[SLUG] If its not broken, dont (attempt to) fix it?

Gavin Baker gavbaker at ntlworld.com
Thu Oct 31 22:20:09 GMT 2002


On Thu, 2002-10-31 at 19:52, aardvark llama wrote:

> >Debian's default runlevel is 2. Your display manager
> >(gdm/kdm/xdm/wdm/...) will start at runlevel 2 (as will just about
> >everything you install).
> >
> >It's just the redhat defaults that have a kind of run level "rule"
> >(2: multiuser no nfs, 3: 2+NFS, 4: unused, 5: 3+X display manager).

> I think there is a more general disagrement than simply between Debian and 
> Redhat. 

I don't think there is a disagreement. Just a minor variation on
implementation details. I didn't mean it to sound like there are only 2
true ways(tm), but there are lots of RH based distributions and most of
them use the same runlevel scheme, which is almost the same as what the
original SYSV UNIX used.

> From my solaris sysadmin course notes -- and IIRC this is true for 
> AIX and Slackware -- there are the following Sys V runlevels:
> 0 Powerdown -- Time to unplug...;
> 1 System Admin -- (aka s or S mode) no networking enabled;
> 2 Multiuser -- no networking enabled (or at least no file sharing...);
> 3 Multiuser -- networking enabled with file sharing;
> 4 Administrator definable.
> 5 Maintenance -- this is a bit strange because of the linux usage;
> 6 Reboot -- like powerdown but then restarts the machine.

Solaris is (almost) pure SYSV, yep.

I thought AIX used some special command to handle it's "services" or
"subsystems".. ya learn something new everyday.

The only runlevels that are the same over all distributions and could be
called "standard" are 0 (halt), 1 (or s or S) Single user mode and 6
(reboot). I didn't mention them for this reason.

> The BSD run levels are remarkably similar.

Except freeBSD, BSDi, openBSD and netBSD etc, which don't have runlevels
at all...

> IME then linux distributions like slackware use 5 as the same as 3 but with 
> X enabled. 

Almost

# These are the default runlevels in Slackware:
# 0 = halt
# 1 = single user mode
# 2 = unused (but configured the same as runlevel 3)
# 3 = multiuser mode (default Slackware runlevel)
# 4 = X11 with KDM/GDM/XDM (session managers)
# 5 = unused (but configured the same as runlevel 3)
# 6 = reboot

A little different is the mandrake one

# Default runlevel. The runlevels used by RHS are:
#   0 - halt (Do NOT set initdefault to this)
#   1 - Single user mode
#   2 - Multiuser, without NFS
#   3 - Full multiuser mode
#   4 - unused
#   5 - X11
#   6 - reboot (Do NOT set initdefault to this)


> However, in general -- or at least with commercial unices I have 
> worked with -- the default run level including X is 3.

Which can be different from unix to unix and linux to linux. For
example, what mandrake (and RH?) use for X, SYSV used as Halt &
Poweroff.

> So, there you go. You pays your money and you take you pick. The only thing 
> then that puzzles me is the choice by debian to use run level two as 
> default...

Why not? :)

I'm sure i could find lots of different schemes like the slack/mandrake
ones above. You find me one that's simpler or more easy to customise
than:

# Runlevel 0 is halt.
# Runlevel 1 is single-user.
# Runlevels 2-5 are multi-user.
# Runlevel 6 is reboot.

And i'll buy you a beer :)

Whats the point of having a runlevel defined as "Multiuser + NFS" if the
box is never gonna use NFS?

And why define runlevel 5 for the X display manager if you choose to
startx with "startx" instead of a graphical login, or don't even have X?
I guess there is no perfect way, luckily we are free to change it to
suit. I'm sure someone somewhere has runlevel 2 as
single-user+quake-server...

Just because we have a common practice, doesn't mean it's the best
practice.

Anyway, we've gone really off topic again :)

Regards,
Gav







More information about the Scarborough mailing list