Comments (5)
Does running udevadm trigger
correct the permissions?
from eudev.
The problem is that you don't udevadm trigger late enough in the boot process. I couldn't pin point a good place to do it, but if you run udevadm trigger after boot is over, all the correct permissions and ownership are set. Note you don't need to mount /dev yourself and you should probably check mountpoint /dev before triggering. Sorry I can't help more, but I'm not familiar with the boot scripts.
from eudev.
ryao: it does
from eudev.
We do have to mount /dev ourselves, in the 'init' script in the initramfs, just before doing the switch_root:
mount -t devtmpfs devtmpfs /pup_new/dev
/pup_new will become / after the switch_root.
This explicit mount is required, we determined after some study of the subject.
A system that does not have an initramfs, that boots straight into the rootfs, does not have to explicitly mount /dev, the kernel does it.
By mounting it explicitly in the initramfs, the kernel will create it with all device nodes discovered so far.
After switch_root, the kernel will continue to populate /dev, as we replay uevents from /sys, by two means, after having started udevd (see /etc/rc.d/rc.sysinit):
```MODALIASES="ls /sys/bus/_/devices/_/modalias
"
...
load udevd
...
#replay uevents from /sys...
for ONEMODALIAS in $MODALIASES
do
ONEPATH="`dirname $ONEMODALIAS`"
if [ -e ${ONEPATH}/uevent ];then
echo add > ${ONEPATH}/uevent #generates an 'add' uevent.
sleep 0.02
fi
done
2.
and by calls to 'udevadm trigger <parameters>'
...in other words, all (relevant) events are getting replayed from /sys
Ah, I might have solved it, or rather identified the basic cause.
I just looked in /dev, and /dev/ttyUSB0 does have the correct ownership. This node got created later on, when I plugged in my 3G USB stick after bootup.
Ok, it seems that the "focused" replay of events from /sys, that we do in /etc/rc.d/rc.sysinit, rather than a broad "udevadm trigger" to replay everything -- which we avoided for various reasons -- is the cause of this problem.
This is probably enough of a lead for me to fix it. Thanks for the feedback.
from eudev.
OK, I have implemented a fix in Puppy Linux.
We can consider this one closed.
from eudev.
Related Issues (20)
- undefined reference to `epoll_create1' HOT 4
- Homepage for eudev and releases HOT 1
- Plan for new release? HOT 1
- ata path_id HOT 10
- ata path_id HOT 1
- no db file to read /run/udev/data/c13:83: No such file or directory HOT 4
- cd/dvd - lost HOT 1
- 3.2.12 tarball seems broken HOT 3
- libgudev requires libudev >= 251, but eudev just provides version 243 HOT 20
- make appimage or binary file, it run every HOT 1
- Any updates for libgudev/eudev? HOT 2
- Android Cross Compilation Eudev Error HOT 1
- Battery status remains unchanged with eudev pre 3.2.14 and libgudev 238 HOT 1
- Operator `:=` not preventing further assignments to `RUN`
- Not seeing rules in /usr/local/lib/udev/rules.d
- Video group grants access to two distinct hardware categories HOT 3
- Adelie Linux misses /dev/disk/by-label symlink to sr0 HOT 2
- nvme issue
- CONTRIBUTING: update HOT 2
- inotify_add_watch(6, /dev/loop0p1, 10) failed: No such file or directory
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from eudev.