dbus doesn't start

Bug #19577 reported by torb
8
Affects Status Importance Assigned to Milestone
dbus (Ubuntu)
Fix Released
Medium
Martin Pitt

Bug Description

On bootoing the 2.6.12 kernel, I get:
* Starting Hardware Abstraction Layer:
run-parts: /etc/dbus-1/event.d/20hal exited with return code 2

and when I start Gnome, a "Error, failed to initialize Hal" message pops up.

hald isn't running.

If I run "sudo hald --daemon=no --verbose=yes" everything works just fine.

However if I start hald as a daemon, it shuts down after a couple of minutes.

"sudo /etc/dbus-1/event.d/20hal start" doesn't say anything and waits until hald
has died.

Everything works just fine with the 2.6.10 kernel.

I'm attaching the output of "sudo hald --daemon=no --verbose=yes".

What can I do to help you trobleshoot this?

Revision history for this message
torb (torrb) wrote :

Created an attachment (id=3208)
Output of nondaemonized hal

Revision history for this message
Runar Ingebrigtsen (ringe) wrote :

I have the exact same problem. Running breezy.

In related news; the proc battery interface shows "unknown" for charging state,
present state, remaining capacity, present voltage.

Could this be a kernel problem?

Revision history for this message
Runar Ingebrigtsen (ringe) wrote :

Just rebooted with kernel 2.6.10 - hald works fine now, seems to be a kernel
2.6.12 problem.

The proc battery interface also works fine with 2.6.10, but not 2.6.12.

Revision history for this message
torb (torrb) wrote :

I can confirm the same battery-behaviour here.

Revision history for this message
torb (torrb) wrote :

The latest kernel-update fixes this for me (hald works when starting 2.6.12-7
but not when starting 2.6.12-6).

Runar is this true for you to and should we close this bug.

Revision history for this message
Martin Pitt (pitti) wrote :

Awaiting confirmation from Runar.

Revision history for this message
Kent Nyberg (nyberg-kent) wrote :

I run 2.6.12-8-k7 in Breezy and have problems with hald not being started upon
boot aswell. I have not yet looked into it more detailed (and sort of lacks the
skills aswell), but it seems to not being started since when i log into gnome, I
get a message about hald not being run (Like the first comment on this bugreport).

Revision history for this message
Martin Pitt (pitti) wrote :

(In reply to comment #7)
> I run 2.6.12-8-k7 in Breezy and have problems with hald not being started upon
> boot aswell. I have not yet looked into it more detailed (and sort of lacks the
> skills aswell), but it seems to not being started since when i log into gnome, I
> get a message about hald not being run (Like the first comment on this bugreport).

OK, judging from some discussions on #ubuntu this still seems to be an issue.
Can you please create a full hal debug output as described in the second half of
https://wiki.ubuntu.com/DebuggingRemovableDevices ? Thanks

Revision history for this message
Kent Nyberg (nyberg-kent) wrote :

Created an attachment (id=3603)
The output of the debug of hal.

The output of:
sudo hald --daemon=no --verbose=yes 2>&1 | tee hal.log

Revision history for this message
Martin Pitt (pitti) wrote :

Thanks for the debug output.

00:43:57.234 [E] hald_dbus.c:2794: dbus_bus_get(): Failed to connect to socket
/var/run/dbus/system_bus_socket: No such file or directory

That looks sooo much like the issue we fixed in:

dbus (0.36.2-0ubuntu2) breezy; urgency=low

  * debian/dbus.postrm: Add back dropped DEBHELPER token to make rc2.d
    symlink generation and daemon start work again.

 -- Martin Pitt <email address hidden> Wed, 31 Aug 2005 12:38:17 +0200

Can you please check that you have the latest dbus?

Revision history for this message
Kent Nyberg (nyberg-kent) wrote :

The dbus package I have installed seems to be the version you talk about:
0.36.2-0ubuntu2.

I run "sudo apt-get update" and "sudo apt-get dist-upgrade" every day (twice a
day some times) so I should have the latest packages.
Tell me if there is anything else I can do. I can open an ssh-account on the
computer if you want to take a look by your self, or tell me what to
do and I will do it.

Revision history for this message
Martin Pitt (pitti) wrote :

> I run "sudo apt-get update" and "sudo apt-get dist-upgrade" every day (twice a
> day some times) so I should have the latest packages.

OK, but did you actually boot your box at any time after upgrading to 0ubuntu2?

> Tell me if there is anything else I can do. I can open an ssh-account on the
> computer if you want to take a look by your self, or tell me what to
> do and I will do it.

If you booted before and it didn't solve the problem, can you please watch
whether dbus is attempted to start at boot time and whether it succeeds? Does

  sudo /etc/init.d/dbus start

and restarting your Gnome session fix the problem (until next boot)?

Revision history for this message
Kent Nyberg (nyberg-kent) wrote :

I tried to reboot. I didn't see anything about hal or dbus (although I could
have missed it, but I dont think so).
When i logged into gnome, I got the message about hal not being started.
If i do "sudo /etc/init.d/dbus start" it starts, and when i logout/login to
gnome it works as it should.
Is there a way to be sure dbus/hal is not started upon boot? It seems strange
that its not started.

Revision history for this message
Martin Pitt (pitti) wrote :

(In reply to comment #13)

> Is there a way to be sure dbus/hal is not started upon boot? It seems strange
> that its not started.

Indeed, it is strange. Maybe it is a fallout from upgrading from some
intermediate development version; it certainly works when being installed from
scratch, and when upgrading from Hoary.

After boot, you can check whether dbus is running with

$ ls -l /var/run/dbus/

With a running dbus, there should be a "pid" file and a socket. What does

  $ ls /etc/rc2.d/*dbus*

say on your system? There should be a link "/etc/rc2.d/S12dbus" pointing to
/etc/init.d/dbus.

Revision history for this message
Kent Nyberg (nyberg-kent) wrote :

Could this be the problem? There is no file under /var/run/dbus, and there is no
file in rc2.d.
I guess the lack of file in rc2.d is the problem?

kent@Leviatan:~ $ ls -l /var/run/dbus/
totalt 0
kent@Leviatan:~ $ ls /etc/rc2.d/*dbus*
ls: /etc/rc2.d/*dbus*: Filen eller katalogen finns inte
kent@Leviatan:~ $

Revision history for this message
Martin Pitt (pitti) wrote :

(In reply to comment #15)
> Could this be the problem? There is no file under /var/run/dbus, and there is no
> file in rc2.d.
> I guess the lack of file in rc2.d is the problem?

Indeed it is. This does not happen with the current version, and neither on
upgrades, so the current package is fine.

Can you please run

  sudo update-rc.d -f dbus remove
  sudo update-rc.d dbus defaults 12

to fix it for you?

Thank you for your investigations!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.