lckpwdf man page on Tru64

Man page or keyword search:  
man Server   12896 pages
apropos Keyword Search (all sections)
Output format
Tru64 logo
[printable version]

lckpwdf(3)							    lckpwdf(3)

NAME
       lckpwdf,	 ulckpwdf  -  co-ordinates modification access to the password
       file

SYNOPSIS
       int lckpwdf( void ); int ulckpwdf( void );

LIBRARY
       SVR4 Library (libsvr4)

DESCRIPTION
       The /etc/.pwd.lock is the lock file.  It is used to coordinate  modifi‐
       cation  access  to the password file /etc/passwd.  lckpwdf() and ulckp‐
       wdf() functions are routines that are used to gain modification	access
       to  the	password  files,  through the lock file.  A process first uses
       lckpwdf() function to lock the lock file and  to	 block	other  threads
       attempting  to use lckpwdf() function, thereby gaining exclusive rights
       to modify the /etc/passwd password  file.   Upon	 completing  modifica‐
       tions, a process should release the lock on the lock file and unblock a
       waiting thread via ulckpwdf() function.	This mechanism prevents simul‐
       taneous modification of the password files.

       lckpwdf()  function  locks  out	other threads and attempts to lock the
       file  /etc/.pwd.lock  within  15	 seconds.   If	 unsuccessful,	 e.g.,
       /etc/.pwd.lock  is    already  locked,  it  unlocks the thread lock and
       returns -1.  If successful,   a return code other than -1 is returned.

       ulckpwdf() function attempts to unlock  the  file  /etc/.pwd.lock.   If
       unsuccessful,	e.g.,  /etc/.pwd.lock  is already unlocked, it returns
       -1.  If successful, it	unlocks the thread lock and returns 0.

       The lckpwdf() function  does  not  check	 for  the  /etc/.AM_is_running
       file.  This  file is used by the Tru64 UNIX account management tools. A
       developer using the lckpwdf() function should be aware that  the	 lckp‐
       wdf()  function does not provide a comprehensive locking mechanism that
       is integrated with the Tru64 UNIX account management tools.

RESTRICTIONS
       Restricted Safe - safe for use in threaded  applications	 except	 under
       specified conditions.

       Restriction: ulckpwdf() function must be called by the same thread that
       called lckpwdf() function.

FILES
       /etc/passwd

       /etc/.pwd.lock

ERRORS
       lckpwdf()and ulckpwdf() functions return	 a  null  pointer  on  EOF  or
       error.

SEE ALSO
       Routines: getpwent(3)

								    lckpwdf(3)
[top]
                             _         _         _ 
                            | |       | |       | |     
                            | |       | |       | |     
                         __ | | __ __ | | __ __ | | __  
                         \ \| |/ / \ \| |/ / \ \| |/ /  
                          \ \ / /   \ \ / /   \ \ / /   
                           \   /     \   /     \   /    
                            \_/       \_/       \_/ 
More information is available in HTML format for server Tru64

List of man pages available for Tru64

Copyright (c) for man pages and the logo by the respective OS vendor.

For those who want to learn more, the polarhome community provides shell access and support.

[legal] [privacy] [GNU] [policy] [cookies] [netiquette] [sponsors] [FAQ]
Tweet
Polarhome, production since 1999.
Member of Polarhome portal.
Based on Fawad Halim's script.
....................................................................
Vote for polarhome
Free Shell Accounts :: the biggest list on the net