I entered ‘systemctl --failed’ in the shell as a routine check, and discovered I do have an issue.
$ systemctl --failed
UNIT LOAD ACTIVE SUB DESCRIPTION
● shadow.service loaded failed failed Verify integrity of password and group files
I’m not sure how to resolve. I’d appreciate any detailed insturctions with a little explanation so that I understand [and hopefully could work through on my own in the future].
I had shutdown and now I’m at my machine again. In the meantime, shadow.service no longer failed although I have not made any changes.
[code]$ systemctl --failed
0 loaded units listed. Pass --all to see loaded but inactive units, too.
To show all installed unit files use ‘systemctl list-unit-files’.
$ systemctl status shadow.service
● shadow.service - Verify integrity of password and group files
Loaded: loaded (/usr/lib/systemd/system/shadow.service; static; vendor preset: disabled)
Active: inactive (dead)[/code]
Any reason this might have happened, and any suggestions?
I will continue to check for failed systemd services, and if it happens again I’ll run the status and post the results.
When there is an update for any application or service that uses the shadow.service, a reboot is often required for the system to adjust to the change.
I did receive a shadow.service failure again. So I ran the status and posted results below.
It looks like there is an invalid reference to ‘mysql’. How can I correct this?
Thanks!
[code]$ systemctl status shadow.service
● shadow.service - Verify integrity of password and group files
Loaded: loaded (/usr/lib/systemd/system/shadow.service; static; vendor preset: disabled)
Active: failed (Result: exit-code) since Thu 2016-04-21 10:35:56 CDT; 2min 12s ago
Process: 1162 ExecStart=/usr/bin/pwck -r (code=exited, status=2)
Main PID: 1162 (code=exited, status=2)
Apr 21 10:35:56 mike-pc systemd[1]: Starting Verify integrity of password and group files…
Apr 21 10:35:56 mike-pc pwck[1162]: user ‘mysql’: directory ‘/var/lib/mysql’ does not exist
Apr 21 10:35:56 mike-pc pwck[1162]: pwck: no changes
Apr 21 10:35:56 mike-pc systemd[1]: shadow.service: Main process exited, code=exited, status=2/INVALIDARGUMENT
Apr 21 10:35:56 mike-pc systemd[1]: Failed to start Verify integrity of password and group files.
Apr 21 10:35:56 mike-pc systemd[1]: shadow.service: Unit entered failed state.
Apr 21 10:35:56 mike-pc systemd[1]: shadow.service: Failed with result ‘exit-code’.[/code]
Never mind, removing the mysql user can cause other issues.
First check for a /etc/groups.pacnew, pacorig, or pacsave file, there may have been an update to this file.
If so merge any changes, if not then as a fix run “grpck” and “pwck”, enter 'yes" to add the correct entries.