Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 166990 - sys-fs/udev-104-r11: writes to /dev/console
Summary: sys-fs/udev-104-r11: writes to /dev/console
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: udev maintainers
Depends on:
Reported: 2007-02-15 09:50 UTC by Jimmy.Jazz
Modified: 2007-02-21 18:57 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Note You need to log in before you can comment on or make changes to this bug.
Description Jimmy.Jazz 2007-02-15 09:50:19 UTC
messages are redirected to the console during gensplash quiet mode

maybe /lib/udev/ should be filtered with something like sed -e "s~> /dev/console~~"

Reproducible: Always
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2007-02-15 10:02:20 UTC
Not baselayout.
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2007-02-15 20:10:32 UTC
What messages are you seeing? Do you have CONSOLE=/dev/tty1 properly set?
Comment 3 Matthias Schwarzott gentoo-dev 2007-02-16 13:17:48 UTC
How to find out in the code if one is allowed to write to /dev/console, or where to write?
Comment 4 Matthias Schwarzott gentoo-dev 2007-02-16 13:24:54 UTC
One possible idea is to check $CONSOLE and use that. But first: at that point of time it is possible that the device node does not exist (udev-start only creates /dev/null and /dev/console) and udev later processes all other stuff.

Second: udev clears environment, that means udev-start has to check and write device to some file /dev/.udev_console (or whatever), and can then check existence and in case write to that.

Or udev-start just disables verbose if CONSOLE!=/dev/console.
Comment 5 Michal Januszewski (RETIRED) gentoo-dev 2007-02-19 21:56:20 UTC
Here are some loose thoughts about the problem:

The general idea would be not to write to /dev/console when the silent splash mode is requested (because then /dev/console is the current tty on which the splash image is displayed) and to use $CONSOLE instead.

If /dev/tty1 from the root fs is accessible when is run (which I think it's not -- correct me if I'm wrong here) then if it doesn't exist, we can simply fall back to /dev/console (splash won't start if /dev/tty1 isn't present on the root fs). If it's not accessible, then maybe it could be created in seed_dev() along with /dev/console and /dev/null?

Clearing the environment shouldn't be that much of a problem because you can always get the CONSOLE setting from /proc/cmdline (I think).
Comment 6 Matthias Schwarzott gentoo-dev 2007-02-20 11:57:10 UTC
This should be fixed in udev-104-r12.

It uses $CONSOLE in
udev.start additionally creates /dev/tty1 to be able to write before udevd has created it.
Comment 7 Jimmy.Jazz 2007-02-21 18:43:07 UTC
(In reply to comment #2)
> What messages are you seeing? Do you have CONSOLE=/dev/tty1 properly set?

yes, i did

deleting the redirection "> /dev/console" in the file works for me. The message then goes to $CONSOLE (i have defined at the kernel cmdline) without other needs. So i don't think it is necessary to force the output to $CONSOLE explicitly. But i can be wrong.

Comment 8 Matthias Schwarzott gentoo-dev 2007-02-21 18:57:32 UTC
The explicit redirection is necessary, as else output would go to /dev/null (where udevd redirects stdin/stdout).