Does the task not use an exit code ? You can test for it until it is succesful
This will run indefinitely if task will never be successful
Alternatively (bash/ksh) you can limit the number of attempts and report about them.
--
If there is no return code and testing the output is the only option, then I suggest testing for the number of fails :
Likewise, you can use
in the second example...
Last edited by Scrutinizer; 08-26-2018 at 04:41 AM..
This User Gave Thanks to Scrutinizer For This Post:
I am trying to parse hundreds of shell scripts to determine how they related to each other. Ideally for every script, I would get an output of:
What other scripts it calls
What files it reads
Environment variables it accesses
Any ideas on how to do this?
TIA! (2 Replies)
Hi
I have a single large file 11gb that I need to copy/backup to tape then restore on another system. I tried tar but that complained about the file being too large
Anyone have any suggestions how I can do this with AIX 5.2
Much appreciated. (3 Replies)
Hi
I have a big file with a certain pattern (shown below) from which I need to parse out some digits in tabular format.
The format of the file is: '-' indicates text which doesn't to be parsed
# Output of huzzle for sequence file 1000.Clade1.html
- - - -- -------... (2 Replies)
Hi All,
I am just curious, not programming anything of my own. I know there are libraries like gmp which does all such things. But I really need to know HOW they do all such things i.e. working with extremely large unimaginable numbers which are beyond the integer limit. They can do add,... (1 Reply)
I have a file that needs to be parsed into multiple files every time there line contains a number 1. the problem i face is the lines are random and the file size is random. an example is that on line 4, 65, 187, 202 & 209 are number 1's so there has to be file breaks between all those to create 4... (6 Replies)
I have a single line file like this :
Average Fragmentation Quotient : 3.084121
Now I want to store the value which comes after ":" i,e 3.084121 into a variable.
And if this variable crosses above 6 i want to call another script...
can any one help me on this... (7 Replies)
I hope to create a file made up of 2 columns
- first column print out number 0~61000 every 50 of it
- second column just contains 0
delineated by space
such as
0 0
50 0
100 0
150 0
200 0
...
60900 0
60950 0
61000 0
Which command should I need to use? I think I might need to use... (5 Replies)
Hi All,
I have a file with long list of numbers. This file contains only one column. These numbers are very large. I am using following command:
cat myfile.txt | awk '{ sum+=$1} END {print sum}'
The output is coming in scientific notation. How do I get the result in proper format?
... (4 Replies)
Below code extracts multiple field values from XML into array and prints all in one line.
perl -nle '@r=/(?: jndiName| authDataAlias| value| minConnections| maxConnections| connectionTimeout| name)="(+)/g and print join ",",$ENV{tIPnSCOPE},$ENV{pr
ovider},$ENV{impClassName},@r' server.xml
... (4 Replies)
Hi,
I need a help on my requirement that
eg: NEED="TEST=Name WORK=Ps DEL=let"
Here the definition can be n number, could anybody have an idea to get the output as,
TEST=Name
WORK=Ps
DEL=let
..
..
till the 'n' definitions listed.
Any suggestions please.....
Regards,
ricky (6 Replies)
Discussion started by: ricky-row
6 Replies
LEARN ABOUT LINUX
rbash
RBASH(1) General Commands Manual RBASH(1)NAME
rbash - restricted bash, see bash(1)RESTRICTED SHELL
If bash is started with the name rbash, or the -r option is supplied at invocation, the shell becomes restricted. A restricted shell is
used to set up an environment more controlled than the standard shell. It behaves identically to bash with the exception that the follow-
ing are disallowed or not performed:
o changing directories with cd
o setting or unsetting the values of SHELL, PATH, ENV, or BASH_ENV
o specifying command names containing /
o specifying a file name containing a / as an argument to the . builtin command
o specifying a filename containing a slash as an argument to the -p option to the hash builtin command
o importing function definitions from the shell environment at startup
o parsing the value of SHELLOPTS from the shell environment at startup
o redirecting output using the >, >|, <>, >&, &>, and >> redirection operators
o using the exec builtin command to replace the shell with another command
o adding or deleting builtin commands with the -f and -d options to the enable builtin command
o using the enable builtin command to enable disabled shell builtins
o specifying the -p option to the command builtin command
o turning off restricted mode with set +r or set +o restricted.
These restrictions are enforced after any startup files are read.
When a command that is found to be a shell script is executed, rbash turns off any restrictions in the shell spawned to execute the script.
SEE ALSO bash(1)GNU Bash-4.0 2004 Apr 20 RBASH(1)