Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 12 Oct 1998 11:16:27 +0930
From:      Greg Lehey <grog@lemis.com>
To:        BEAUPRE Antoine <beaupran@JSP.UMontreal.CA>
Cc:        Francisco Reyes <francisco@natserv.com>, freebsd-questions <freebsd-questions@FreeBSD.ORG>
Subject:   Re: How to reset FreeBSD?
Message-ID:  <19981012111627.P24503@freebie.lemis.com>
In-Reply-To: <Pine.SGI.3.96.981011213551.3347B-100000@derby.jsp.umontreal.ca>; from BEAUPRE Antoine on Sun, Oct 11, 1998 at 09:39:44PM -0400
References:  <19981012094800.J24503@freebie.lemis.com> <Pine.SGI.3.96.981011213551.3347B-100000@derby.jsp.umontreal.ca>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sunday, 11 October 1998 at 21:39:44 -0400, BEAUPRE Antoine wrote:
> On Mon, 12 Oct 1998, Greg Lehey wrote:
>
>> On Sunday, 11 October 1998 at 19:42:50 -0400, BEAUPRE Antoine wrote:
>>> On Sun, 11 Oct 1998, Francisco Reyes wrote:
>>>> On 11-Oct-98 BEAUPRE Antoine wrote:
>>>>> Apart from a reboot, how can I restart the system?
>>>>
>>>> What do you mean by "restart" the system?
>>>> What did you mean by reboot? The reboot command?
>>>> You can "halt" the system and then turn off the computer or press any key
>>>> for a reboot.
>>>>
>>>> man: shutdown, halt, reboot
>>>
>>> I mean restarting the ttys, re-reading rc.local, etc. But not rebooting!
>>> No morre than halting the system. Keeping process running (like ppp) would
>>> be nice also...
>>
>> If you want to re-read /etc/rc.local, do:
>>
>>  # . /etc/rc.local
>>
>> But you need to understand what you're doing first.  In most cases,
>> you can restart individual processes or configure interfaces without
>> resorting to that kind of blanket measure.  What are you really trying
>> to do?
>
> In particular, I had problems with ppp. Trying to bind a socket to and
> address was giving me "address already in use" by bind. What deamon or
> process is responsible for this?

The answer went past not quite an hour ago:

On Monday, 12 October 1998 at  2:50:16 +0200, Neil Blakey-Milner wrote:
> On Sat 1998-10-10 (17:55), Alfred wrote:
>> i'm trying to code a threaded ident server
>> (yes i know one already exists)
>> however i'm finding the way that socket->uid mappings are done to be VERY
>> UGLY(tm) unless i cheat :)
>>
>> then it gets worse when i try to find what port the socket is actually
>> bound to.
>
> I'm not sure if this helps, but take a look at the lsof code, it does all
> sorts of fun things, which you can limit to specific ports, and things
> like that.
>
> ie, if I wanted to know who was using port 3400, I'd do:
>
> lsof -i :3400
>
> and it'd return something like...
>
> irc-4.4  1291  bvi    4u  inet 0xf77aede0      0t0  TCP xxxx:3400->yyyy:6667
>
> Neil

> Apart from this, I once needed to restart the ttys...

All of them?  What was wrong with them?  Normally you'd do a

   kill -1 1

to get init to re-read /etc/ttys.

> Also, when I drop single-user (kill 1),

kill 1?  You're trying to kill init?  The correct way to go back to
single-user mode is with shutdown (no flags).  But why do you want to
do this?

> I can't get back to mutli-user mode... This must be an easy one
> although.  it tries to mount drives,and I get "device busy"s, but I
> can't umount them...

Right.  In fact, 'shutdown now' isn't very useful.  If you *really*
want to go to single user mode, you're better off booting.  But I
can't see any good reason to want to do so.

Greg
--
See complete headers for address, home page and phone numbers
finger grog@lemis.com for PGP public key

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19981012111627.P24503>