On Tue, 1 Sep 1998, Richard Adams wrote:
> Hi Kenneth Stephen. et all.
>
> 1.1 Help! I can't remember my root password!
> What you will need to do, is a re-boot. If you are the administrator it
> would be prudent to warn users that are logged in. Say something like you
> have to do an emergency maintenance.
>
> [
> You do not even need to reboot, if you do the System will automaticly send
> a message to all connecties/users that "The System is going down".
> Even using 'init 1' will still send other users the same message.
>
You *do* need to send users a warning. They system will send a message to
all users that it is going down, and they will be chucked off immediately.
It is curtious to give them at least 10-15 minutes notice before chucking
them off. You can do this with options to shutdown (which I can't
remember right now...)
> Ok, Now how do you do it.
>
> 1: first think up a new password.
> 2: reboot the machine
>
> No dont reboot, just use 'init 1' which has the same effect but does not
> reboot the machine.
Um. You can't do init 1 unless you are root in which case you can change
your password just by editing /etc/shadow (or passwd on an unshadowed
system) and deleting the password, then use passwd to set a new one.
> 1.7
> do a 'ps aux' to and look through the output to see which line corresponds
> to the process you are trying to kill. The second column on the relevant
> line is the process id. Now do a 'kill -9 <process id>'.
>
> [
> do 'ps ax | grep command' Where command is the name typed which caused the
> problem. (Saves having to sift thro' all those prosecces).
There is a command 'killall' which comes with many distributions. You can
do 'killall process_name' to kill all processes with that name. A word of
warning though - in Solaris and some other unices, killall kills all
processes you own...
HTH
--
Mike <[EMAIL PROTECTED]>
QOTD:
"I drive my car quietly, for it goes without saying."