Sponsored Content
Top Forums Shell Programming and Scripting Run a command once in three hours Post 303027150 by ginrkf on Monday 10th of December 2018 07:43:48 AM
Old 12-10-2018
Hi it should run only every 9th time the script is running.If the file is there yes we need to execute hi and quit
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

AT command to batch execute every x hours

I want to schedule a batch job (SQL)to run every 6 hours in Unix and the AT command syntax does not seem to cover this. I have created a file ncd_rpt in the directory report and have given the command in this file. at -f /report/ncd_rpt 1:00 am tomorrow I schedule this by running sh... (1 Reply)
Discussion started by: naveen79
1 Replies

2. Shell Programming and Scripting

list the file created before 24 hours using ls command

I want to list the files created before past 24 hours using ls command. please help me on this (7 Replies)
Discussion started by: jayaramanit
7 Replies

3. Shell Programming and Scripting

How to make a script run for a maximum of "x" number of hours only

How to make a script run for a maximum of "x" number of hours only (7 Replies)
Discussion started by: ScriptDummy
7 Replies

4. Shell Programming and Scripting

Command to clear logs for every 6 hours in solaris

Hi Folks, I need to remove log files for six hours on Solaris. before i used to do for every 24 hours below is the code for 1 day older log files, now i tried using -mmin +360 but it says command not found. Can someone please help me out!!! part of the code: LOG_FILE=`find /home/Logdir... (1 Reply)
Discussion started by: Sendhil.Kumaran
1 Replies

5. HP-UX

Crontab do not run on PM hours

Hi All I have a problem, I wonder if you can help me sort it out: I have the following entry in the cron: 00 1,13 * * * /home/report/opn_amt_gestores_credito.ksh > opn_amt_gestores_credito.log But the entry only runs at 01:07 I have stopped the cron deamon, and started, but it still... (39 Replies)
Discussion started by: fretagi
39 Replies

6. Shell Programming and Scripting

Script for telnet and run one command kill it and run another command using while loop

( sleep 3 echo ${LOGIN} sleep 2 echo ${PSWD} sleep 2 while read line do echo "$line" PID=$? sleep 2 kill -9 $PID done < temp sleep 5 echo "exit" ) | telnet ${HOST} while is executing only command and exits. (5 Replies)
Discussion started by: sooda
5 Replies

7. UNIX for Dummies Questions & Answers

Find command to get the modified files past 2 hours

Hello, How to get the modified/created files past 2 hours in Solaris with find command? Thank you. (7 Replies)
Discussion started by: balareddy
7 Replies

8. UNIX for Dummies Questions & Answers

At command not running out of hours

Hi All, new to the forum and new to Unix but I have an issue which is annoying on a new level. I have included a short and full version for anyone needing more information. Short Version I am running a set of scripts that work and run fine. one of the scripts arranges the first... (4 Replies)
Discussion started by: Delboy4000
4 Replies

9. Solaris

How to run cron entry every 5 min during office hours only?

Hi I need to setuop a cron entry to run every 5 min, only in office hours (between 8:00AM to 18:00PM, I did the following: 0,5,10,15,20,25,30,35,40,45,50,55 8,9,10,11,12,13,14,15,16,17,18 * * * /home/xxx/zzz.ksh But somehow does not work. Could it be wrong? (8 Replies)
Discussion started by: fretagi
8 Replies

10. Shell Programming and Scripting

Help 'speeding' up this 'parsing' script - taking 24+ hours to run

Hi, I've written a ksh script that read a file and parse/filter/format each line. The script runs as expected but it runs for 24+ hours for a file that has 2million lines. And sometimes, the input file has 10million lines which means it can be running for more than 2 days and still not finish.... (9 Replies)
Discussion started by: newbie_01
9 Replies
ifplugd(8)						      System Manager's Manual							ifplugd(8)

NAME
ifplugd - A link detection daemon for ethernet devices SYNOPSIS
ifplugd [options] DESCRIPTION
ifplugd is a daemon which will automatically configure your ethernet device when a cable is plugged in and automatically unconfigure it if the cable is pulled. This is useful on laptops with on-board network adapters, since it will only configure the interface when a cable is really connected. It uses your distribution's native ifup/ifdown programs, but can be configured to do anything you wish when the state of the interface changes. It may ignore short unplugged whiles (-d option) or plugged whiles (-u option). ifplugd may be used in "compatibility mode" by specifying -F on the command line. Than ifplugd will treat network drivers which do not sup- port link beat querying as always online. OPTIONS
-a | --no-auto Do not enable interface automatically (default: off) -n | --no-daemon Do not daemonize (for debugging) (default: off) -s | --no-syslog Do not use syslog, use stdout instead (for debugging) (default: off). -b | --no-beep Do not beep (off), overrides --no-beep-up and --no-beep-down. -U | --no-beep-up Do not beep on interface up (off) -D | --no-beep-down Do not beep on interface down (off) -f | --ignore-fail Ignore detection failure, retry instead. Failure is treated as "no link". (default: off) -F | --ignore-fail-positive Ignore detection failure, retry instead. Failure is treated as "link detected". (default: off) -i | --iface= IFACE Specify ethernet interface (default: eth0) -r | --run= EXEC Specify program to execute when link status changes (default: /etc/ifplugd/ifplugd.action) -I | --ignore-retval Don't exit on nonzero return value of program executed on link change. (default: off) -t | --poll-time= SECS Specify poll time in seconds (default: 1) -T | --poll-utime= USECS Specify poll time in microseconds, added to -t (default: 0) -u | --delay-up= SECS Specify delay for configuring interface (default: 0) -d | --delay-down= SECS Specify delay for deconfiguring interface (default: 5) -m | --api-mode= MODE Force a specific link beat detection ioctl() API. Possible values are auto, iff, wlan, ethtool, mii, and priv for automatic detec- tion, interface flag (IFF_RUNNING), wireless extension, SIOCETHTOOL, SIOCGMIIREG resp. SIOCPRIV. Only the first character of the argument is relevant, case insensitive. (default: auto) -p | --no-startup Don't call the script to bring up network on deamon start (default: off) -q | --no-shutdown Don't call the script for network shutdown on deamon quit (default: off) -w | --wait-on-fork When daemonizing, wait until the background process finished with the initial link beat detection. When this is enabled, the parent process will return the link status on exit. 2 means link beat detected, 3 stands for link beat not detected, everything else is an error. -W | --wait-on-kill When killing a running daemon (with -k) wait until the daemon died. -x | --extra-arg= ARG Specify an extra argument to be passed to the action script. -M | --monitor Don't fail when the network interface is not available, instead use NETLINK to monitor device avaibility. The is useful for PCMCIA devices and similar. -h | --help Show help -k | --kill Kill a running daemon (Specify -i to select the daemon instance to kill) -c | --check-running Check if a daemon is running for a given network interface. Sets the return value to 0 if a daemon is already running or to 255 if not. -v | --version Show version -S | --supend Suspend a running daemon. The daemon will no longer check the link status until it is resumed (-R) again. (Specify -i to select the daemon instance to suspend.) -R | --resume Resume a suspended daemon. (Specify -i to select the daemon instance to resume.) -z | --info Request that a running daemon shall write its status information to syslog. (Specify -i to select the daemon instance to send the request to.) FILES
/etc/default/ifplugd: this file is sourced by the init script /etc/init.d/ifplugd and contains the interface to be monitored and the options to be used. /etc/ifplugd/ifplugd.action: this is the script which will be called by the daemon whenever the state of the interface changes. It takes two areguments: the first is the interface name (eg. eth0), the second either "up" or "down". /var/run/ifplugd.<iface>.pid: the pid file for ifplugd. ENVIRONMENT
The action script will be called with two environment variables set: IFPLUGD_PREVIOUS The previous link status. Either "up", "down", "error" or "disabled". The former values should be obvious, the latter is set on daemon startup. IFPLUGD_CURRENT The current link status. See above for possible values. SIGNALS
SIGINT, SIGTERM ifplugd will quit, possibly running the shutdown script. This is issued by passing -k to ifplugd. SIGQUIT ifplugd will quit, the shutdown script is never run. SIGHUP ifplugd will write its status information to syslog. This is issued by -z. SIGUSR1 ifplugd will go to suspend mode. (-S) SIGUSR2 ifplugd will resume from suspend mode. (-R) AUTHOR
ifplugd was written by Lennart Poettering <mzvscyhtq (at) 0pointer (dot) de>. ifplugd is available at http://0pointer.de/lennart/projects/ifplugd/ SEE ALSO
ifplugd.conf(5), ifup(8), interfaces(5), ifconfig(8), ifplugstatus(8) COMMENTS
This man page was written using xmltoman(1) by Oliver Kurth. Manuals User ifplugd(8)
All times are GMT -4. The time now is 12:59 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy