Bug 309132 - avahi-daemon and avahi-dnsconfd claims to be dead after boot.
Summary: avahi-daemon and avahi-dnsconfd claims to be dead after boot.
Status: RESOLVED FIXED
Alias: None
Product: openSUSE 10.3
Classification: openSUSE
Component: GNOME (show other bugs)
Version: Beta 3
Hardware: x86-64 Other
: P5 - None : Major (vote)
Target Milestone: ---
Assignee: Mauro Parra Miranda
QA Contact: E-mail List
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-09-10 09:41 UTC by Ladislav Michnovic
Modified: 2007-09-13 21:03 UTC (History)
1 user (show)

See Also:
Found By: ---
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
Patch for this bug, according to jpr's comment. (1.21 KB, text/x-patch)
2007-09-13 20:50 UTC, Mauro Parra Miranda
Details
Patch for this bug, according to jpr's comment. (1.21 KB, patch)
2007-09-13 21:03 UTC, Mauro Parra Miranda
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ladislav Michnovic 2007-09-10 09:41:30 UTC
I have installed my computer and chacked these daemons if they are running:
/etc/init.d/avahi-daemon status
Checking for Avahi daemon:                             dead
/etc/init.d/avahi-dnsconfd status
Checking for Avahi DNS Configuration daemon:                      dead

but they are not running.
Comment 1 JP Rosevear 2007-09-10 14:46:57 UTC
jpr@rook:~> /etc/init.d/avahi-daemon status
Checking for Avahi daemon: Failed to open PID file: Permission denied
                                                                      dead
jpr@rook:~> /etc/init.d/avahi-daemon status
Checking for Avahi daemon: Failed to open PID file: Permission denied
                                                                      dead

Its not actually dead.  The pid file is just not accessible because avahia-daemon via libdaemon tries to open it read/write instead of just read as a regular user when passed the -c option.
Comment 3 JP Rosevear 2007-09-10 14:51:01 UTC
Lowering severity, since the daemons aren't actually dead.
Comment 4 JP Rosevear 2007-09-10 17:22:21 UTC
From lennart upstream:

If I remember correctly I open it as RDWR there because of a limitation
of the file locking APIs on some OSes, where locking files you don't
have opened as O_RDWR doesn't work.

However, I agree that the bug report mentioned is worth fixing. So it
might be advisable to add some code to reopen the file as O_RDONLY if
O_RDWR fails, and also to try F_RDLCK as a fallback if F_WRLCK
fails. That should be reasonably safe even on more exotic OSes.

If have prepared a patch for this in SVN r131 (although I didn't test
it) If this works for you I will ship this in the next release of
Comment 5 Gary Ekker 2007-09-11 17:23:12 UTC
Mauro can you get this patch in before the end of this week?
Comment 6 JP Rosevear 2007-09-11 17:23:33 UTC
The patch is actually for libdaemon FYI.
Comment 7 Mauro Parra Miranda 2007-09-13 20:50:58 UTC
Created attachment 163991 [details]
Patch for this bug, according to jpr's comment.
Comment 8 Mauro Parra Miranda 2007-09-13 20:56:16 UTC
Applied patch suggested in comment #4. Submitted and tested --for compilation-- via abuild & mbuild. 

In sake of completness, the patch was added to the bug.

Test packages available here: 

http://w3.suse.de/~mauro/bnc-309192/
Comment 9 Mauro Parra Miranda 2007-09-13 21:00:05 UTC
The right url is: 

http://w3.suse.de/~mauro/bnc-309132/
Comment 10 Mauro Parra Miranda 2007-09-13 21:03:12 UTC
Created attachment 163993 [details]
Patch for this bug, according to jpr's comment.