8 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All
I am trying to remove the line having specific pattern from a file by using sed command
I have the file named ODS_REP_SRCE_File.txt with content as:
... (1 Reply)
Discussion started by: Shilpi Gupta
1 Replies
2. Shell Programming and Scripting
Hi everyone!
I'm writting a function in .bashrc to extract some text from a file. The file looks like this:
" random text
Begin CG step 1
random text
Begin CG step 2
...
Begin CG step 100
random text"
For a given number, let's say 70, I want all the text between "Begin CG... (4 Replies)
Discussion started by: radudownload
4 Replies
3. UNIX for Dummies Questions & Answers
Hi,
I have a file like this-
aa
12
23
34
aa
21
34
56
aa
78
45
56
I want to print out only the lines after the last aa. How do I do this? I tried using grep -A and sed -n, but both didnt work as I wanted to.
Could someone help me out please.. (3 Replies)
Discussion started by: jamie_123
3 Replies
4. Shell Programming and Scripting
Hello,
anyone could me explain what does this line script really do?( sed -e "/^#/d" -e "s/#.*$$//" /var/tmp/map.cgd ) | ( awk '{for (i = 2; i <= NF; i++) print $$i, $$0}' )
Moreover... why $$ on second sed instruction?!? What does it means?
Thanks
gb
---------- Post updated at 11:38... (1 Reply)
Discussion started by: gogol_bordello
1 Replies
5. Shell Programming and Scripting
Hi All,
I need to extract 543 from the command below :
# pvscan
PV /dev/sdb1 VG vg0 lvm2
Total: 1 543.88 GB] / in use: 1 / in no VG: 0
I have the following command which does the job, but I think this could be achieved in a more simple way using sed or awk. Any help is... (7 Replies)
Discussion started by: nua7
7 Replies
6. Shell Programming and Scripting
Hi there,
My samba configuration file looks like that :
...
...
path = /home/samba/profiles/
...
path = /home/samba/shares/family
valid users = family
path = /home/samba/shares/admins
valid users = admins
path = /home/samba/shares/publicI want to extract the list of standard... (3 Replies)
Discussion started by: chebarbudo
3 Replies
7. Shell Programming and Scripting
Hi! I'm trying to find a way to extract a certain amount of lines from a log file. This would allow me to "follow" a web user through our log files.
Here is a sample fake log file to explain what i want to accomplish :
BEGIN REQUEST sessionID=123456
boatload of lines for thread-1 detailing... (8 Replies)
Discussion started by: gnagus
8 Replies
8. Shell Programming and Scripting
Forgive me if this is a dumb question...I'm a Windows sys admin with little programming knowledge.
I have files containing anywhere from 3 to 200 lines. Using SED, I want to extract only lines containing a specific instance of "ISS." It is possible that "ISS" will occur several times in a... (10 Replies)
Discussion started by: thuston22
10 Replies