LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   udev is about to beat me (/dev/null, etc) (https://www.linuxquestions.org/questions/linux-hardware-18/udev-is-about-to-beat-me-dev-null-etc-333982/)

CowboyJ 06-15-2005 03:44 PM

udev is about to beat me (/dev/null, etc)
 
Sometime I ago I apparently somehow screwed up permissions on entries in /dev. Devices such as null, console, zero, etc, are now being created 'crw-rw--- root:root'. That makes it difficult for ordinary users to utilize those devices. Problems with /dev/null showed up in a number of places; when I changed its group to 'users', those problems went away. I could not open a terminal in X until I changed the group for /dev/ptmx to 'users'. I have googled and LQ-searched extensively and find a number of people have similar problems. The usual suggestions are to read about udev, and then use udev's rules and permissions to make the devices with the desired permissions. I have found threads ending with apparent success for physical devices (had, sda, scsi/usb devices), but no apparent successes with null, console, etc.

I have hesitated to post this question because of the appearance of being another in long line of similar questions. But, here I am.

I have learned a lot about udev and it permissions. I have modified the permissions involving the non-physical devices, but they don't seem to ever be applied. I have changed the defaults in /etc/udev/udev.conf. I can manually change permissions (or group membership), and devices will then work OK for the non-root user. But as soon as I reboot, the wrong permissions are back. I have deleted the devices to see if then the rules would apply, but they still come back wrong. I have read stuff that suggested to me to udev.tdb may cause devices to be re-created as they were at shutdown, so I deleted udev.tdb before rebooting. Still the devices come back wrong.

Are certain devices immune to udev? If so, where do I set the rules governing their creation? I hope some knowledgable person is patient enough to read to here, and can offer some advice related to changing permission or ownership for /dev/null, /dev/console, /dev/ptmx, and other non-physical devices.

Half_Elf 06-16-2005 10:16 AM

I noticed the problem too, there seem to be a problem with the latest version of udev and "non physical" devices (null, random, urandom, most noticably). I suspect they done a "change" in configuration, mean you old config files need a "new config way".

But eh, I am lazy, so instead of reading tons of docu and fixing it an elegant way, I just added "chmod 777 /dev/null" to some bootup script (I use gentoo, I don't know about Suse, but don't you have some "rc.local" script? ). It works perfectly but I look like a total newbie :P

CowboyJ 06-16-2005 03:28 PM

Half_Elf, you might be on to something with your thought about changes in the later versions of udev. I know I upgraded Udev to version 58 (I think) recently. My problems may go back to that event. I'm away from my computer for a few days, but I'm going to try to explore that idea when I get back.

Half_Elf 06-16-2005 09:12 PM

I use udev version 056 (from gentoo package), all this mess happened when I switched from 054. My config seems ok, in the 054 way, at least, so I guess the problem is udev.
If you find something,let me know :)

lullo 07-06-2005 05:19 AM

I had the same problem after an emerge -u world with Gentoo. After some searching I found the following to solve all problems:

emerge --unmerge udev
rm -r /etc/udev
emerge udev

Half_Elf 07-06-2005 08:12 AM

Ok so I was right, the configuration changed but Gentoo didn't updated it.
Hmmm probably quite more elegant than my solution, I'll add this on my "to-do when less-lazy list" :)


All times are GMT -5. The time now is 07:40 AM.