Tom Diehl on 19 Aug 2005 20:03:43 -0000 |
On Fri, 19 Aug 2005, Michael C. Toren wrote: On Thu, Aug 18, 2005 at 10:32:29PM -0400, Tom Diehl wrote:On Thu, 18 Aug 2005, John Von Essen wrote:Use "vipw" to edit the password file when making these types of changes, DONT simply edit /etc/passwd.
vipw(8) locks the password file using the same locking mechanism that passwd(1), chfn(1), useradd(8), etc all do, which means you avoid concurrent update problems. Additionally, many implementations of vipw will merge the appropriate fields of the passwd and shadow files together for the editor session, and unmerge the fields and store them in the appropriate file when you save and exit. While the implementation of vipw many Linux distributions include does not support this feature, it does permit you to edit the shadow file by specifying a command line argument ("-s") while still locking the file appropriately.
Regards, Tom ___________________________________________________________________________ Philadelphia Linux Users Group -- http://www.phillylinux.org Announcements - http://lists.phillylinux.org/mailman/listinfo/plug-announce General Discussion -- http://lists.phillylinux.org/mailman/listinfo/plug
|
|