10 More Discussions You Might Find Interesting
1. UNIX for Advanced & Expert Users
Hi,
We have few hundered scripts using cut command in thousands of lines. On HP-UX shell script developer used echo "ABCEFG" | cut -c -1-3 to cut first three character of the string. We recently moved to Linux and this command throws error. I think this might be due to different version of... (3 Replies)
Discussion started by: ajazurrahman
3 Replies
2. UNIX for Advanced & Expert Users
at which situation uniq command fails.
How to delete/remove duplicate lines in an unix file (1 Reply)
Discussion started by: tp2115
1 Replies
3. Shell Programming and Scripting
Here is my test script:
#!/bin/sh
result=`jobs`
echo "
Jobs:
"$result
result=`ls`
echo "
LS
"$result
Here is the output:
Jobs:
LS
0 1 2 3 4 5 6 7 gcd initialize.sh #inter_round_clean.sh# inter_round_clean.sh inter_round_clean.sh~ look parallel_first_run.sh... (3 Replies)
Discussion started by: nealh
3 Replies
4. Shell Programming and Scripting
Hi,
I need to count number of '$' symbol in a file and assign it to a variable.
I am using below command.
grep -c '\$' inputfile
O/p:
10359
Its giving correct o/p but when I am assigning the same to a variable its giving completely different o/p.
ab1=`grep -c '\$' inputfile`
$... (3 Replies)
Discussion started by: Opamps123
3 Replies
5. Shell Programming and Scripting
hi,
The following mail cmd executed successfully.
mailx -s 'subject' user@company.com < testfile.dat
However When i include this mail cmd in shell script it behave odd. Getting an error message mailx comand not found. (2 Replies)
Discussion started by: zooby
2 Replies
6. UNIX for Advanced & Expert Users
Running the find command as: find /abc -follow -ls gives, for some files, the message, which I have never seen before:
find: /abc/def/123.txt: No error
Does it mean that find found the file with out error. If it found it without error then why did it not output the "ls" particulars as with... (2 Replies)
Discussion started by: twk
2 Replies
7. Shell Programming and Scripting
Im trying to execute the below command on our server to list files and replace the newline in the file list with spaces, but the character 'n' is getting replaced with a space, is there any environment variable that needs to be set in UNIX?
sh -c 'ls -trx... (1 Reply)
Discussion started by: rameshrr3
1 Replies
8. Shell Programming and Scripting
I call....
cat 1.txt | uniq -c
Sample of whats in 1.txt
vmstat
cd
exit
w
cd
cd
cd
newgrp
xinit
f
cd
cd
cd
rlogin (2 Replies)
Discussion started by: Bandit390
2 Replies
9. Shell Programming and Scripting
Help needed - I am sure there is something to do with tabs or white space that is killing me here..
I have a file that is generated from an oracle sql script - when I cat the file I see the below
601888725 14-AUG-08-10:20 3
601888726 14-AUG-08-10:37 ... (4 Replies)
Discussion started by: frustrated1
4 Replies
10. UNIX for Dummies Questions & Answers
Hi
I am using awk command for string replacement.
I have 2 servers. The command runs perfectly well on 1st server
On the second server when i run the command on the same datset
The command gets stuck while processing a large piece of record..
Does it have anything to with setting on the 2... (1 Reply)
Discussion started by: aixjadoo
1 Replies