Something like this longhand:-
OSX 10.7.5, deafult bash terminal.
Results:-
EDIT:
The line "exit 1" is deliberately added but can be removed if not needed.
This section does not change or reset the number of retries but that is an easy task to cure...
Last edited by wisecracker; 06-22-2014 at 03:18 PM..
Reason: See above...
This User Gave Thanks to wisecracker For This Post:
I want to create an automated script which is called by another maually executed script.
The condition is that the no one should be able to manually execute the automated script.
The automated script can be on the same machine or it can be on a remote machine.
Can any one suggest a check in the... (1 Reply)
Hi ,
I have a date parameter passed in YYYYMMDD format , how can I check whether it is Sat or Sun on Solaris box , as we can do the same easily on linux box by using date -d YYYYMMDD '+a' .
Any pointres will be really helpful . (5 Replies)
Hi,
i have a script 'a.sh' that should be called only by certain scripts like b.sh, c.sh
Inside a.sh, how can i determine
1) if this script was run directly from command prompt (or scheduler)
2) if called via other scripts?
Is there an easy way to get parent process name (not just pid),... (2 Replies)
Hello,
I wanted to run one of my shell script for every sunday at 5PM.
Here is the crontab entry i am using..
00 17 * * 0 /inventory/update.sh > /inventory/update.log 2>&1
The job is not kicking on sunday at the specified time.. Am i missing anthing?
Any help is appreciated... (2 Replies)
I have a local linux machine in which the files are dumped by a remote ubuntu server. If the process in remote server has any problem then empty files are created in local machine. Is there any way using perl script to check if the empty files are being created and delete them and then run a shell... (2 Replies)
I was to schedule a script in a crontab after every 15 days specically on every 2nd Sunday.
I know that i can schedule on basis of weekdays, but can it be done by skipping in between???:wall: (5 Replies)
Hi,
I need to create a autosys job which will run on every sunday at 7:30 AM NY time for each 10 min interval of time.
days_of_week: su
start_mins: 0,10,20,30,40,50
run_window:"07:30"
Is it fine? Please help
Thanks,
Anup (2 Replies)
Hello,
I'm looking for a bash script, that I will run from cron, that executes a php script. After 5 minutes that the php script is executed, the bash script, must check a value in a text file /public_html/check.txt
if check.txt = 0 the script will stop, if check.txt is not = 0 it must... (0 Replies)
Hi all,
I have a script that can be run via cron or via the command line.
Is there any way that I can place something on the script to be able to distinguish/differentiate whether the script was run via a user in the command line or whether it was run from the cron? (3 Replies)
Hi ALL,
I have been testing this script to run for every last Sunday of the month,looks like month which have 5 sunday (july 2016 )is not passing this and failing every time.
Here is what I am using,
current_date=31
echo " CURRENT DAY -> $current_date"
if
... (2 Replies)
Discussion started by: netdbaind
2 Replies
LEARN ABOUT DEBIAN
nngoback
NNGOBACK(1) General Commands Manual NNGOBACK(1)NAME
nngoback - make news articles unread on a day-by-day basis (nn)
SYNOPSIS
nngoback [ -NQvi ] [-d] days [ group ]...
DESCRIPTION
nngoback will rewind the .newsrc record file of nn(1) one or more days. It can be used to rewind all groups, or only a specified set of
groups. In other words, nngoback can mark news articles which have arrived on the system during the last days days unread.
Only subscribed groups that occur in the current presentation sequence are rewound. That means that if no group arguments are specified,
all groups occurring in the sequence defined in the init file will be rewound. Otherwise, only the groups specified on the argument line
will be rewound.
When a group is rewound, the information about selections, partially read digests etc. are discarded. It will print notifications about
this unless the -Q (quiet) option is used.
If the -i (interactive) option is specified, nngoback will report for each how many articles can be marked unread, and ask for confirmation
before going back in that group.
If the -v (verbose) option is specified, nngoback will report how many articles are marked unread.
If the -N (no-update) option is specified, nngoback will perform the entire goback operation, but not update the .newsrc file.
If you are not up-to-date with your news reading, you can also use nngoback to catch up to only have the last few days of news waiting to
be read in the following way:
nn -a0
nngoback 3
The nn command will mark all articles in all groups as read (answer all to the catch-up question.) The following nngoback will then make
the last three days of news unread again.
Examples:
nngoback 0
Mark the articles which have arrived today as unread.
nngoback 1
Mark the articles which have arrived yesterday and today as unread.
nngoback 6
Mark the articles which have arrived during the last week as unread.
You cannot go more than 14 days back with nngoback. (You can change this limit as described below.)
THE BACK_ACT DAEMON
It is a prerequisite for the use of nngoback that the script back_act is executed at an appropriate time once (and only once) every day.
Preferably this is done by cron right before the bacth of news for `today' is received. back_act will maintain copies of the active file
for the last 14 days.
Optionally, the back_act program accepts a single numerical argument specifying how many copies of the active file it should maintain.
This is useful if news is expired after 7 days, in which case keeping more than 7 days of active file copies is wasteful.
FILES
~/.newsrc The record of read articles.
~/.newsrc.goback The original rc file before goback.
$db/active.N The N days `old' active file.
$master/back_act Script run by cron to maintain old active files.
SEE ALSO nn(1), nncheck(1), nngrab(1), nngrep(1), nnpost(1), nntidy(1)nnadmin(1M), nnusage(1M), nnmaster(8)NOTES
nngoback does not check the age of the `old' active files; it will blindly believe that active.0 was created today, and that active.7 is
really seven days old! Therefore, the back_act script should be run once and only once every day for nngoback to work properly.
The days are counted relative to the time the active files were copied.
AUTHOR
Kim F. Storm, Texas Instruments A/S, Denmark
E-mail: storm@texas.dk
4th Berkeley Distribution Release 6.6 NNGOBACK(1)