10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
Can anyone please write a shell script to remove the empty files using an if condition.
please help me out , urgent
thanks (6 Replies)
Discussion started by: muthi_murali
6 Replies
2. UNIX for Advanced & Expert Users
Hi,
I am unable to get $HOSTNAME value in a remote script when executed through SSH. Also the scripts hangs and doesnt return to the calling environment.
For instance
command -
ssh user1@box2 "cd /var/home/bin ; ./generateScript.sh"
Can any one plese throw light on the issue and... (5 Replies)
Discussion started by: mihirvora16
5 Replies
3. Shell Programming and Scripting
I have a script that runs ditto for me, and occasionally (if I exit the script while ditto is running in the background) it will leave an empty file named 0 in the script's directory. The next time I run the script, it generates incorrect data because of this file. I know I can easily insert a... (1 Reply)
Discussion started by: reid
1 Replies
4. Shell Programming and Scripting
I have a script that runs ditto for me, and occasionally (if I exit the script while ditto is running in the background) it will leave an empty file named 0 in the script's directory. The next time I run the script, it generates incorrect data because of this file. I know I can easily insert a... (1 Reply)
Discussion started by: reid
1 Replies
5. Shell Programming and Scripting
I'm trying to write a shell script to files of zero length in a specified directory, but I keep getting errors. Would anybody be kind enough to look it over for issues? Thanks a bunch in advance.
#!/bin/sh
if
then
if
then
find $1 -type f -size 0 -print|xargs rm
exit 0... (1 Reply)
Discussion started by: ScriptingIssues
1 Replies
6. Shell Programming and Scripting
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)
Discussion started by: hussa1n
2 Replies
7. Shell Programming and Scripting
So, I will be working with someone and basically we are trying to build a form that is submitted most likely via the web and the data is just a string of numbers.
like:
19383882872201110929282821818182827349190102837364718191001932873711
Now, each number is part of a numerical value of... (4 Replies)
Discussion started by: tlarkin
4 Replies
8. Shell Programming and Scripting
Hi,
I created the following shell script to lookup multiple name servers for a domain.
#!/bin/bash
echo -n "Enter the domain name and press : "
read domain
result1=`dig +short $domain @4.2.2.1`
revresult1=`host $result1 | cut -f5 -d " "`
echo "test1"
result2=`dig +short... (3 Replies)
Discussion started by: mohitmoudgil
3 Replies
9. UNIX for Dummies Questions & Answers
Hi All,
I am checking for a empty input file to do some further action , but I am getting exit status 0 in both the cases , for empty and non empty file both.
The value of $? is coming 0 in if part also and else part too.
#!/bin/ksh
if ]; then
echo "data"
# exit 0
echo "$?"
else... (4 Replies)
Discussion started by: mavesum
4 Replies
10. UNIX for Dummies Questions & Answers
Deleted#### (1 Reply)
Discussion started by: tibbyuk
1 Replies