10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi All,
I have a shell script, at one point it try to ping a server in our organization network, if ping fail it will wait for an hour using sleep command and try to run the script again from the beginning.
I'm wondering what could be the possible impact on my Linux server if 1000 sleep... (5 Replies)
Discussion started by: SaddamAB
5 Replies
2. UNIX for Beginners Questions & Answers
I am trying to work on a script where it is a *(star) delimited file has a multiple lines starts with RTG and 3rd column=TD8 I want to substring the date part and
I want to replace with currentdate minus 15 days. Here is an example. iam using AIX server
$ cat temp.txt
RTG*888*TD8*20180201~... (1 Reply)
Discussion started by: Shankar455
1 Replies
3. Shell Programming and Scripting
Hi Guys,
In my script i need to sleep for some seconds till the previous command exeuction is successful
#!/bin/bash
cp test.txt /direct/sub_dir
if ; then
echo "file copied"
else
echo "file not copied"
sleep 5
exit 1
fi
i need to sleep for 5 seconds if the copy command... (7 Replies)
Discussion started by: Master_Mind
7 Replies
4. Shell Programming and Scripting
Hello,
I am trying to write a unix cmd , that if files in folder /path/FTP are all zero kb or empty then good to go, if not empty then sleep for 8 hrs.
Following cmd list me the files which are not empty, But when I am incorporating IF ELSE cmd fails
find /path/FTP. -type f -exec wc -l {}... (6 Replies)
Discussion started by: bluestarmoon
6 Replies
5. UNIX for Dummies Questions & Answers
Hello All,
I was wondering if anyone knew of a way to find out what commands were run on a specific date.
I'm looking to see if I can find certain commands that were run on 3/4, today is 3/10...?
Any thoughts or ideas would be much appreciated!
Thanks in Advance,
Matt
----------... (3 Replies)
Discussion started by: mrm5102
3 Replies
6. UNIX for Advanced & Expert Users
Hi ,
How can I use floating point argument for sleep command in unix.I cannot use usleep as it is not suppported.
Also how can I find out that a file is in use at that particular instant only.(wether it is being read or written) (7 Replies)
Discussion started by: kanus
7 Replies
7. Shell Programming and Scripting
This is a very crude attempt in Bash at something that I needed but didn't seem to find in the 'sleep' command. However, I would like to be able to do it without the need for the temp file. Please go easy on me if this is already possible in some other way:
How many times have you used the... (5 Replies)
Discussion started by: deckard
5 Replies
8. Shell Programming and Scripting
Hi,
I have a log file having size of 48mb.
For such a large log file. I want to get the message in a particular format which includes only unique error and exception messages.
The following things to be done :
1) To remove all the date and time from the log file
2) To remove all the... (1 Reply)
Discussion started by: Pank10
1 Replies
9. Shell Programming and Scripting
I am currently running the following Korn shell script which works fine:
#!/usr/bin/ksh
count=`db2 -x "select count(*) from schema.tablename"`
echo "count"
I would like to add a "where" clause to the 2nd line that would allow me to get a record count of all the records from schema.tablename... (9 Replies)
Discussion started by: sasaliasim
9 Replies
10. Shell Programming and Scripting
Hi friends
sftpCmd.txt
-----------------
!echo "Getting files from sftp"
!echo "----------------"
cd /home/msgGoogle/PLATFORM/PROD/MIMUS/outbound/ARCHIVE/invsnap
!echo "folder created"
!date
mget ???050108*.txt output
!echo "------------------"
!echo "Completed : "
!echo... (3 Replies)
Discussion started by: kittusri9
3 Replies