Bug 845978 - KeyError: 'getpwuid(): uid not found: 0'
KeyError: 'getpwuid(): uid not found: 0'
Status: CLOSED CANTFIX
Product: Fedora
Classification: Fedora
Component: systemd (Show other bugs)
17
Unspecified Unspecified
unspecified Severity unspecified
: ---
: ---
Assigned To: systemd-maint
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2012-08-06 07:27 EDT by Jan Hutař
Modified: 2012-08-28 09:20 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2012-08-06 09:13:00 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Jan Hutař 2012-08-06 07:27:11 EDT
Description of problem:
Restarting osa-dispatcher service produces traceback in /var/log/messages.


Version-Release number of selected component (if applicable):
systemd-44-17.fc17.x86_64
osa-dispatcher-5.11.4-1.fc17.noarch
python-2.7.3-7.2.fc17.x86_64


How reproducible:
always on one mine setup


Steps to Reproduce:
1. Have system with osa-dispatcher which denies to start (state "Active: failed (Result: exit-code)")
2. Attempt to restart osa-dispatcher and follow /var/log/messages


Actual results:
# service osa-dispatcher restart
Redirecting to /bin/systemctl restart  osa-dispatcher.service
Aug  7 21:50:38 <host> osa-dispatcher[31159]: Traceback (most recent call last):
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/site.py", line 567, in <module>
Aug  7 21:50:38 <host> osa-dispatcher[31159]: main()
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/site.py", line 549, in main
Aug  7 21:50:38 <host> osa-dispatcher[31159]: known_paths = addusersitepackages(known_paths)
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/site.py", line 278, in addusersitepackages
Aug  7 21:50:38 <host> osa-dispatcher[31159]: user_site = getusersitepackages()
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/site.py", line 253, in getusersitepackages
Aug  7 21:50:38 <host> osa-dispatcher[31159]: user_base = getuserbase() # this will also set USER_BASE
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/site.py", line 243, in getuserbase
Aug  7 21:50:38 <host> osa-dispatcher[31159]: USER_BASE = get_config_var('userbase')
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/sysconfig.py", line 521, in get_config_var
Aug  7 21:50:38 <host> osa-dispatcher[31159]: return get_config_vars().get(name)
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/sysconfig.py", line 425, in get_config_vars
Aug  7 21:50:38 <host> osa-dispatcher[31159]: _CONFIG_VARS['userbase'] = _getuserbase()
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/sysconfig.py", line 183, in _getuserbase
Aug  7 21:50:38 <host> osa-dispatcher[31159]: return env_base if env_base else joinuser("~", ".local")
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/sysconfig.py", line 169, in joinuser
Aug  7 21:50:38 <host> osa-dispatcher[31159]: return os.path.expanduser(os.path.join(*args))
Aug  7 21:50:38 <host> osa-dispatcher[31159]: File "/usr/lib64/python2.7/posixpath.py", line 260, in expanduser
Aug  7 21:50:38 <host> osa-dispatcher[31159]: userhome = pwd.getpwuid(os.getuid()).pw_dir
Aug  7 21:50:38 <host> osa-dispatcher[31159]: KeyError: 'getpwuid(): uid not found: 0'
Aug  7 21:50:38 <host> systemd[1]: osa-dispatcher.service: main process exited, code=exited, status=1
Aug  7 21:50:38 <host> systemd[1]: Unit osa-dispatcher.service entered failed state.


Expected results:
Should work


Additional info:
I'm not sure if this is systemd issue, but paths in the traceback do not indicate it is osa-dispatcher issue, so I have filled this against systemd.
Comment 2 Michal Schmidt 2012-08-06 09:13:00 EDT
(In reply to comment #0)
> I'm not sure if this is systemd issue, but paths in the traceback do not
> indicate it is osa-dispatcher issue, so I have filled this against systemd.

You mean the paths to some python modules? systemd is not written in python.
Also the error messages are clearly prefixed with "osa-dispatcher[31159]", which are the process name and PID.

I'd reassign it to the osa-dispatcher component, but I cannot find it in the repository. Is it a Fedora package?
Instead I'm closing this as CANTFIX.
Comment 3 Jan Pazdziora 2012-08-28 09:20:49 EDT
Thanks. It's a SELinux issue caused for labelling of /etc/passwd in Fedora 17. I'll fix it in Spacewalk.

Note You need to log in before you can comment on or make changes to this bug.