Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 143795 - udev could depend on /dev/urandom, not made by udev-start.sh
Summary: udev could depend on /dev/urandom, not made by udev-start.sh
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Greg Kroah-Hartman (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: udev-meta
  Show dependency tree
 
Reported: 2006-08-13 10:01 UTC by Justin Sanchez
Modified: 2006-08-30 21:25 UTC (History)
2 users (show)

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


Attachments
Kernel .config (kernelconfig,37.76 KB, text/plain)
2006-08-13 11:13 UTC, Justin Sanchez
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Justin Sanchez 2006-08-13 10:01:07 UTC
Something I ran into, anyway.

The udev ebuilds create /lib/udev/devices/{console,null,zero} which are copied into the new /dev/ before udev is started by udev-start.sh, but there is no such handling of /dev/urandom. If udev needs /dev/urandom to work, such as for openssl, it doesn't work correctly, and the system doesn't boot. putting a urandom into /lib/udev/devices fixed the problem.
Comment 1 Jakub Moc (RETIRED) gentoo-dev 2006-08-13 10:54:31 UTC
What a wealth of info... You didn't post emerge --info for starters, or udev version, or kernel .config, or what's your problem with getting /dev/(u)random created. 

Gentoo boots just fine with completely empty /dev, don't see what your problem is.
Comment 2 Justin Sanchez 2006-08-13 11:13:31 UTC
Created attachment 94161 [details]
Kernel .config
Comment 3 Justin Sanchez 2006-08-13 11:17:20 UTC
The tone isn't really necesary, I don't think... And it is a name service problem, not a kernel issue, or build issue. Like I said, udev might need urandom, for openssl. ldaps:// name service, for example, and openssl needs urandom. start-udev.sh mounts a blank tmpfs over /dev, copies in console, null, and zero, creates some symlinks, and then starts udev. udev can't resolve names, and you run into nss-ldap timeouts, due to TLS negotiation failures.

udev is sys-fs/udev-087-r1

The emerge --info:

Portage 2.1-r2 (default-linux/x86/2006.0, gcc-3.4.6, glibc-2.3.6-r4, 2.6.17.1 i686)
=================================================================
System uname: 2.6.17.1 i686 Intel(R) Pentium(R) 4 CPU 1.60GHz
Gentoo Base System version 1.12.4
distcc 2.18.3 i686-pc-linux-gnu (protocols 1 and 2) (default port 3632) [disabled]
ccache version 2.3 [enabled]
app-admin/eselect-compiler: [Not Present]
dev-lang/python:     2.2.3-r1, 2.3.5-r2, 2.4.3-r1
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.3
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.11-r2
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O3 -march=pentium4 -funroll-loops -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/lib/mozilla/defaults/pref /usr/share/X11/xkb /usr/share/config /usr/share/texmf/dvipdfm/config/ /usr/share/texmf/dvips/config/ /usr/share/texmf/tex/generic/config/ /usr/share/texmf/tex/platex/config/ /usr/share/texmf/xdvi/ /var/bind"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-O3 -march=pentium4 -funroll-loops -fomit-frame-pointer -pipe"
DISTDIR="/pub/distfiles"
FEATURES="autoconfig ccache distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="http://gentoo.mirrors.pair.com/ "
LC_ALL="en_US.utf8"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 X X509 Xaw3d a52 aac aalib acpi aim akode alsa apache2 apm arts asterisk audiofile avi bash-completion berkdb bitmap-fonts bonobo bzip2 canna cdda cddb cdparanoia cdr cdrom cjk clamav cli crypt cups curl curlwrappers dga dlloader doc dri dv dvd dvdr dvdread eds emboss encode escreen esd evo faac faad fame festival ffmpeg firefox flac foomaticdb fortran fping freetype ftp gd gdbm gif gimp gimpprint gkrellm glut gnome gnome-print gnomedb gnuplot gpm gs gstreamer gtk gtk2 gtkhtml hal hbci imagemagick imap imlib immqt-bc ipv6 irda isdnlog jabber jack java jpeg junit kde latex lcms ldap libcaca libg++ libgdb libwww lirc live lm_sensors lzo lzw mad matroska mbox mbrola mikmod mjpeg mmx mmx2 mmxext mng motif mozilla mp3 mpeg mpeg4 mplayer mysql mythtv ncurses net netbeans nethack network nls nptl nptlonly nsplugin nvidia ocaml offensive ofx ogg opengl oss pam pcre pda pdf pdflib pel perl php png pnp postgres ppds pppd print python qt3 qt4 quicktime quotes rar readline real reflection rtc rtsp ruby samba scanner sdl serial session silc sndfile soap sockets sox spamassassin speex spell spl sse sse2 ssl stream stroke subject-rewrite subtitles sysvipc tcltk tcpd tetex tga theora threads tiff timidity transcode truetype truetype-fonts trusted type1 type1-fonts udev unicode usb v4l v4l2 vcd videos vim vorbis win32codecs wxwindows xanim xcomposite xine xinerama xinetd xml xmms xorg xrandr xsl xv xvid xvmc yahoo zlib elibc_glibc input_devices_keyboard input_devices_mouse input_devices_evdev kernel_linux lirc_devices_all userland_GNU video_cards_nvidia"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LDFLAGS, LINGUAS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS


Comment 4 Jakub Moc (RETIRED) gentoo-dev 2006-08-13 11:23:01 UTC
(In reply to comment #3)
> And it is a name service > problem, not a kernel issue, or build issue. Like I said, udev might need
> urandom, for openssl. l

Eh, you've misunderstood the problem, I'm afraid.



*** This bug has been marked as a duplicate of 99564 ***
Comment 5 Justin Sanchez 2006-08-13 11:31:47 UTC
No, I'm pretty sure I haven't. That bug you reference is similar, but not the same. It addresses the wrong issue. He is saying his udev is going to nss ldap and not nss files, and that is his bug, but the issue that I am is that my nss is only ldap, so udev needs to be able to access the ldap information if it is going to resolve names. udev couldn't really read non existing files, could it?

udev needs a name service, we agree on this? Unless you are saying ldap isn't a valid name service to use, then udev _should_ be able to use it, no? Certainly if it is the only name service...
Comment 6 Jakub Moc (RETIRED) gentoo-dev 2006-08-13 11:33:21 UTC
Please, read the other bug more carefully.

*** This bug has been marked as a duplicate of 99564 ***
Comment 7 Jakub Moc (RETIRED) gentoo-dev 2006-08-13 11:35:27 UTC
Closing this, it has exactly zero in common with /dev/{random,urandom}.
Comment 8 Justin Sanchez 2006-08-13 11:45:16 UTC
Well, you are half right, it has nothing to do with /dev/random. It does however, have everything to do with /dev/urandom. And you are the one who isn't reading. 

The bug you referenced has to do with udev reading names from baselayout's /etc/{group,passwd}. It will only do this if "files" is mentioned in /etc/nsswitch.conf. The bug you reference has to do with using "ldap" in addition to "files". 

This bug has to do with using "ldap" instead of "files". I don't expect udev to read /etc/{group,passwd}, since nsswitch.conf does not contain "files" in the passwd or groups configuration. In which case, having udev not use ldap is not a solution, since ldap is the only name service. udev needs to be able to resolve names over ldap, which means it needs urandom, if it is using SSL for the ldap connection.
Comment 9 Jon Portnoy (RETIRED) gentoo-dev 2006-08-13 11:46:06 UTC
Jakub, I am not sure why you feel the need to pull an attitude without offering a reasonable explanation as to why this is not a bug and I do think you are misunderstanding the problem.
Comment 10 Jon Portnoy (RETIRED) gentoo-dev 2006-08-13 11:46:30 UTC
Could we get your opinion please, Greg?
Comment 11 Greg Kroah-Hartman (RETIRED) gentoo-dev 2006-08-13 23:22:44 UTC
Will add /dev/urandom to list of things that the udev init script initializes.
Comment 12 Greg Kroah-Hartman (RETIRED) gentoo-dev 2006-08-30 21:25:01 UTC
Will be fixed in the 098 ebuild release.