10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
The log file is huge and lot of information, i would like to parse and make a report .
below is the log file looks like:
REPORT DATE: Mon Aug 10 04:16:17 CDT 2017
SYSTEN VER: v1.3.0.9
TERMINAL TYPE: prod
SYSTEM: nb11cu51
UPTIME: 04:16AM up 182 days 57 mins min
MODEL, TYPE, and SN:... (8 Replies)
Discussion started by: amir07
8 Replies
2. UNIX for Advanced & Expert Users
Hi
I am new to Linux / scripting language. I need to improve our Linux servers at work and looking to claim some space my deleting log files/ folders on a 5 day basis.
Can someone help me with creating a script to do so.
Any sample script will be helpful.:b:
Regards (2 Replies)
Discussion started by: sachinksl
2 Replies
3. Shell Programming and Scripting
Hi ,
I am trying to create shell script which will help me to compare file name in two folder.
There is a multiple file store in 2 folder.I want to compare that with the name.
If all the file are same then send a mail that "all date is same"
if not then create one log file which contain... (4 Replies)
Discussion started by: san_dy123
4 Replies
4. Shell Programming and Scripting
Dear Members,
I have a table in Oracle DB and one of its column name is INFO which has data in text format which we need to fetch in a script and create an xml file of a new table from the input.
The contents of a single cell of INFO column is like:
Area:app - aam
Clean Up Criteria:... (0 Replies)
Discussion started by: Yoodit
0 Replies
5. UNIX for Dummies Questions & Answers
unix program to which a directory name will be passed as
parameter. This directory will contain files with various
extensions. This script will create directories with the names of the
extention of the files and then put the files in the
corresponding folder. All files which do not have any... (2 Replies)
Discussion started by: Deekay.p
2 Replies
6. Shell Programming and Scripting
Hi
I would like to create a log file to track the execution of my script.
Example, if there were any errors, if it passed or failed etc.
How do I go about doing this.
My log file will be saved to this location: /var/log/import.log
How do I specify the directory?
I have been... (1 Reply)
Discussion started by: ladyAnne
1 Replies
7. UNIX for Advanced & Expert Users
Hi,
I am trying to run a shell script using the crontab scheduler, and I am redirecting the log of the script output to some temp log file using the following command.
sh somescript.sh 1> /location/somefile.log
Evrytime the cronjob triggers this script, It creates a zero byte file in the... (4 Replies)
Discussion started by: DSDexter
4 Replies
8. Shell Programming and Scripting
I have a schell script that runs continously on an AIX system. It is actually started from another shell script with the "ksh -x" command and then I just write the output to a log file. This causes the log files to be filled with mostly useless information. I would like to modify this script to... (2 Replies)
Discussion started by: heprox
2 Replies
9. Solaris
I have a simple backup script that I am running to back up drives across the network. However I need to have detailed log files for this script such as time backup started, what was backed up, if there were any errors and the time that the backup was complete. I would also like the script to... (3 Replies)
Discussion started by: valicon
3 Replies
10. UNIX for Advanced & Expert Users
hi
i am using borne shell script to install a product.
In the script i get from the user some input and then to do pkgadd and some sqlplus commands.
I want to capture all the information to the logfile.
if i use , tee command i dont get the user entered input.
can u let me know... (4 Replies)
Discussion started by: barun007
4 Replies
vxcmdlog(1M) vxcmdlog(1M)
NAME
vxcmdlog - administer command logging
SYNOPSIS
vxcmdlog [-H] [-l] [-m {on|off}] [-n number] [-s size]
DESCRIPTION
The vxcmdlog command is used to administer command logging in Veritas Volume Manager (VxVM). This feature can be used to record all VxVM
commands that are issued, and can be used in conjunction with the transaction logging feature (see vxtranslog(1M)).
When the current log file reaches a maximum size, it is renamed as a historic log file, and a new current log file is created. A limited
number of historic log files is preserved to avoid filling up the file system.
Each log file contains a header that records the host name, host ID, and the date and time that the log was created. See the EXAMPLES sec-
tion below for a description of the entries that are recorded in a log file.
OPTIONS
-H Displays detailed help about the usage of the command.
-l Lists current settings for command logging. This shows whether command logging is enabled, the maximum number of historic log
files, and the maximum log file size.
-m {on|off}
Turns command logging on or off. By default, command logging is turned on.
-n number Sets the maximum number of historic log files to maintain. The default number is 5. If number is set to no_limit, there is no
limit on the number of historic log files that are created.
-s size Sets the maximum size to which a command log can grow. (Note that this setting has no effect on existing historic log files.)
The suffix modifiers k, m, and g may be used express sizes in kilobytes, megabytes and gigabytes respectively. If no suffix is
specified, the default units are kilobytes.
If size is set to no_limit, there is no limit on the size of the log file.
The size of the command log is checked after an entry has been written so the actual size may be slightly larger than that speci-
fied. When the log reaches the specified size, the current command log file, cmdlog, is renamed as the next available historic
log file, cmdlog.number, where number is an integer from 1 up to the maximum number of historic log files that is currently
defined.
If the maximum number of historic log files has been reached, the oldest historic log file is removed, and the current log file
is renamed as that file.
The default maximum size of the command log file is 1m(1MB).
EXAMPLES
Turn on command logging:
vxcmdlog -m on
Set the maximum command log file size to 512KB:
vxcmdlog -s 512k
Set the maximum number of historic command log files to 10:
vxcmdlog -n 10
The following are sample entries from a command log file:
/usr/sbin/vxdctl mode
/usr/sbin/vxdisk -q -o alldgs list
/etc/vx/diag.d/vxprivutil dumpconfig /dev/vx/rdmp/Disk_4s2
/usr/sbin/vxdisk list SENA0_1
Each entry usually contains a client ID that identifies the command connection to the vxconfigd daemon, the process ID of the command, a
time stamp, and the command that was used together with its arguments. If the client ID is 0, as in the third entry shown here, this means
that the command did not open a connection to vxconfigd.
Note: The client ID is the same as that recorded for the corresponding transactions in the transactions log.
FILES
/etc/vx/log Symbolic link to the log directory. This can be redefined if necessary.
/etc/vx/log/cmdlog Current command log.
/etc/vx/log/cmdlog.number
Historic command logs.
NOTES
If vxcmdlog records the invocation of a vxmake command that reads object definitions from a description file, vxcmdlog additionally records
the contents of the description file.
Most command scripts are not logged, but the command binaries that they call are logged. Exceptions are the vxdisksetup, vxinstall, and
vxdiskunsetup scripts, which are logged.
SEE ALSO
vxtranslog(1M)
Veritas Volume Manager Troubleshooting Guide
VxVM 5.0.31.1 24 Mar 2008 vxcmdlog(1M)