Subject: Re: using "shutdown" as a shell
To: None <shnek@chemi.muni.cz>
From: Martti Kuparinen <martti.kuparinen@iki.fi>
List: netbsd-help
Date: 09/12/2003 09:27:11
Lubos Vrbka wrote:
> 
>> This is what I have in my home PC:
>>
>> - two users
>>
>>     halt:*:0:0:Halt this PC:/home/halt:/bin/sh
>>     reboot:*:0:0:Reboot this PC:/home/halt:/bin/sh
>>
>> - both have this .profile in their home directory
>>
>>     #!/bin/sh
>>     case ${LOGNAME} in
>>             halt)
>>                     /sbin/halt -p
>>                     ;;
>>             reboot)
>>                     /sbin/reboot
>>                     ;;
>>             *)
>>                     ;;
>>     esac
>>
>> Works very well for me :-)
> 
> the situation is complicated in one more way. home directories for all

Just create these two users so that their home directory is on a local disk.
Something like this:

	halt:*:0:0:Halt this PC:/usr/halt:/bin/sh
	reboot:*:0:0:Reboot this PC:/usr/halt:/bin/sh

Martti