Hello,
I reconfigure now my linux. And I have some problems.
I have slackware distribution. During boot I always
see root directory is mounted read-only, after that rc.K
script is executed (TERM and KILL signals are sent),
then rc.M is executed and everything is OK.
/etc/inittab seems to be OK.
Today I changed /etc/inittab, and then I got into
/etc/failinit program (that is executed in case init have
some problems).
I have:
* /bin/bash statically linked.
* root has shell /bin/bash
* user has shell /bin/tcsh
I run:
* login as root
* cd /etc/rc.d
* su user
* rc.0 (see the below)
After that I can toogle between root and user,
one time execute command as a user, second time as a root.
server:~#
server:~# cd /etc/rc.d
server:/etc/rc.d# su user
server:/etc/rc.d:1 14:03:07% rc.0
Running shutdown script rc.0:
[1]+ Stopped (signal) su user
server:/etc/rc.d# halt: must be superuser.
cp: cannot create regular file `/etc/localtime': Permission denied
Turning off swap.
umount: only root can do that
swapoff: /dev/swap: Operation not permitted
Unmounting local file systems.
umount: only root can do that
mount: only root can do that
The system is halted.
On the next boot fsck will be FORCED.
halt: must be superuser.
server:/etc/rc.d:2 14:03:10%
server:/etc/rc.d:2 14:03:12%
[1]+ Stopped (signal) su user
server:/etc/rc.d#
(...)
server:/etc/rc.d# pstree
init-+-bash---screen---screen---bash-+-less
| |-pstree
| `-tcsh <- each command I toggle into this process
|-crond (as user user)
|-gpm
|-kflushd
|-klogd
|-kswapd
|-rpc.portmap
|-syslogd
`-xinetd
--
Piotr Klaban
---