D-BUS support
I'm attaching a small patch which fixes a build error when dbus support is enabled.
BTW, I noticed that when dbus support is enabled udev becomes much slower (is this a serialization side effect of the dbus daemon?):
# time /etc/init.d/udev start Creating initial udev device nodes...done.
real 0m32.795s
user 0m0.314s
sys 0m0.376s
#
I can see with ps that there are a big number of processes waiting to complete, and I verified with strace that they are waiting for a reply from the dbus daemon, e.g.:
root@wonderland:/USR3/src/P/udev/udev-0.014# strace -v -p 14583
Process 14583 attached - interrupt to quit
select(4, [3], [], [3], NULL) = 1 (in [3])
read(3, "OK\r\n", 2048) = 4
select(4, [], [3], [3], NULL) = 1 (out [3])
write(3, "BEGIN\r\n", 7) = 7
writev(3, [{"l\1\0\0x\0\0\0\0\0\0\0\1\0\0\0\1o\0\0\25\0\0\0/org/fre"..., 120}, {"", 0}], 2) = 120
gettimeofday({1074981742, 670060}, NULL) = 0
select(4, [3], [], [3], {15, 0}) = 1 (in [3], left {0, 98000})
read(3, 0x805c250, 2048) = -1 ECONNRESET (Connection reset by peer)
close(3) = 0
gettimeofday({1074981757, 578538}, NULL) = 0
open("/udev/.udev.tdb", O_RDWR|O_CREAT, 0644) = 3
[...]Looks like it's even timing out from time to time:
root@wonderland:/USR3/src/P/udev/udev-0.014# dpkg -i ../udev_0.014-1_i386.deb (Lettura del database ... 98030 file e directory attualmente installati.) Preparativi per il rimpiazzo di udev 0.014-1 (usando ../udev_0.014-1_i386.deb) ... Spacchetto il rimpiazzo di udev ... Configuro udev (0.014-1) ... Installo la nuova versione del file di configurazione /etc/init.d/udev ... Restarting system message bus: dbus-1. Creating initial udev device nodes...cannot acquire org.kernel.udev service, error org.freedesktop.DBus.Error.NoReply: Message did not receive a reply'done.
root@wonderland:/USR3/src/P/udev/udev-0.014#
Signature · 2 lines
ciao, | Marco | [4290 st4MxE3BJ1VvA]
udev_dbus.c +1 -0
@@ -12,6 +12,7 @@#include "udev.h" #include "udev_version.h" #include "udev_dbus.h" +#include "logging.h" /** variable for the connection the to system message bus or #NULL
Quoted 7 lines · Marco d'Itri
# time /etc/init.d/udev start Creating initial udev device nodes...done.real 0m32.795s
user 0m0.314s
sys 0m0.376s
#
For me (700MHz laptop) I get these results:
# time /etc/init.d/udev start Creating initial udev device nodes...done. /dev management daemon (udev) enabled.
real 0m5.447s user 0m1.459s sys 0m2.401s
Quoted 3 lines
I can see with ps that there are a big number of processes waiting to complete, and I verified with strace that they are waiting for a reply from the dbus daemon, e.g.:
[snip]
I do see this thought.
Quoted 1 line
Looks like it's even timing out from time to time:
[snip]
Quoted 1 line
Creating initial udev device nodes...cannot acquire org.kernel.udev service, error org.freedesktop.DBus.Error.NoReply: Message did not receive a reply'done.
And that as well.
Ross
Signature · 17 lines
Ross Burton mail: [email protected] jabber: [email protected] www: http://www.burtonini.com./ PGP Fingerprint: 1A21 F5B0 D8D0 CFE3 81D4 E25A 2D09 E447 D0B4 33DF ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 9 lines · Ross Burton
For me (700MHz laptop) I get these results:
# time /etc/init.d/udev start Creating initial udev device nodes...done. /dev management daemon (udev) enabled.real 0m5.447s user 0m1.459s sys 0m2.401s
How many nodes do you have?
md@wonderland:~$ find /udev/ -type b -or -type c | wc -l 103 md@wonderland:~$
Signature · 13 lines
ciao, | Marco | [4299 aszI.AznZHV1Y] ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 10 lines · Marco d'Itri
Quoted 8 lines · Ross Burton
For me (700MHz laptop) I get these results:
# time /etc/init.d/udev start Creating initial udev device nodes...done. /dev management daemon (udev) enabled.real 0m5.447s user 0m1.459s sys 0m2.401s
Quoted 5 lines
How many nodes do you have?
md@wonderland:~$ find /udev/ -type b -or -type c | wc -l 103 md@wonderland:~$
$ find /udev/ -type b -or -type c | wc -l 411 $
Of couse that does include 256 rfcomm devices:
$ find /udev/ -type b -or -type c | grep -v rfcomm | wc -l 155
Ross
Signature · 17 lines
Ross Burton mail: [email protected] jabber: [email protected] www: http://www.burtonini.com./ PGP Fingerprint: 1A21 F5B0 D8D0 CFE3 81D4 E25A 2D09 E447 D0B4 33DF ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 6 lines · David Zeuthen
Quoted 2 lines
Creating initial udev device nodes...cannot acquire org.kernel.udev service, error org.freedesktop.DBus.Error.NoReply: Message did not receive a reply'done.
I've seen this behaviour when the system message bus (dbus-daemon-1 --system) isn't running or the udev policy file for the system message bus is missing. It seems you're experiencing the latter
No, the file is there and the daemon is running.
If I stop the daemon then udev is quick again.
The error does not always happen, only a few times. Maybe the accept queue for the daemon is not large enough?
Signature · 13 lines
ciao, | Marco | [4335 di6A/vxQDzrt2] ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net [email protected] https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel