Sponsored Content
Full Discussion: Monitor a script
Top Forums UNIX for Dummies Questions & Answers Monitor a script Post 302764947 by Vicky5 on Friday 1st of February 2013 06:58:59 AM
Old 02-01-2013
thank u @gary_w
Its working fine.
if f_background_command() function takes just 5 sec to complete In that case script still waits for another 25 sec.

1. So is there any solution where if f_background_command() completes lessthan 30 sec then continue execution with the rest of the lines after sleep command.
2. If the f_background_command() takes more than 30 sec then the process needs to be terminated,

#2 is achieved with gary_w's code, but #1 is not working.
 

9 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

need help doing a script to monitor if files are go through

I am trying to do a shell script to check a folder and see if files are passing through. Now if a file did not pass through in the last 1 hour send an email. ftp----------> folder to monitor ----------->ftp Now the script that moves the file runs every sec in cron, so i do not know if i... (0 Replies)
Discussion started by: jonathan184
0 Replies

2. Shell Programming and Scripting

Help with HD monitor script

Hi, I'm new to linux and I'm trying to compile a hard drive monitoring script. I've seen a few on the internet and I've attempted to stumble through but I'm stuck at my while/do scenario. I assigned the variable NUM then took the percentage from my output and cut the % so it would be just a... (6 Replies)
Discussion started by: crocyson
6 Replies

3. Shell Programming and Scripting

Monitor script

Does anyone have a monitoring script in solaris that monitors the drives in an exclosure? The script should be in /bin/bash or /bin/sh thnks again This should be for solaris 10/11 looking for something that tells me a drive is down or offline.:confused: (0 Replies)
Discussion started by: walnutpony123
0 Replies

4. Shell Programming and Scripting

Script to monitor Values

Hi All, I want a scrip to monitor values which is the out put of a certain command. Example is $ for (( c=1; c<15; c++ )); do cmu -O HTA -d HTTP-PROXY.tswebpxmp5.$c | grep -i active; done HTA_STATS_htaStatsDef.ifw_stats.streamStat.activeStreams : 2 ... (1 Reply)
Discussion started by: Siddheshk
1 Replies

5. Shell Programming and Scripting

How to monitor a shell script called within a script?

HIi Guys... I am in a fix.... 1st the code : Script 123.sh looks like this : ./abc # a script which is getting called in this script while true do count=`ps -ef | grep abc | wc -l` if echo "abc is running sleep 10 fi done but the process is getting checked... (5 Replies)
Discussion started by: chatwithsaurav
5 Replies

6. Shell Programming and Scripting

[Help] Script to monitor logs

Hello friends, as they are? First of all sorry for my poor English. I tell them what is my problem. I have the following script, which is basically what makes error search for a pattern within a folder containing logs. The script works fine, the problem is that whenever I find a pattern of new... (2 Replies)
Discussion started by: romanrsr
2 Replies

7. Shell Programming and Scripting

Monitor the services by script

I developed for monitoring the network connections among the branch servers as I given below as script.But I don't know how to monitor the services through network script whether the services is running or not. eg : I want to check the postgres service for all the branch servers through network... (0 Replies)
Discussion started by: kannansoft1985
0 Replies

8. Infrastructure Monitoring

Searching for Saas Monitor service which monitor my servers which are sitting in different providers

Sorry if this is the wrong forum Searching for Saas Monitor service which monitor my servers which are sitting in different providers . This monitor tool will take as less CPU as possible , and will send info about the server to main Dashboard. The info I need is CPU / RAM / my servers status (... (1 Reply)
Discussion started by: umen
1 Replies

9. UNIX for Advanced & Expert Users

Script monitor website wth default tomcat script

Hi all, on our application server we have the following script that monitor the status of the website, my problem here is that i have edite the retries from 3 to 5, and the timewait to 120 second, so the script should check 5 times every 2 minutes, and if the fifth check fails it must restart... (0 Replies)
Discussion started by: charli1
0 Replies
Sys::Virt::Secret(3pm)					User Contributed Perl Documentation				    Sys::Virt::Secret(3pm)

NAME
Sys::Virt::Secret - Represent & manage a libvirt secret DESCRIPTION
The "Sys::Virt::Secret" module represents a secret managed by the virtual machine monitor. METHODS
my $uuid = $sec->get_uuid() Returns a 16 byte long string containing the raw globally unique identifier (UUID) for the secret. my $uuid = $sec->get_uuid_string() Returns a printable string representation of the raw UUID, in the format 'XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX'. my $type = $sec->get_usage_type() Returns the usage type of this secret. The usage type determines the format of the unique identifier for this secret. my $id = $sec->get_usage_id() Returns the identifier of the object with which the secret is to be used. For secrets with a usage type of volume, the identifier is the fully qualfied path. my $xml = $sec->get_xml_description() Returns an XML document containing a complete description of the secret's configuration $sec->undefine() Remove the configuration associated with a secret previously defined with the "define_secret" method in Sys::Virt. $bytes = $sec->get_value() Returns the raw bytes for the value of this secret, or undef if there is no value stored with the secret. $sec->set_value($bytes) Sets the value for the secret to be $bytes. CONSTANTS
Sys::Virt::Secret::USAGE_TYPE_NONE The constant for secrets which are not assigned for use with a particular object Sys::Virt::Secret::USAGE_TYPE_VOLUME The constant for secrets which are to be used for storage volume encryption. The usage ID for secrets will refer to the fully qualified volume path. Sys::Virt::Secret::USAGE_TYPE_CEPH The constant for secrets which are to be used for authenticating to CEPH storage volumes. The usage ID for secrets will refer to the server name. AUTHORS
Daniel P. Berrange <berrange@redhat.com> COPYRIGHT
Copyright (C) 2006-2009 Red Hat Copyright (C) 2006-2007 Daniel P. Berrange LICENSE
This program is free software; you can redistribute it and/or modify it under the terms of either the GNU General Public License as published by the Free Software Foundation (either version 2 of the License, or at your option any later version), or, the Artistic License, as specified in the Perl README file. SEE ALSO
Sys::Virt, Sys::Virt::Error, "http://libvirt.org" perl v5.14.2 2012-05-21 Sys::Virt::Secret(3pm)
All times are GMT -4. The time now is 10:53 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy