Re: /dev/console wrong on upgraded systems (2.0 -> 2.1)
"Ralf G. R. Bergs" wrote:
>Hi,
>
>I discovered that on ALL my systems that originally were Debian 2.0 and have
>
>been upgraded to Debian 2.1 /dev/console is wrong. It's a link to /dev/tty0
>instead of a device special file (mknod -m 622 /dev/console c 5 1).
>
>Can anyone pls. check whether this is the case with "native" 2.1 systems?
>Anyone know who to inform in case the bug is also present in 2.1?
This is the relevant bit of /dev/MAKEDEV (makedev package):
console)
major=`Major vcs` # not fatal
makedev tty0 c 4 0 $cons
# console
# new kernels need a device, old ones a symlink... sigh
kern_rev1=`uname -r | awk -F'.' '{print $1}'`
kern_rev2=`uname -r | awk -F'.' '{print $2}'`
if [ $kern_rev1 -gt 2 ]
then
makedev console c 5 1 $cons
else
if [ $kern_rev1 -eq 2 -a $kern_rev2 -ge 1 ]
then
makedev console c 5 1 $cons
else
symlink console tty0
fi
fi
Therefore, if your kernel is 2.1 or greater, you can delete the console
symlink and run `MAKEDEV console' to create a new console device.
Since 2.1 (slink) ships with kernel 2.0.3x, the symlink is correct for
it. Perhaps the makedev package should contain something to look at the
kernel version and upgrade automatically?
--
Oliver Elphick Oliver.Elphick@lfix.co.uk
Isle of Wight http://www.lfix.co.uk/oliver
PGP key from public servers; key ID 32B8FAA1
========================================
"Nay, in all these things we are more than conquerors
through him that loved us." Romans 8:37
Reply to: