The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Operating Systems > AIX
.
google unix.com



AIX AIX is IBM's industry-leading UNIX operating system that meets the demands of applications that businesses rely upon in today's marketplace.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
cron job starts new cron proccess ron76 SUN Solaris 3 05-12-2008 02:07 AM
Cron and Pseudo-Cron dingusmcghee UNIX for Dummies Questions & Answers 1 01-31-2008 12:58 PM
CRON usage for CRON job skyineyes UNIX for Dummies Questions & Answers 1 01-17-2008 10:17 AM
AIX and cron logs filtering ?: /etc/cronlog.conf, /var/adm/cron/log Keith Johnson AIX 0 01-09-2008 08:32 PM
Cron : you are not authorized to use cron. Sorry. tt155 UNIX for Advanced & Expert Users 1 07-06-2005 11:37 AM

Closed Thread
English Japanese Spanish French German Portuguese Italian Dutch Swedish Russian Norwegian Hungarian Hebrew Danish Bulgarian Greek Powered by Powered by Google
 
LinkBack Thread Tools Search this Thread Rate Thread Display Modes
  #1 (permalink)  
Old 02-08-2008
vjm vjm is offline
Registered User
  
 

Join Date: Mar 2005
Posts: 43
Question Cron help

I want to schedule svmon -i 1 5 to run every 5 minutes and give output to a specific file. Can anybody help me to do this with cron?
  #2 (permalink)  
Old 02-08-2008
bakunin bakunin is offline Forum Staff  
Bughunter Extraordinaire
  
 

Join Date: May 2005
Location: In the leftmost byte of /dev/kmem
Posts: 1,641
First: what exactly do you want to achieve? It might be better suited to your needs to issue "svmon -G" instead, which gives you the "globals", aka summary of information instead of a momentary snapshot.

Second: The way you call svmon it has already an interval built in, so you do not need cron: "svmon -i 300" will take the snapshot every 300 seconds = 5 minutes for as long as you want. That might be, what you really want. In this case issue the following:


Code:
# nohup svmon -i 300 > /path/to/file &

and kill the process when you have take enough samples.

If you insist in taking 5 samples in a 1-second-interval every 5 minutes you need cron. Issue "crontab -e" (edit) as root and add the following line:


Code:
0,5,10,15,20,25,30,35,40,45,50,55 * * * * /usr/bin/svmon -i 1 5 > /path/to/file 2>/dev/null

see "man crontab" for an explanation of what the first part of the line means.
Closed Thread

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On




All times are GMT -4. The time now is 06:21 AM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited. Language Translations Powered by .
vBCredits v1.4 Copyright ©2007 - 2008, PixelFX Studios
The UNIX and Linux Forums Content Copyright ©1993-2009. All Rights Reserved.Ad Management by RedTyger

Content Relevant URLs by vBSEO 3.2.0