10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Good Morning,
i ran into some trouble this morning while 'improving' my monitoring stuff. i would like to get a warning when the number of mails sent (outbound) by postfix is above a certain number. so far, so easy. to test that i simply put
cat /var/log/mail.info | grep 'to=<' | grep -v -e... (1 Reply)
Discussion started by: Mike
1 Replies
2. UNIX for Beginners Questions & Answers
PH=(6H 0 0 JD 9S 0 KD 0) #input from .txt file
In the above array, I am trying to get the computer to tell me at what indices the non-zeros are at.
I don't understand why this doesn't work...
grep -v -b "0" ph.txt > position.txt
Isn't grep -v supposed to show non matches in Bash?... (2 Replies)
Discussion started by: cogiz
2 Replies
3. Shell Programming and Scripting
i have this line of code that looks for the same file if it is currently running and returns the count.
`ps -eaf -o args | grep -i sfs_pcard_load_file.ksh | grep -v grep | wc -l`
basically it is assigned to a variable
ISRUNNING=`ps -eaf -o args | grep -i sfs_pcard_load_file.ksh |... (6 Replies)
Discussion started by: wtolentino
6 Replies
4. OS X (Apple)
Hi,
I'm using Mac 10.9.1. I would like to create an alias for grep so that it won't print out messages like "grep: /Users/davea/workspace/myproject/subdir/: Is a directory" all the time. So in my terminal, I opened ~/.profile and entered
alias grep='grep -s'
However, when I close and... (5 Replies)
Discussion started by: laredotornado
5 Replies
5. UNIX for Dummies Questions & Answers
I have a text file (allWords.txt), that I would like to search through. Here is a snippet of what it looks like...
a
aah
aahed
aahing
aahs
aardvark
aardvarks
aardwolf
ab
abaci
aback
abacus
abacuses
abaft
......
I would like to use the grep search to search, line by line, for... (8 Replies)
Discussion started by: blackvelvet
8 Replies
6. Shell Programming and Scripting
Hi everyone, thank you so much for reading.
I built a user reference page from /etc/password for a class project. Now I need two shell scripts: 1) Add names to the reference page 2) Delete names from the reference page. I know grep -v is involved somehow and some piping but I am super stuck.
... (1 Reply)
Discussion started by: jsmpdx
1 Replies
7. Shell Programming and Scripting
Hi,
I search for the string below which contains a single quote,
some text '/home/myuser
in the file myfile.txt as another user with the grep command as follows
su - myuser -c "grep 'some text \'/home/myuser' myfile.txt"
I also tried using two backslashes
su - myuser... (6 Replies)
Discussion started by: cimcmahon
6 Replies
8. UNIX for Dummies Questions & Answers
Hi there, I'm new to unix-environments.
I'm richard, and i'm mostly a web-developer, under php. I've done work in unix env before, but never had my own.
Today, I've got debian 3.1 r4 from the official site, and i've attempted to install it twice.
I installed it initially as "Desktop... (0 Replies)
Discussion started by: izua
0 Replies
9. Solaris
I'm not sure where to post this but it's happening on a SunOS 5.8 server so I'll try here.
I've discovered some unexpected behavior when using tr.
For example:
echo a | tr
Z
echo b | tr
a
echo a | tr
B
echo a | tr
B
echo a | tr
A (8 Replies)
Discussion started by: Mike@Work
8 Replies
10. Shell Programming and Scripting
Frenz,
I have a file with certain columns from ls -lR which looks something like:
file stemp
----------
lrwxrwxrwx ./temp/s1 -> 2.ksh
lrwxrwxrwx ./temp/s2 -> 3.ksh
lrwxrwxrwx ./temp/subtemp/s3 -> 1.ksh
lrwxrwxrwx ./temp/subtemp/s4 -> 2.ksh
lrwxrwxrwx ./temp/s5 -> ... (9 Replies)
Discussion started by: manthasirisha
9 Replies