10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi,
I have this simple c program that creates duplicate process with fork():
#include <sys/types.h>
main()
{
if (fork() == 0)
while(1);
else
while(1);
}
I tried running it in the background
gcc -o test first.c
test &
And I got this list of running process: (4 Replies)
Discussion started by: uniran
4 Replies
2. Shell Programming and Scripting
Hi,
I have created a function f1 defined in script A.sh .I have called this function in background . But I want to use its return value for another function f2 in script A.sh.
I tried declaring it as a global variable, yet it always returns the status as 0. Is there any way with which I can get... (7 Replies)
Discussion started by: ashima jain
7 Replies
3. Shell Programming and Scripting
Hi All,
I was out not working on unix from quite sometime and came back recently. I would really appreciate a help on one of the issue I am facing....
I am trying to kick off the CodeNameProcess.sh in PARALLEL for all the available codes. The script runs fine in parallel.
Let say there are... (1 Reply)
Discussion started by: rkumar28
1 Replies
4. Shell Programming and Scripting
I have a script which runs a script in the background. Now the script running in background returns some variable value and i want to catch return value in the parent script.
e.g.
Parent Script :
#!/bin/bash
./Back.sh &
pid=$!
echo "a=$a"
echo "b=$b"
echo "d=$((a+b))"
wait $pid
... (4 Replies)
Discussion started by: Shaishav Shah
4 Replies
5. Shell Programming and Scripting
Hi ,
I want to see all the background process that are running in unix box machine...please guide me is there any specific command for that..since I am executing some scripts at background..!!:confused: (1 Reply)
Discussion started by: nks342
1 Replies
6. Shell Programming and Scripting
Hey all,
Okay, this one is tricky and I'm not sure there is a niec way to do it, or indeed anyway to do it. The main issue revolves around timing out a hung ssh. I am doing this by creating a wrapper script for the ssh with the following requirements.
My requirements are:
Defineable... (5 Replies)
Discussion started by: RECrerar
5 Replies
7. Shell Programming and Scripting
Hi,
I have a process that I run in the background that looks like this
${BASEDIR}/ksh/sqler.ksh ${compnames003} &
and I would like to get the return code of the sqler.ksh script.
so my code is like this
${BASEDIR}/ksh/sqler.ksh ${compnames003} &
retcode=$? (3 Replies)
Discussion started by: c19h28O2
3 Replies
8. Shell Programming and Scripting
I have run one shell script in background that contains a endless while loop.
I am not able to know the status of that job .
Please provide any command to know this. I have already used "ps -aef" , "jobs" to know it , but it didn't work. I am sure the process is running as it is generating a file... (8 Replies)
Discussion started by: sumanta
8 Replies
9. UNIX for Dummies Questions & Answers
I'm trying to install a solaris 9 patch cluster and when I try to use & to run in background it won't allow me to enter in my sudo password so it fails the install and sudo auth. Does Solaris not have screen like linux? If & will work what am I doing wrong?
sudo ./install_cluster -q &
is... (3 Replies)
Discussion started by: kingdbag
3 Replies
10. Shell Programming and Scripting
Hi
I have the following piece of code that is calling another child process archive.ksh in the background
while read file;
do
file_name=`ls $file`;
ksh archive.ksh $file_name &;
done < $indirect_file
The problem is, indirect_file may contain anwhere from 2 to 20 different... (5 Replies)
Discussion started by: Vikas Sood
5 Replies