Project

General

Profile

Actions

Bug #2535

closed

Avahi package installs, but fails to start

Added by Jostein Elvaker Haande almost 12 years ago. Updated almost 12 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Start date:
07/04/2012
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
Affected Version:
2.1
Affected Plus Version:
Affected Architecture:
amd64

Description

I'm having an issue with the Avahi package under pfSense 2.1. The package installs, but fails to start, as it seems like some of the package dependencies aren't met.

Avahi package version: 0.6.25_2
pfSense build: 2.1-BETA0 (amd64) built on Wed Jul 4 07:34:55 EDT 2012 FreeBSD 8.3-RELEASE-p3

This is what is found in the system logs when trying to start the package:

  1. START OF LOG ###

Jul 4 22:07:21 pfsense avahi-daemon38143: Found user 'avahi' (UID 558) and group 'avahi' (GID 558).
Jul 4 22:07:21 pfsense avahi-daemon38143: Successfully dropped root privileges.
Jul 4 22:07:21 pfsense avahi-daemon38143: avahi-daemon 0.6.29 starting up.
Jul 4 22:07:21 pfsense avahi-daemon38143: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 4 22:07:21 pfsense avahi-daemon38143: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 4 22:07:21 pfsense avahi-daemon38143: dbus_bus_get_private(): Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
Jul 4 22:07:21 pfsense avahi-daemon38143: dbus_bus_get_private(): Failed to connect to socket /var/run/dbus/system_bus_socket: No such file or directory
Jul 4 22:07:21 pfsense avahi-daemon38143: WARNING: Failed to contact D-Bus daemon.
Jul 4 22:07:21 pfsense avahi-daemon38143: WARNING: Failed to contact D-Bus daemon.
Jul 4 22:07:21 pfsense avahi-daemon38143: avahi-daemon 0.6.29 exiting.

  1. END OF LOG ###

Any clues on why this fails?

Actions #1

Updated by Carlos Cesario almost 12 years ago

I usage this to solve temporary the problem.

In shell console:

# mkdir -p /var/run/dbus/
# pw user add messagebus
# chown messagebus:messagebus /var/run/dbus
# dbus-daemon --system

After this I enable service in PFsense GUI

And the process start :)

Jul 5 12:41:06 pfdev check_reload_status: Syncing firewall
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Found user 'avahi' (UID 558) and group 'avahi' (GID 558).
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Successfully dropped root privileges.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: avahi-daemon 0.6.29 starting up.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 5 12:41:06 pfdev avahi-daemon[6826]: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Loading service file /usr/pbi/avahi-amd64/etc/avahi/services/sftp-ssh.service.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Loading service file /usr/pbi/avahi-amd64/etc/avahi/services/ssh.service.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Joining mDNS multicast group on interface em0.IPv4 with address 192.168.100.1.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: New relevant interface em0.IPv4 for mDNS.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Network interface enumeration completed.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Registering new address record for fe80::20c:29ff:fe83:621a on em0.*.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Registering new address record for 192.168.100.1. on em0.IPv4.
Jul 5 12:41:06 pfdev avahi-daemon[6826]: Registering HINFO record with values 'AMD64'/'FREEBSD'.
Jul 5 12:41:07 pfdev avahi-daemon[6826]: Server startup complete. Host name is pfdev.local. Local service cookie is 2798121152.
Jul 5 12:41:08 pfdev avahi-daemon[6826]: Service "pfdev" (/usr/pbi/avahi-amd64/etc/avahi/services/ssh.service) successfully established.
Jul 5 12:41:08 pfdev avahi-daemon[6826]: Service "pfdev" (/usr/pbi/avahi-amd64/etc/avahi/services/sftp-ssh.service) successfully established.

Maybe the problem is in dbus startup process

Actions #2

Updated by Jim Pingle almost 12 years ago

Real fix is pending - just needs pushed - should be up shortly.

Actions #3

Updated by Jim Pingle almost 12 years ago

  • Status changed from New to Feedback
  • % Done changed from 0 to 100

Applied in changeset commit:b012ea0f60785020b8f697300fe8e78da2e5e45d.

Actions #4

Updated by Carlos Cesario almost 12 years ago

Avahi process now start, but dbus service no.

Jul 5 14:27:35 pfdev check_reload_status: Syncing firewall
Jul 5 14:27:46 pfdev check_reload_status: Syncing firewall
Jul 5 14:27:47 pfdev root: /usr/pbi/avahi-amd64/etc/rc.d/dbus: WARNING: failed to start dbus
Jul 5 14:27:52 pfdev avahi-daemon32912: Found user 'avahi' (UID 558) and group 'avahi' (GID 558).
Jul 5 14:27:52 pfdev avahi-daemon32912: Successfully dropped root privileges.
Jul 5 14:27:52 pfdev avahi-daemon32912: avahi-daemon 0.6.29 starting up.
Jul 5 14:27:52 pfdev avahi-daemon32912: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 5 14:27:52 pfdev avahi-daemon32912: WARNING: No NSS support for mDNS detected, consider installing nss-mdns!
Jul 5 14:27:52 pfdev avahi-daemon32912: Loading service file /usr/pbi/avahi-amd64/etc/avahi/services/sftp-ssh.service.
Jul 5 14:27:52 pfdev avahi-daemon32912: Loading service file /usr/pbi/avahi-amd64/etc/avahi/services/ssh.service.
Jul 5 14:27:52 pfdev avahi-daemon32912: Network interface enumeration completed.
Jul 5 14:27:52 pfdev avahi-daemon32912: Registering HINFO record with values 'AMD64'/'FREEBSD'.
Jul 5 14:27:52 pfdev avahi-daemon32912: Server startup complete. Host name is pfdev.tecnomega.local. Local service cookie is 1792877340.
Jul 5 14:27:52 pfdev avahi-daemon32912: Service "pfdev" (/usr/pbi/avahi-amd64/etc/avahi/services/ssh.service) successfully established.
Jul 5 14:27:52 pfdev avahi-daemon32912: Service "pfdev" (/usr/pbi/avahi-amd64/etc/avahi/services/sftp-ssh.service) successfully established.

Actions #5

Updated by Jim Pingle almost 12 years ago

Try to run /usr/pbi/avahi-amd64/etc/rc.d/dbus onestart

See what happens there - I wiped away all traces of avahi and dbus from my vm and reinstalled and it worked fine for me.

Actions #6

Updated by Carlos Cesario almost 12 years ago

/usr/pbi/avahi-amd64/etc/rc.d/dbus onestart

Starting dbus.
Failed to start message bus: Could not get UID and GID for username "messagebus" 
/usr/pbi/avahi-amd64/etc/rc.d/dbus: WARNING: failed to start dbus
Actions #7

Updated by Jim Pingle almost 12 years ago

Are you on a current snap and getting the PBI from our repo? I delete the messagebus and avahi users and then re-add the package and they come back as expected and it starts up without any special intervention.

Actions #8

Updated by Jostein Elvaker Haande almost 12 years ago

Carlos Cesario wrote:

I usage this to solve temporary the problem.

In shell console:

[...]

This also works on this end, but the folder is deleted upon reboot of the machine. Other than that, it seems to be working as expected.

Actions #9

Updated by Carlos Cesario almost 12 years ago

I try again, removing the avahi and messagebus users.
And install again the avahi package

Downloading http://files.pfsense.org/packages/amd64/8/All/avahi-0.6.29-amd64.pbi ...

After complete, onlye the user avahi is created.

avahi:*:558:558:User &:/home/avahi:/bin/sh

My system is not in last snap.

Actions #10

Updated by Jim Pingle almost 12 years ago

Update to the latest snap and try again, it is working from a bare install on a new snap here. I really don't want to have to manually add the messagebus user during the install process if I can avoid it.

Actions #11

Updated by Carlos Cesario almost 12 years ago

Jim,

I install new VM with last snap

FreeBSD pfSense.localdomain 8.3-RELEASE-p3 FreeBSD 8.3-RELEASE-p3 #0: Thu Jul 5 03:23:23 EDT 2012 root@FreeBSD_8.3_pfSense_2.1.snaps.pfsense.org:/usr/obj./usr/pfSensesrc/src/sys/pfSense_SMP.8 amd64

And the avahi package works as expected.
The users avahi and messagebus are created.

But I have a bit detail. In remove process the users avahi and messagebus are not removed. Is it normal!?

Actions #12

Updated by Jim Pingle almost 12 years ago

Yes that's normal. Probably a side effect of how the PBI system adds the PBI users, that's a fairly new feature of the PBI tools from PC-BSD. Not really hurting anything as the users really have no privileges and no usable password or other capabilities.

Actions #13

Updated by Carlos Cesario almost 12 years ago

Ok.

So I believe this may be considered as solved :)

Actions #14

Updated by Jim Pingle almost 12 years ago

  • Status changed from Feedback to Resolved
Actions #15

Updated by Carlos Cesario almost 12 years ago

Thank you ;)

Actions #16

Updated by Jostein Elvaker Haande almost 12 years ago

Hello again, I just tried the most recent snapshot (ref: 2.1-BETA0 (amd64) built on Sat Jul 7 19:53:29 EDT 2012).

The directory /var/run/dbus isn't created upon reboot/re installation of the package. Nor is the DBUS service started. As a result, the avahi service fails to start.

Actions #17

Updated by Jim Pingle almost 12 years ago

I just installed it on a VM using that same snapshot. The VM did not have (nor ever had) Avahi installed, so it had no /var/run/dbus. After installing, I went to Avahi's settings, enabled, entered a domain, pressed Save, and it created /var/run/dbus and started up fine.

Do you get an error if you go to the shell and run:
/usr/local/etc/rc.d/avahi-daemon.sh restart

Actions

Also available in: Atom PDF