10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I am trying to capture logs of the script in the file as well as on the screen. I have used exec and tee command for this. While using exec command I am getting the correct output in the file but, script output is not getting displayed on the screen as it get executed.
Below is my sample... (14 Replies)
Discussion started by: Prathmesh
14 Replies
2. Shell Programming and Scripting
#!/bin/ksh
#This script will check status of load balancer in AIX servers from hopbox
#Steps to do as folows :
#Login to server
#netstat -ani | grep <IP>
#check if the output contains either lo0 OR en0
#if the above condition matches, validation looks good
#else, send an email with impacted... (7 Replies)
Discussion started by: vinil
7 Replies
3. UNIX for Dummies Questions & Answers
I am trying to call a script(callingscript.sh) from a master script(masterscript.sh) to get string type value from calling script to master script. I have used scripts mentioned below.
#masterscript.sh
./callingscript.sh
echo $fileExist
#callingscript.sh
echo "The script is called"... (2 Replies)
Discussion started by: Raj Roy
2 Replies
4. Shell Programming and Scripting
Hi,
I want to write a script which continuously checking status of a script running in background by nohup command. And if same script is not running then immediately start the script...please help..
i am using below command to run script
nohup system_traps.sh &
but in some... (9 Replies)
Discussion started by: ketanraut
9 Replies
5. Shell Programming and Scripting
Hi All
I have written below basic restart script but it is giving me the following error -
error - syntax error at line 40 : `else' is not matched .
below is the script can someone assist me what i am doing wrong -
#!/bin/ksh
cd bin
. ./set_sysm
sleep 60
./swstop -f 0
... (1 Reply)
Discussion started by: honey26
1 Replies
6. Shell Programming and Scripting
Greetings...
I have to construct shell script to check the SFTP status,
Define a global variable (say sftpStatus). Set it to default value "success" when you define it first time outside the script.
check the current SFTP status (say currentStatus - local variable within the script)
if... (16 Replies)
Discussion started by: manju98458
16 Replies
7. Shell Programming and Scripting
Hi,
I have a problem with running out of memory in my Ubuntu web server (4GB RAM) because many people try to access my server.
I used to restart manually my apache server to clear out the memory & swap.
Can anyone tell me how to write bash script that can automatically restart apache when... (2 Replies)
Discussion started by: nica
2 Replies
8. Shell Programming and Scripting
hi,
i am new to this scripting stuff so please help.
i need a script that should check network connection while process.bsh is running which connects to a server for some time (e.g. 30 secs to a minute) and I wanted to make sure that network interruption does not happen during this time period... (2 Replies)
Discussion started by: bun $ ny
2 Replies
9. Shell Programming and Scripting
Hi!
I have a script, which calls another script on a remote machine using ssh.
I need to check if the remote running script is succesful. If it is succesful I need to continue the for loop (run it on another machine) or break the loop.
Please let me know if anyone has an idea on checking the... (3 Replies)
Discussion started by: nua7
3 Replies
10. Shell Programming and Scripting
Hi,
I have tried with the following code;
if ;then
echo "Failure."
else
echo "Success."
fi
to test the exit status of the test.ksh shell script. But whatever is the exit status of the test.ksh shell script Failure. is always printed.
Please help.
regards,
Dipankar. (2 Replies)
Discussion started by: kdipankar
2 Replies