10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi,
I have two files:
File1:
sample statements1
<UID = " " PWD = " ">
sample statements2
File2:
UID ="admin"
PWD ="password" (6 Replies)
Discussion started by: manid
6 Replies
2. Shell Programming and Scripting
Hi
I've to remove the files which has the following file pattern in path /home/etc/logs
fnm_HST_date1
fnm_hst_date1
fnm_HST_date2
I've used the following code to to remove the files having file names like "HST" .
#!/usr/bin/ksh
set -x
file_path=/home/etc/logs
file_nm=HST
find... (2 Replies)
Discussion started by: smile689
2 Replies
3. UNIX for Dummies Questions & Answers
I have the following script that greps lines containing "AT" from data files data1.hsq through data1000.hsq, then cuts their second column and puts in data files called perm1 through perm1000.
I want to modify the script so that instead of putting the data in separate data files perm1 through... (2 Replies)
Discussion started by: evelibertine
2 Replies
4. Shell Programming and Scripting
Hi
I am trying to filter some data using awk. I have a statement-
awk 'BEGIN { FS = "\n" ; RS = "" } { if ( $6 = "City: " ) { print "City: Unknown" } else { print $6 } }'`
The $6 values are
City: London
City: Madrid
City:
City: Tokyo
This expression seems to catch all the lines... (4 Replies)
Discussion started by: jamie_123
4 Replies
5. UNIX for Dummies Questions & Answers
Hello,
I'm using Ubuntu Netbook Edition on my family's 4 netbooks. Sadly (and a big mistake in my opinion?), I can't add a temp monitoring applet to my panel, but that's not really the point. I am needing a way to monitor my computer temps that includes a graph (kinda like a CPU usage ... (0 Replies)
Discussion started by: Narnie
0 Replies
6. UNIX for Advanced & Expert Users
Hi,
I'm trying to remove rows that including specific word, but the below is replacing only the first occurrence, how to do this for the all occurrences within the file.
grep -v "mdsMVLink\|mdsMVMembership\|mdsMVLinkType" sfile.txt > dfile.txt
Could someone help me how to accomplish this?
... (2 Replies)
Discussion started by: john_prince
2 Replies
7. Shell Programming and Scripting
Hello,
I was using a shell script for sending contents of a text file(email.report) to different users.
I was using the below command in my script to send email...
cat email.report | /usr/bin/mailx -s $REQ_SUBJECT -h 5 abc@xyz.com
It was working fine all these days but now all of a sudden it... (18 Replies)
Discussion started by: smarty86
18 Replies
8. Shell Programming and Scripting
Hi,
I have a script that checks the length of each record/line in file - This seems to be working when there are no special systems character that are invisible or hidden.
awk -v file=$file '{
if (filename==file)
{ k+=$5
if (length() <= 10 ){print size length(), "bytes " k}
}... (2 Replies)
Discussion started by: asemota
2 Replies
9. Shell Programming and Scripting
Hi,
I have a sql file that runs something like this
vi Test.sql
REVOKE EXECUTE ON DEMO_USER.SQC_SAMP FROM PUBLIC;
REVOKE EXECUTE ON DEMO_USER.SQC_SAMP FROM DEMO_READ;
REVOKE SELECT ON DEMO_USER.DEMO_NOMINEE_TEST FROM DEMO_READ;
REVOKE EXECUTE ON DEMO_USER.SQC_SAMP FROM... (3 Replies)
Discussion started by: rajan_san
3 Replies
10. Shell Programming and Scripting
hello All,
I need to invoke by perl script some program/command and monitor it for 5
minutes . In case it still running for more then 5 min I need to send a signal which will stop it.
I implemeted this as shown below by using eval & alarm
and I'd like to know if there is a better way to... (1 Reply)
Discussion started by: Alalush
1 Replies