Fred K Ollinger on Sun, 26 May 2002 21:20:14 +0200 |
I have a perl util (anyone who wants can have a copy) that distributes passwds to many machines, it takes a list of passwds, then it adds some to the passwd list so one could change their passwd on one machine, and it will be soon be changed on all other machines. My scripts all work out of cron and work flawlessly, but someoneo pointed out that I was asking for a race condition which would hose the passwd file if another process tried to access passwd file at the same time. The debian shadow source code makes use of a c-interface for passwd locking, but I can't find any perl interface in cpan nor anywhere else. Is there such a util for passwd locking in perl? I will write one if I need to, but I'd rather save the work instead of reinventing the wheel. Thanks. Fred Ollinger (follinge@sas.upenn.edu) CCN sysadmin ______________________________________________________________________ Philadelphia Linux Users Group - http://www.phillylinux.org Announcements-http://lists.phillylinux.org/mail/listinfo/plug-announce General Discussion - http://lists.phillylinux.org/mail/listinfo/plug
|
|