10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
What would be the best way to store the name of an extracted file from a tar to a text file?
I want to extract one file from a tar and store the name of the extracted file to a temp file.
tar -xvf tar_file.tar file_to_be_extracted (1 Reply)
Discussion started by: erin00
1 Replies
2. Shell Programming and Scripting
hello guys
Please help me with the below issue
I have two files one base file another lookupfile
base file
abc-001
bcd-001
cde-001
Lookupfile
abc-001|11|12
abc-001|11|12
abc-001|11|12 (6 Replies)
Discussion started by: Pratik4891
6 Replies
3. Shell Programming and Scripting
Hi there,
I just want to know how can I redirect error msgs returned from running a command (e.g. nslookup) and then only print out the correct output using an if statement?.
I've tried the following:
where $a is a list of IPs.
but I got all the error msgs printed out to screen and... (9 Replies)
Discussion started by: Abdulelah
9 Replies
4. Shell Programming and Scripting
Dear All-
My requirement is as below-
Header file
$ cat HEADER.txt
RequestId:
RequestDate:
Data file
$ cat DATAVAL.txt
1001|2009-03-01
I need to send the combined data below as email body via mailx command
------------------
RequestId:1001
RequestDate:2009-03-01
I would like... (4 Replies)
Discussion started by: sureshg_sampat
4 Replies
5. Shell Programming and Scripting
Hi -
I am looking for a replacing a string in a in multiple *.sql files in directory with a new string without using a temporary file
Normally I can use sed command as below
for W in ls `FILE*.sql`
do
sed 's/OLD/NEW/g' $W > TEMPFILE.dat
mv TEMPFILE.dat $W
done
But Here in my... (9 Replies)
Discussion started by: raghutapal
9 Replies
6. UNIX for Dummies Questions & Answers
Hi Experts,
I have a requirement where i need to update the below items in file,
1. END TIME
2. PREV_STATUS
For the first time the PREV_status and end time of all job the job will be sysdate & NULL reply as below,
Session_name,Load Type,Frequency,Seesion End time,Prev_Status... (2 Replies)
Discussion started by: prabhutkl
2 Replies
7. Shell Programming and Scripting
Hi all.
I want to check the free space on a given FS and process the output. Right now, I'm using a temp file to avoid using df twice. This is what I'm doing
#!/usr/bin/ksh
...
df -k $FS_NAME > $TMP_FILE 2>&1
if ]; then
RESULT="CRITICAL - $(cat $TMP_FILE)"
else
cat $TMP_FILE | ...... (3 Replies)
Discussion started by: fox1212
3 Replies
8. Shell Programming and Scripting
Hi all, new to the threads as well as Unix/Linux. I need to create a script that will delete any temporary files as well as check the files on the system for errors or corruption. This is what I have so far and I'm sure that I'm missing things or have the wrong commands. I'm not sure where to go... (3 Replies)
Discussion started by: Bwood1377
3 Replies
9. Shell Programming and Scripting
Hello I am trying to append an incrimenting number to the end of each line I have it working with a temp file. But I want to do this without a temp file.
a=1
cat "file" | while read LINE
do
echo "$LINE, $a" >> filewithnumbers
a=`expr $a + 1`
... (4 Replies)
Discussion started by: rorey_breaker
4 Replies
10. UNIX for Dummies Questions & Answers
Need help to resolve this message "NOQUEUE: low on space (have 18, SMTP-DAEMON needs 101 in /var/spool/mqueue)"
Attached capture file from server HPUX 10.2 Ace
root@PS01 : Aug 13 18:27:30 SANG last message repeated 7 times
Aug 13 18:27:45 PS01 sendmail: NOQUEUE: low on space (have 18,... (2 Replies)
Discussion started by: real-chess
2 Replies