I see now, you are missing a lot of entries. Maybe check if your /var is full (that would be interessting nobody noticed for more than a half year) or if the file max size limits have been reached, which should be unlimited for root (ulimits) and some big value for jfs2 (16 TB) which is very unlikely.
If you find nothing and don't need the old entries, I would just zero it with
and check if it accepts new entries.
Sir,
I using the following commands in a file (part of a bigger script):
#!/bin/bash
cd /opt/oracle/bin
ls -lt | tail -1 | awk '{print $6}' >> /tmp/ramb.out
If I run this from the command prompt the result is:
2007-05-16
if I run it as a cron job then... (5 Replies)
Hi ,
I have a piece of code ...wherein I need to assign the following ...
1) A command line argument to a variable
e.g origCount=ARGV
2) A unix command to a variable
e.g result=`wc -l testFile.txt`
in my awk shell script
When I do this :
print "origCount" origCount --> I get the... (0 Replies)
AIX:Command to get netaddress/subnet address command in IPv4/IP6
Can anybody help us with a command to retrieve netaddress/subnet address command in IPv4/IP6 on aix machine.
net/subnet address is in the format 172.16.212.0(signifies all 255 machines in an IPv4 network) (2 Replies)
Hi everyone,
when executing this command in unix:
echo "WM7 Fatal Alerts:", $(cat query1.txt) > a.csvIt works fine, but running this command in a shell script gives an error saying that there's a syntax error.
here is content of my script:
tdbsrvr$ vi hc.sh
"hc.sh" 22 lines, 509... (4 Replies)
Hi,
Well my title isn't very clear I think. So to understand my goal:
I have a script "test1"
#!/bin/bash
xvkbd -text blabla
with xbindkeys, I bind F5 key in order it runs my test1 script
So when I press F5, test1 runs.
I'm under Emacs/Vi and I press F5 in order to have "blabla" be... (0 Replies)
HI Guys,
I hope you are well. I am trying to write a script that gets executed every time i open a shell (cshell). I have two questions about that
1) I need to enter these commands
$ echo $DISPLAY
$ setenv $DISPLAY output_of_echo_$display_command
How can i write a... (2 Replies)
I am working with a sh script on a solaris 9 zone (sol 10 host) that grabs information to build the configuration command line. the variables Build64, SSLopt, CONFIGopt, and CC are populated in the script. the script includes
CC=`which gcc`
CONFIGopt=' --prefix=/ --exec-prefix=/usr... (8 Replies)
below is the output xml string from some other command and i will be parsing it using awk
cat /tmp/alerts.xml
<Alert id="10102" name="APP-DS-ds_ha-140018-componentFailure-S" alertDefinitionId="13982" resourceId="11427" ctime="1359453507621" fixed="false" reason="If Event/Log Level(ANY) and... (2 Replies)
exec(): 0509-036 Cannot load program /usr/opt/freeware/bin/rpm because of the following errors:
0509-022 Cannot load module /opt/freeware/lib/libintl.a(libintl.so.1).
0509-150 Dependent module /opt/freeware/lib/libiconv.a(shr4.o) could not be loaded.
0509-152 Member... (4 Replies)
Hello Forum,
I'm making very good progress on my report thanks to the very helpful people on this forum. I've been able to successfully create my report for my Red Hat servers. But I do have a few ubuntu servers in the mix and I'd like to capture some data from them when an ssh connection is... (8 Replies)
Discussion started by: greavette
8 Replies
LEARN ABOUT X11R4
acctcon
acctcon(1M) System Administration Commands acctcon(1M)NAME
acctcon, acctcon1, acctcon2 - connect-time accounting
SYNOPSIS
/usr/lib/acct/acctcon [-l lineuse] [-o reboot]
/usr/lib/acct/acctcon1 [-p] [-t] [-l lineuse] [-o reboot]
/usr/lib/acct/acctcon2
DESCRIPTION
acctcon converts a sequence of login/logoff records to total accounting records (see the tacct format in acct.h(3HEAD)). The login/logoff
records are read from standard input. The file /var/adm/wtmpx is usually the source of the login/logoff records; however, because it might
contain corrupted records or system date changes, it should first be fixed using wtmpfix. The fixed version of file /var/adm/wtmpx can then
be redirected to acctcon. The tacct records are written to standard output.
acctcon is a combination of the programs acctcon1 and acctcon2. acctcon1 converts login/logoff records, taken from the fixed /var/adm/wtmpx
file, to ASCII output. acctcon2 reads the ASCII records produced by acctcon1 and converts them to tacct records. acctcon1 can be used with
the -l and -o options, described below, as well as with the -p and -t options.
OPTIONS -p Print input only, showing line name, login name, and time (in both numeric and date/time formats).
-t acctcon1 maintains a list of lines on which users are logged in. When it reaches the end of its input, it emits a session
record for each line that still appears to be active. It normally assumes that its input is a current file, so that it uses
the current time as the ending time for each session still in progress. The -t flag causes it to use, instead, the last
time found in its input, thus assuring reasonable and repeatable numbers for non-current files.
-l lineuse lineuse is created to contain a summary of line usage showing line name, number of minutes used, percentage of total
elapsed time used, number of sessions charged, number of logins, and number of logoffs. This file helps track line usage,
identify bad lines, and find software and hardware oddities. Hangup, termination of login(1) and termination of the login
shell each generate logoff records, so that the number of logoffs is often three to four times the number of sessions. See
init(1M) and utmpx(4).
-o reboot reboot is filled with an overall record for the accounting period, giving starting time, ending time, number of reboots,
and number of date changes.
EXAMPLES
Example 1: Using the acctcon command.
The acctcon command is typically used as follows:
example% acctcon -l lineuse -o reboots < tmpwtmp > ctacct
The acctcon1 and acctcon2 commands are typically used as follows:
example% acctcon1 -l lineuse -o reboots < tmpwtmp | sort +1n +2 > ctmp
example% acctcon2 < ctmp > ctacct
FILES
/var/adm/wtmpx History of user access and administration information
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWaccu |
+-----------------------------+-----------------------------+
SEE ALSO acctcom(1), login(1), acct(1M), acctcms(1M), acctmerg(1M), acctprc(1M), acctsh(1M), fwtmp(1M), init(1M), runacct(1M), acct(2),
acct.h(3HEAD), utmpx(4), attributes(5)
System Administration Guide: Basic Administration
NOTES
The line usage report is confused by date changes. Use wtmpfix (see fwtmp(1M)), with the /var/adm/wtmpx file as an argument, to correct
this situation.
During a single invocation of any given command, the acctcon, acctcon1, and acctcon2 commands can process a maximum of:
o 6000 distinct session
o 1000 distinct terminal lines
o 2000 distinct login names
If at some point the actual number of any one of these items exceeds the maximum, the command will not succeed.
SunOS 5.10 22 Feb 1999 acctcon(1M)