|Summary:||passwd will run while vipw is running|
|Product:||[Retired] Red Hat Linux||Reporter:||fairlite|
|Component:||passwd||Assignee:||Cristian Gafton <gafton>|
|Status:||CLOSED NOTABUG||QA Contact:|
|Fixed In Version:||Doc Type:||Bug Fix|
|Doc Text:||Story Points:||---|
|Last Closed:||1999-04-01 06:07:38 UTC||Type:||---|
|oVirt Team:||---||RHEL 7.3 requirements from Atomic Host:|
|Cloudforms Team:||---||Target Upstream Version:|
Description fairlite 1998-12-31 21:55:37 UTC
On RedHat 5.1, if you run vipw, and someone concurrently runs passwd, passwd will run and modify /etc/passwd even though /etc/ptmp exists. This condition would result in a loss of the password change (or multiple changes) that occurred while vipw was in operation. I spoke with "oot" on LinuxNET and he verified the bug, which apparently also exists in 5.2. He asked me to report this bug here.
Comment 1 Preston Brown 1999-03-22 19:00:59 UTC
Michael: Do you think we should add a quick check to passwd to look for the lockfile, and exit if it exists?
Comment 2 Michael K. Johnson 1999-03-23 01:06:59 UTC
glibc vs. vipw locking difference passed on to Cristian to resolve
Comment 3 Cristian Gafton 1999-04-01 06:07:59 UTC
vipw can not lock the passwd file for an extended period of time. The locking mechanism has an algorithm that will make it avoid deadlocks from runaway processes (basically wait at most 10 sec before ignoring the lock and acquiring it for yourself) vipw will lock the database when it is updating it, checking that the timestamp was not modified in the meantime.