# Latest udev broke sound

## j79zlr

When I updated to the latest ~x86 v077-r1 of udev it broke my sound card.  I was able to fix it by masking udev-077 and reemerging udev-073.  The error seemed to come from the fact that /dev/sound and its subfiles were not created. I have an ASUS P4PE with the onboard intel8x0 sound card. FWIW:

```
root@gentoo ~ # emerge info

Portage 2.0.51.22-r3 (default-linux/x86/2005.1, gcc-3.4.4, glibc-2.3.5-r2, 2.6.14-gentoo-r4 i686)

=================================================================

System uname: 2.6.14-gentoo-r4 i686 Intel(R) Pentium(R) 4 CPU 2.53GHz

Gentoo Base System version 1.6.13

dev-lang/python:     2.3.5, 2.4.2

sys-apps/sandbox:    1.2.12

sys-devel/autoconf:  2.13, 2.59-r6

sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r1

sys-devel/binutils:  2.16.1

sys-devel/libtool:   1.5.20

virtual/os-headers:  2.6.11-r3

ACCEPT_KEYWORDS="x86"

AUTOCLEAN="yes"

CBUILD="i686-pc-linux-gnu"

CFLAGS="-O2 -pipe -march=pentium4 -fomit-frame-pointer"

CHOST="i686-pc-linux-gnu"

CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/lib/X11/xkb /usr/lib/mozilla/defaults/pref /usr/share/config /var/qmail/control"

CONFIG_PROTECT_MASK="/etc/gconf /etc/splash /etc/terminfo /etc/env.d"

CXXFLAGS="-O2 -pipe -march=pentium4 -fomit-frame-pointer"

DISTDIR="/usr/portage/distfiles"

FEATURES="autoconfig distlocks sandbox sfperms strict"

GENTOO_MIRRORS="ftp://ftp.gtlib.cc.gatech.edu/pub/gentoo http://gentoo.chem.wisc.edu/gentoo/ http://gentoo.cites.uiuc.edu/pub/gentoo/ ftp://gentoo.cites.uiuc.edu/pub/gentoo/ "

MAKEOPTS="-j2"

PKGDIR="/usr/portage/packages"

PORTAGE_TMPDIR="/var/tmp"

PORTDIR="/usr/portage"

SYNC="rsync://rsync.namerica.gentoo.org/gentoo-portage"

USE="x86 X aac alsa apm asf audiofile avi berkdb bitmap-fonts bzip2 cdr crypt cups curl dvd dvdr dxr3 eds emboss encode esd exif expat fam flac foomaticdb fortran gdbm gif gimp gimpprint glut gnome gnutls gphoto2 gpm gstreamer gtk gtk2 guile hal howl idn imagemagick imlib ipv6 java joystick jpeg lcms libg++ libwww mad mikmod mng motif mozilla mp3 mpeg ncurses nls nptl offensive ogg oggvorbis opengl pam pcre pdflib perl png ppds python quicktime readline real samba scanner sdl spell sse sse2 ssl tcltk tcpd tiff truetype truetype-fonts type1-fonts udev usb vorbis win32codecs xine xml2 xmms xv zlib userland_GNU kernel_linux elibc_glibc"

Unset:  ASFLAGS, CTARGET, LANG, LC_ALL, LDFLAGS, LINGUAS, PORTDIR_OVERLAY

root@gentoo ~ #
```

Just a heads up to anyone experiencing problems, that reemerging the older udev might be a solution until this is sorted.

----------

## Diskus

HAllo,

i have the same problem with you-/dev/dsp no file or directory-udev-073 is ok.

Diskus

----------

## dgaffuri

Not here

```
~ # ls -l /dev/sound/

total 0

crw-rw----  1 root audio 14, 12 Dec  8 02:05 adsp

crw-rw----  1 root audio 14,  4 Dec  8 02:05 audio

crw-rw----  1 root audio 14,  3 Dec  8 02:05 dsp

crw-rw----  1 root audio 14,  0 Dec  8 02:05 mixer

crw-rw----  1 root audio 14,  1 Dec  8 02:05 sequencer

crw-rw----  1 root audio 14,  8 Dec  8 02:05 sequencer2

~ # emerge -pv udev

These are the packages that I would merge, in order:

Calculating dependencies ...done!

[ebuild   R   ] sys-fs/udev-077-r1  (-selinux) 0 kB

Total size of downloads: 0 kB
```

Of course I've rebooted after upgrading udev. Did you update conf files?

----------

## Diskus

HAllo,

yes i have etc-update and reboot!!

```

diskus lars # ls -l /dev/sound/

insgesamt 0

crw-rw----  1 root audio 14, 1  8. Dez 2005  sequencer

crw-rw----  1 root audio 14, 8  8. Dez 2005  sequencer2

diskus lars #

```

with udev-073 is ok.

Diskus

----------

## PboY

 *j79zlr wrote:*   

> When I updated to the latest ~x86 v077-r1 of udev it broke my sound card.

 

mine too.

solved the problem launching 

```

udevstart

/etc/init.d/alsasound restart

nano -w /etc/conf.d/rc

```

change

```

RC_DEVICE_TARBALL="no"

```

to

```

RC_DEVICE_TARBALL="yes"

```

bye

----------

## Ateo

upgrade to udev-077-r1 fine here without any file modifications (other than updating the default rules file).

Did you have any sound specific custom rules in your rules file that may have been overwritten?

----------

## PboY

 *Ateo wrote:*   

> upgrade to udev-077-r1 fine here without any file modifications (other than updating the default rules file).
> 
> Did you have any sound specific custom rules in your rules file that may have been overwritten?

 

no ...   :Sad: 

----------

## Inc!

It appears to baselayout problem. I'm running baselayout-1.11.13-r1 and the following fixed it:

In /sbin/rc i replaced...

```

                       # Setup temporary storage for /dev

                       ebegin "Mounting /dev for udev"

                       if [[ ${RC_USE_FSTAB} = "yes" ]] ; then

                               mntcmd=$(get_mount_fstab /dev)

                       else

                               unset mntcmd

                       fi

                       if [[ -n ${mntcmd} ]] ; then

                               try mount -n ${mntcmd}

                       else

                               if egrep -qs tmpfs /proc/filesystems ; then

                                       mntcmd="tmpfs"

                               else

                                       mntcmd="ramfs"

                               fi

                               # many video drivers require exec access in /dev #92921

                               try mount -n -t ${mntcmd} udev /dev -o exec,nosuid,mode=0755

                       fi

                       eend $?

                       # Selinux lovin; /selinux should be mounted by selinux-patched init

                       if [[ -x /sbin/restorecon ]] && [[ -c /selinux/null ]] ; then

                               restorecon /dev &> /selinux/null

                       fi

                       # Actually get udev rolling

                       ebegin "Configuring system to use udev"

                       if [[ ${RC_DEVICE_TARBALL} = "yes" ]] && [[ -s /lib/udev-state/devices.tar.bz2 ]]

                       then

                               einfo "  Populating /dev with device nodes ..."

                               try tar -jxpf /lib/udev-state/devices.tar.bz2 -C /dev

                       fi

                       populate_udev

                       # Setup hotplugging (if possible)

                       if [ -e /proc/sys/kernel/hotplug ] ; then

                               if [ "$(udev_version)" -ge "48" ] ; then

                                       einfo "  Setting /sbin/udevsend as hotplug agent ..."

                                       echo "/sbin/udevsend" > /proc/sys/kernel/hotplug

                               elif [ -x /sbin/hotplug ] ; then

                                       einfo "  Using /sbin/hotplug as hotplug agent ..."

                               else

                                       einfo "  Setting /sbin/udev as hotplug agent ..."

                                       echo "/sbin/udev" > /proc/sys/kernel/hotplug

                               fi

                       fi

                       eend 0

```

with:

```

                   start_addon udev

```

Upgrading to latest unstable baselayout might also work, or just upgrading /sbin/rc only, however i can't confirm it. Have a nice day guys,

----------

## luca82

 *PboY wrote:*   

>  *j79zlr wrote:*   When I updated to the latest ~x86 v077-r1 of udev it broke my sound card. 
> 
> mine too.
> 
> solved the problem launching 
> ...

 

That's worked also for me with 077-r1.

----------

## dgaffuri

 *Inc! wrote:*   

> It appears to baselayout problem. I'm running baselayout-1.11.13-r1 and the following fixed it:
> 
> ....
> 
> ```
> ...

 

That's like baselayout-1.12.0_pre11-r3. In fact I din't have any problem updating udev.

----------

## calr0x

Very popular problem lately and it IS related to what versions of both udev and baselayout yer using...  :Smile: 

----------

## sundialsvc4

Something that could also be a potential issue is the feature of Gentoo that can make a tarball of the contents of /dev and restore it.  That feature, to me, is turned off.

It's possible, for example, that the device-configuration that's "normally" set-up by udev hasn't really been coming into play because the tarball has been superseding it.

udev basically operates through a rules-file, in /etc/udev, which isn't spectacularly hard to grok.

----------

## Inc!

 *dgaffuri wrote:*   

> That's like baselayout-1.12.0_pre11-r3. In fact I din't have any problem updating udev.

 

exactly, i took a peek at /sbin/rc in 1.12.0_pre11-r3 to see how it deals with udev stuff. seems it handles it differently now. 1.11.13-r1 had the gizmo that started udev at boottime packed inside /sbin/rc. however 1.12.0_pre11-r3 makes a call to /lib/rcscripts/addons/udev-start.sh, which is provided by udev-077 package and does all the stuff to start it up.

it's likely that mentioned gizmo in 1.11.13-r1 is not enough now to start latest udev-077 properly (hence missing nodes in /dev for soundcards and v4l devices in my case), therefore to summarize possible solutions, i see the following options to make it work:

 keep the baselayout-1.11.13-r1, but patch /sbin/rc to make a call to udev-start.sh, like i did few posts above and i can confirm it working.

 keep the baselayout-1.11.13-r1, but try to replace /sbin/rc with one extracted from baselayout-1.12.0_pre11, which should work as well and i'll give it a try when i get bored.

 upgrade baselayout to the latest, or downgrade udev to the previous version  :Smile: 

manually calling udevstart every boot, although does the job, doesn't sound like a good solution for me. neither setting RC_DEVICE_TARBALL="yes" in /etc/conf.d/rc - it only restores device nodes from tarball and we want udev working.

----------

## dgaffuri

 *Inc! wrote:*   

> manually calling udevstart every boot, although does the job, doesn't sound like a good solution for me. neither setting RC_DEVICE_TARBALL="yes" in /etc/conf.d/rc - it only restores device nodes from tarball and we want udev working.

 

I agree. Just for information, I'm running new baselayout from some time, never had problems. Thanks for the detailed info, you made a good job.   :Cool: 

----------

## calr0x

Ya def thanks..   :Smile: 

----------

## martin.k

That's why I'm still using devfs, even on current 2.6.15-rc5-mm1.

It's still there... So I use because I don't want any udev breakdowns  :Smile: 

----------

## calr0x

 *martin.k wrote:*   

> That's why I'm still using devfs, even on current 2.6.15-rc5-mm1.
> 
> It's still there... So I use because I don't want any udev breakdowns 

 

Other than this temporary issue, there has been none.. I def suggest moving to it.

----------

## j-m

You need at least baselayout-1.11.14 for udev-077* to work. 077-r3 now RDEPENDS on it.

----------

## calr0x

 *j-m wrote:*   

> You need at least baselayout-1.11.14 for udev-077* to work. 077-r3 now RDEPENDS on it.

 

Ya, "need" is the wrong term tho..  Yes it's the minimum VERSION, but that combo is currently busted..  I HAD udev 77 and baselayout 1.11.14 and originally downgraded udev to 73, today I upgraded back to 77, and actually upped my baselayout to 1.12.

Long story short, udev77 and baselayout-1.11.14 do NOT currently work together...  Either use udev73 and baselayout1.11.14 OR use udev77 and baselayout-1.12.

----------

## j-m

 *calr0x wrote:*   

>  *j-m wrote:*   You need at least baselayout-1.11.14 for udev-077* to work. 077-r3 now RDEPENDS on it. 
> 
> Long story short, udev77 and baselayout-1.11.14 do NOT currently work together...  Either use udev73 and baselayout1.11.14 OR use udev77 and baselayout-1.12.

 

Works fine here, if something does not work for you then some better description is needed.

----------

## calr0x

 *j-m wrote:*   

>  *calr0x wrote:*    *j-m wrote:*   You need at least baselayout-1.11.14 for udev-077* to work. 077-r3 now RDEPENDS on it. 
> 
> Long story short, udev77 and baselayout-1.11.14 do NOT currently work together...  Either use udev73 and baselayout1.11.14 OR use udev77 and baselayout-1.12. 
> 
> Works fine here, if something does not work for you then some better description is needed.

 

Um... read up?

----------

## j-m

 *calr0x wrote:*   

> 
> 
> Um... read up?

 

Um... works here.

----------

## calr0x

 *j-m wrote:*   

>  *calr0x wrote:*   
> 
> Um... read up? 
> 
> Um... works here.

 

I don't even know what to say to this.  Do you only read the last post in a thread?

READ.

UP.

/me forces your head up

----------

## calr0x

https://forums.gentoo.org/viewtopic-t-409612-highlight-.html

https://forums.gentoo.org/viewtopic-t-408962-highlight-.html

https://forums.gentoo.org/viewtopic-t-409881-highlight-.html

Welcome to the fact there's a well established problem w/ udev/baselayout thats depending on running certain versions of each.

/me shakes his head

----------

## calr0x

For my pal j-"Works fine here"-w:

 *Inc! wrote:*   

> It appears to baselayout problem. I'm running baselayout-1.11.13-r1 and the following fixed it:
> 
> In /sbin/rc i replaced...
> 
> ```
> ...

 

----------

## calr0x

More stuff:

https://bugs.gentoo.org/show_bug.cgi?id=114932

/me gives j-w a noogie

----------

## calr0x

And finally:

Changes:

*udev-077-r3 (09 Dec 2005) 09 Dec 2005; Greg Kroah-Hartman (gregkh) +udev-077-r3.ebuild: 077-r3 release - fix dependancy on newer version of baselayout (for those who are running stable for other packages, and don't seem to want to upgrade) as we need it to start udev properly at boot time.

----------

## j-m

 *calr0x wrote:*   

> For my pal j-"Works fine here"-w:
> 
>  *Inc! wrote:*   It appears to baselayout problem. I'm running baselayout-1.11.13-r1 and the following fixed it:
> 
> In /sbin/rc i replaced...
> ...

 

Ayeeee, that's exactly what's in /sbin/rc in baselayout-1.11.14, so maybe you should read up the code instead of spamming this thread with unhelpful posts...   :Razz: 

P.S. Thanks for the bugzie references, you can now check yourself that you're holding a candle to the sun.   :Smile: Last edited by j-m on Sat Dec 10, 2005 11:20 am; edited 1 time in total

----------

## ToeiRei

could we stop that flamewar and start searching for solutions?

Rei

----------

## j-m

 *ToeiRei wrote:*   

> could we stop that flamewar and start searching for solutions?
> 
> Rei

 

Yeah, sure... If you'd read up then you'd find out that you need a newer baselayout...   :Laughing: 

----------

## ToeiRei

 *j-m wrote:*   

> Yeah, sure... If you'd read up then you'd find out that you need a newer baselayout...  

 

I got simmilar problems with baselayout 1.12.0_pre11-r3. 

Rei

----------

## calr0x

 *ToeiRei wrote:*   

>  *j-m wrote:*   Yeah, sure... If you'd read up then you'd find out that you need a newer baselayout...   
> 
> I got simmilar problems with baselayout 1.12.0_pre11-r3. 
> 
> Rei

 

Exactly. =P

----------

## ToeiRei

I could track it down... thanks to my cat for the solution.

While fiddeling around with udev 0.77-r3 /  baselayout 1.12.0_pre11-r3 I rebooted several times. 

The initrd complains that /dev was busy and could not be unmounted. At this point my cat ripped out my USB mouse and the pc rebooted without problems and udev started ok.

Rei

----------

## StringCheesian

 *ToeiRei wrote:*   

>  *j-m wrote:*   Yeah, sure... If you'd read up then you'd find out that you need a newer baselayout...   
> 
> I got simmilar problems with baselayout 1.12.0_pre11-r3.

 

Same here. udev 077-r4, baselayout 1.12.0_pre11-r1 (EDIT: I just upgraded to udev 077-r5 and baselayout 1.12.0_pre11-r3, no change)

No sound, no /dev/dsp, but sound starts working again as soon as I run "udevstart".

Also I don't know if this is related, from dmesg:

```
Advanced Linux Sound Architecture Driver Version 1.0.10rc1 (Mon Sep 12 08:13:09 2005 UTC).

ALSA device list:

  No soundcards found.
```

gentoo-sources 2.6.14-r4

ALSA is built in with emu10k1 as a module. Maybe udev isn't creating device nodes in cases where the sound card isn't properly detected? 

But then how come all the right modules were loaded anyway? And why did sound start working fine when I udevstart if my sound card is supposedly not being detected?

----------

## ToeiRei

StringCheesian, are you using an initrd?

A quick 'hack' did it for me - altering /sbin/rc the way that the udevd got killed before started. Maybe I'm wrong but it looks like the problem is located in the initrd and his device-manager which did not shut down on startup...

Rei

----------

## StringCheesian

 *ToeiRei wrote:*   

> StringCheesian, are you using an initrd?

 

I'm not. Should I?

 *ToeiRei wrote:*   

> A quick 'hack' did it for me - altering /sbin/rc the way that the udevd got killed before started. Maybe I'm wrong but it looks like the problem is located in the initrd and his device-manager which did not shut down on startup...

 

I don't understand   :Confused:  ... you mean modify /sbin/rc the way Inc! said to?

----------

## ToeiRei

No. I am using the newest baselayout - so there is no need to.

In the /sbin/rc there is the "start_addon udev" command. 

Before that I added "killall -9 udevd" which solved it for me.

Rei

----------

