Unknown username "polkit" in message bus.....

I have enabled dbus and hald in rc.conf.
but when starting the system, it error pops up,
says:
Code:
starting dbus
Unknown username "polkit" in message bus configuration file
Unknown username "avahi" in message bus configuration file
starting hald..
somehow, i cannot starx no more..

could someone help with it?
thanks a lot in adv..
 
i am new to Freebsd, normally use Gentoo,
is there a way to re-compile all existing packages? or could fix it simply!
thanks
 
Don't avahi me in?

It sounds like you overwrote your /etc/passwd when you upgraded.
You can manually add the users polkit and avahi (you probably will need messagebus & haldaemon as well) with adduser(8). I don't think the UID or GID are strict, & using /sbin/nologin as the shell is probably an excellent idea.
(extracted from my /etc/passwd
Code:
messagebus:*:556:556:D-BUS Daemon User:/nonexistent:/sbin/nologin
polkit:*:562:562:PolicyKit Daemon User:/nonexistent:/sbin/nologin
haldaemon:*:560:560:HAL Daemon User:/nonexistent:/sbin/nologin
avahi:*:558:558:Avahi Daemon User:/nonexistent:/sbin/nologin
& /etc/group)
Code:
messagebus:*:556:
polkit:*:562:
haldaemon:*:560:
avahi:*:558:
 
I have manually added those lines, after rebooting i found the error still there! it is wired!
 
You can't add them manually by editing /etc/passwd. Delete them from /etc/passwd and use `vipw` and add them (`env EDITOR=ee vipw` if you are not familar with vi).
 
crsd said:
You can't add them manually by editing /etc/passwd. Delete them from /etc/passwd and use `vipw` and add them (`env EDITOR=ee vipw` if you are not familar with vi).

thank you, yes i do use vi.
i am going to have a try..:)
 
thanks a lot guys, i have fixed it used this way:

Code:
cd /usr/ports/sysutils/policykit/
make reinstall reinstall clean

cd /usr/ports/net/avahi-app
make reinstall reinstall clean

also i have tried the way as crsd pointed, it helped me as well. thanks a lot.:)
 
crsd said:
You can't add them manually by editing /etc/passwd. Delete them from /etc/passwd and use `vipw` and add them (`env EDITOR=ee vipw` if you are not familar with vi).
IIRC, you can just run # /usr/sbin/pwd_mkdb /etc/passwd on the munged^H^H^H^H^H^Hedited file, no?
 
failed initializing dbus and hald...

I have had this same issue as well, I know the cause of my FUBAR, but the quoted text below is basically what I did to fix it, and the only thing I had to do to fix it.

the only difference is I had to do a "make deinstall" as teh second step in each one and a "make install clean" as a third and final step and then both of these problems were gone.

FreeBSD 8.0-RELEASE

I am still having mouse issues in KDE though, but it now works fine on the command line...
I also had to edit /etc/rc.conf to change my mouse bus type to "usm0" as it was set as something else, I forgot what now. additionally moused_enable was set to off. this was probably the most important thing to change!!

Anyway I need to get some sleep, hope this helps someone in the future, and if it does. please remember to login, and quote this message stating it worked (or at least put in a post referencing my post and stating that it worked, as if you do you will then be helping someone else out in the future. My biggest complaint about using the internet for troubleshooting is when you find a post from years ago that is exactly what you are having a problem with and it does not have the solution, or has several and no one said which one worked.

Good luck, and I referrenced linked this forum post from my website to help get people here if they need this help. http://www.joelperryporductions.com

NAC said:
thanks a lot guys, i have fixed it used this way:

Code:
cd /usr/ports/sysutils/policykit/
make reinstall reinstall clean

cd /usr/ports/net/avahi-app
make reinstall reinstall clean

also i have tried the way as crsd pointed, it helped me as well. thanks a lot.:)
 
since I am not yet allowed to edit my posts... you can also hit the thanks button on the post that helped you. Enjoy and most important have fun, if you are not, then go find something else to do.

----------------------------------------------------------
1984
At the Winter USENIX/UniForum meeting, AT&T describes its support policy for Unix:
"No advertising, no support, no bug fixes, payment in advance."

----------------------------------------------------------
 
finndo said:
I am still having mouse issues in KDE though, but it now works fine on the command line...
I also had to edit /etc/rc.conf to change my mouse bus type to "usm0" as it was set as something else, I forgot what now. additionally moused_enable was set to off. this was probably the most important thing to change!!
Don't. Remove the moused_enable line completely. You have an USB mouse. It's automatically loaded. Make sure both hald and dbus are running.
 
This is interesting stuff!!

I'm trying to set up x11-wm/awesome, x11/rxvt-unicode and www/firefox under x11/Xorg on 7.3-STABLE. I'm able to % xinit, but not able to move the mouse or anything.

It complains about the user "messagebus" not present...

Is it really safe to manually adding messagebus user using vi? I do not think the % /usr/sbin/pwd_mkdb /etc/passwd works quite as expected (complains about the standard line 3).

OFFTOPIC: Is it possible in some way to speed up tty switching from xorg to normal (alt+ctrl+F1) in the kernel in some way?
 
rusma said:
OFFTOPIC: Is it possible in some way to speed up tty switching from xorg to normal (alt+ctrl+F1) in the kernel in some way?

When moused is running in normal mode (as opposed to autostarted for USB mice), it eliminates the long pause switching back to X from console.
 
wblock said:
When moused is running in normal mode (as opposed to autostarted for USB mice), it eliminates the long pause switching back to X from console.

Does this have to do with the kernel?
 
rusma said:
Does this have to do with the kernel?

Not to my knowledge, more like an interaction between X and moused. Try it: switch to and from X from a console, then set moused_enable="YES", restart, and try it again. I think it's the switch from console back to X that is really long if moused isn't explicitly enabled but autostarted by USB.
 
wblock said:
Not to my knowledge, more like an interaction between X and moused. Try it: switch to and from X from a console, then set moused_enable="YES", restart, and try it again. I think it's the switch from console back to X that is really long if moused isn't explicitly enabled but autostarted by USB.

Thanks. I'll sure try that out.

What about the rest ONTOPIC question of mine?
 
Re:

Sorry for bumping this four years later, but I have a similar problem as described in the first post on a completely fresh install of Xorg (using Ports) on FreeBSD 9.2-RELEASE, except that instead of "avahi" I have:

Code:
Unknown username "haldaemon" in message bus configuration file

I tried this solution:

NAC said:
thanks a lot guys, i have fixed it used this way:

Code:
cd /usr/ports/sysutils/policykit/
make reinstall reinstall clean

cd /usr/ports/net/avahi-app
make reinstall reinstall clean

Unfortunately, it didn't work, and I now have an additional line reading

Code:
Unknown username "avahi" in message bus configuration file

How do I roll back to the previous situation, and what can I do to fix the initial issue?

Edit: For "haldaemon" I found the following topic https://forums.freebsd.org/viewtopic.php?f=5&t=694&p=3710&hilit=dbus+unknown+username#p3710. Can someone confirm that this still works in FreeBSD 9.2-R? I don't want to screw things up more than they are...

The complete set of messages I get for dbus and hald are:
Code:
Starting dbus.
Unknown username "polkit" in message bus configuration file
Unknown username "haldaemon" in message bus configuration file
Unknown username "avahi" in message bus configuration file
Failed to start message bus: Could not get UID and GID for username "messagebus"
/etc/rs: WARNING: failed to start dbus
install: unknown user polkit
chown: polkit: illegal user name
install: unknown user haldaemon
install: unknown user haldaemon
install: unknown user haldaemon
Starting hald.

hald starts fine, as far as I can see.
 
Try doing vipw(8) as root. Save and quit without making any modifications. It sometimes happens that passwd and pwd.db go out of sync.
 
Back
Top