unixdev.net


Switch to SpeakEasy.net DSL

The Modular Manual Browser

Home Page
Manual: (HP-UX-11.11)
Page:
Section:
Apropos / Subsearch:
optional field



 acctsh(1M)							  acctsh(1M)




 NAME
      chargefee, ckpacct, dodisk, lastlogin, monacct, nulladm, prctmp,
      prdaily, prtacct, shutacct, startup, turnacct - shell procedures for
      accounting

 SYNOPSIS
      /usr/sbin/acct/chargefee login-name number

      /usr/sbin/acct/ckpacct [blocks]

      /usr/sbin/acct/dodisk [-o] [files ...]

      /usr/sbin/acct/lastlogin

      /usr/sbin/acct/monacct number

      /usr/sbin/acct/nulladm file

      /usr/sbin/acct/prctmp

      /usr/sbin/acct/prdaily [-l] [-c] [mmdd]

      /usr/sbin/acct/prtacct file [heading]

      /usr/sbin/acct/shutacct [reason]

      /usr/sbin/acct/startup

      /usr/sbin/acct/turnacct on | off | switch

 DESCRIPTION
      chargefee	     Can be invoked to charge a number of units to login-
		     name.  A record is written to /var/adm/fee, to be
		     merged with other accounting records during the night.

      ckpacct	     Should be initiated via cron(1M).	It periodically
		     checks the size of /var/adm/pacct.	 If the size exceeds
		     blocks, 1000 by default, turnacct is invoked with
		     argument switch.  If the number of free disk blocks in
		     the /var file system falls below 500, ckpacct
		     automatically turns off the collection of process
		     accounting records via the off argument to turnacct.
		     When at least this number of blocks is restored, the
		     accounting will be activated again.  This feature is
		     sensitive to the frequency at which ckpacct is
		     executed, usually by cron.

      dodisk	     Should be invoked by cron to perform the disk
		     accounting functions.  By default, it will do disk
		     accounting on the special files in /etc/fstab. If the
		     -o flag is used, it does a slower version of disk



 Hewlett-Packard Company	    - 1 -   HP-UX Release 11i: November 2000






 acctsh(1M)							  acctsh(1M)




		     accounting by login directory.  files specifies the one
		     or more filesystem names where disk accounting is to be
		     done.  If files is used, disk accounting will be done
		     on these filesystems only.	 If the -o flag is used,
		     files should be mount points of mounted filesystem.  If
		     omitted, they should be the special file names of
		     mountable filesystems.

      lastlogin	     Invoked by runacct to update /var/adm/acct/sum/loginlog
		     which shows the last date on which each user logged in
		     (see runacct(1M)).

      monacct	     Should be invoked once each month or each accounting
		     period.  number indicates which month or period it is.
		     If number is not given, it defaults to the current
		     month (01 through 12).  This default is useful if
		     monacct is to executed via cron on the first day of
		     each month.  monacct creates summary files in
		     /var/adm/acct/fiscal and restarts summary files in
		     /var/adm/acct/sum.

      nulladm	     Creates file with mode 664 and ensures that owner and
		     group are adm.  It is called by various accounting
		     shell procedures.

      prctmp	     Can be used to print the session record file normally
		     /var/adm/acct/nite/ctmp created by acctcon1 (see
		     acctcon(1M)).

      prdaily	     Invoked by runacct (see runacct(1M)) to format a report
		     of the previous day's accounting data.  The report
		     resides in /var/adm/acct/sum/rprtmmdd where mmdd is the
		     month and day of the report.  The current daily
		     accounting reports may be printed by typing prdaily.
		     Previous days' accounting reports can be printed by
		     using the mmdd option and specifying the exact report
		     date desired.  The -l flag prints a report of
		     exceptional usage by login id for the specifed date.
		     Previous daily reports are cleaned up and therefore
		     inaccessible after each invocation of monacct.  The -c
		     flag prints a report of exceptional resource usage by
		     command, and can be used on current day's accounting
		     data only.

      prtacct	     Can be used to format and print any total accounting
		     (tacct) file.

      shutacct	     Should be invoked during a system shutdown to turn
		     process accounting off and append a ``reason'' record
		     to /var/adm/wtmp.




 Hewlett-Packard Company	    - 2 -   HP-UX Release 11i: November 2000






 acctsh(1M)							  acctsh(1M)




      startup	     Should be called by system startup scripts to turn the
		     accounting on whenever the system is brought up.

      turnacct	     An interface to accton (see acct(1M)) to turn process
		     accounting on or off.  The switch argument turns
		     accounting off, moves the current /var/adm/pacct to the
		     next free name in /var/adm/pacctincr then turns
		     accounting back on again.	(incr is a number starting
		     with 1 and incrementing by one for each additional
		     pacct file.) turnacct is called by ckpacct, and thus
		     can be run under cron and used to keep pacct to a
		     reasonable size.

 FILES
      /usr/sbin/acct			      holds all accounting commands
					      listed in section (1M) of this
					      manual
      /var/adm/fee			      accumulator for fees
      /var/adm/acct/nite		      working directory
      /var/adm/pacct			      current file for per-process
					      accounting
      /var/adm/pacct*			      used if pacct gets large, and
					      during execution of daily
					      accounting procedure
      /usr/sbin/acct/ptecms.awk		      contains the limits for
					      exceptional usage by command
					      name
      /usr/sbin/acct/ptelus.awk		      contains the limits for
					      exceptional usage by login id
      /var/adm/acct/sum			      summary directory, should be
					      saved
      /var/adm/wtmp			      login/logoff summary

 SEE ALSO
      acct(1M), acctcms(1M), acctcom(1M), acctcon(1M), acctmerg(1M),
      acctprc(1M), cron(1M), diskusg(1M), fwtmp(1M), runacct(1M), acct(2),
      acct(4), utmp(4).

 STANDARDS CONFORMANCE
      chargefee: SVID2, SVID3

      ckpacct: SVID2, SVID3

      dodisk: SVID2, SVID3

      lastlogin: SVID2, SVID3

      monacct: SVID2, SVID3

      prctmp: SVID2, SVID3




 Hewlett-Packard Company	    - 3 -   HP-UX Release 11i: November 2000






 acctsh(1M)							  acctsh(1M)




      prdaily: SVID2, SVID3

      prtacct: SVID2, SVID3

      shutacct: SVID2, SVID3

      startup: SVID2, SVID3

      turnacct: SVID2, SVID3













































 Hewlett-Packard Company	    - 4 -   HP-UX Release 11i: November 2000