10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello,
As stated in the title, I do some hacked parallel processing by running multiple instances of bash scripts, each in their own subshell. The code looks like this,
# launch one batch-train script in background for each value in fold group list
for FOLD_GROUP in "${FOLD_GROUP_LIST}"
do
... (5 Replies)
Discussion started by: LMHmedchem
5 Replies
2. Shell Programming and Scripting
Hey I have a shell script that is like this:
(
echo "hi!"
##DO SOMETHING
)&(
sleep 5
##EMAIL RECIPIENTS VARs
ERECIPIENT3="email.com"
echo "Connection on status: is Down"|mail -s "Subject:" ${ERECIPIENT3}
kill -- -$$
)
This isn't working anyone know why? mail won't go out from... (12 Replies)
Discussion started by: mo_VERTICASQL
12 Replies
3. Shell Programming and Scripting
Hi,
the getopts doesnt seem to be working in the subshell of the ksh. when I echo $@ and $* from the subshell it shows nothing. even when I am capturing the parameters from the outer shell and passing while invoking the file then I am still not getting it properly.
the below code is in the... (9 Replies)
Discussion started by: hitmansilentass
9 Replies
4. Shell Programming and Scripting
People,
Here is my code
while read ln
do
xyz=$(echo $ln/$val1*100-100|bc -l|xargs printf "%1.0f\n")
if && ; then
iam="YELLOW"
fi
done <<< "$(grep "^" $TMPOUT)"
where $TMPOUT is a flat file which contains a set of values.
Whilst executing the above, I get an error... (4 Replies)
Discussion started by: sathyaonnuix
4 Replies
5. Shell Programming and Scripting
Hi All,
I would like to improve my bash scripting skill and found a problem which I do not understand. Task is to search and print files in directory (and subdirecories) which contains its own name. Files can have spaces in name.
This one works fine for files in main directory, but not for... (4 Replies)
Discussion started by: new_item
4 Replies
6. Shell Programming and Scripting
Hello
I read a lot of post related to this topic, but nothing helped me. :mad:
I'm running a ksh script with subshell what processing some ldap command. I need to check output for possible errors.
#!/bin/ksh
...
readinput < $QCHAT_INPUT |&
while read -p line
do
echo $line
... (3 Replies)
Discussion started by: Osim
3 Replies
7. Shell Programming and Scripting
Hello,
I've a little problem with one of my ksh scripts and I manage to narrow it to the script here:
#!/bin/ksh
writeLog()
{
paramHandle="unknown"
OPTIND=1
while getopts :i: option $*
do
case $option in
i) paramHandle=${OPTARG} ;;
esac
done
echo... (2 Replies)
Discussion started by: Dahu
2 Replies
8. Shell Programming and Scripting
I am calling a script from with another script and reading its output one line at a time (using <childscript> | while read line) in the parent script. If the output exceeds a predefined number of lines I want to kill the child shell from within the parent shell.
I decided to print the process ID... (2 Replies)
Discussion started by: slash_blog
2 Replies
9. Shell Programming and Scripting
Hi,
I would like to avoid re-directing line by line to a file.
What is the best way to re-direct STDOUT to a file in a subshell?
Thanks in advance.
Cheers
Vj (1 Reply)
Discussion started by: tnvee
1 Replies
10. Shell Programming and Scripting
The profile of the user is empty. Then before I run the script I want I run a parameter file that populates the variables for oracle.
ORACLE_HOME
ORACLE_BASE
ORACLE_SID
PATH
etc ...
But it seems that these variables are not making it to the shell I am in because when I do an echo on... (6 Replies)
Discussion started by: lesstjm
6 Replies