10 More Discussions You Might Find Interesting
1. UNIX for Beginners Questions & Answers
Hi All,
i want to write a shell script read below file line by line and want to exclude the lines which contains empty value for MOUNTPOINT field.
i am using centos 7 Operating system.
want to read below file.
# cat /tmp/d5
NAME="/dev/sda" TYPE="disk" SIZE="60G" OWNER="root"... (4 Replies)
Discussion started by: balu1234
4 Replies
2. Shell Programming and Scripting
Hello ,
I will need your help once again.
I have the following file:
cat file02.txt
PATTERN XXX.YYY.ZZZ. 500
ROW01 aaa. 300 XS 14
ROW 45 29 AS XD.FD.
PATTERN 500 ZZYN002
ROW gdf gsste
ALT 267 fhhfe.ddgdg.
PATTERN ERE.MAY. 280
PATTERRNTH 5000 rt.rt.
ROW SO a 678
PATTERN... (2 Replies)
Discussion started by: alex2005
2 Replies
3. Shell Programming and Scripting
Hi All,
I have a requirement that i need to list only the missing sequences with a unix script.
For Example:
Input:
FILE_001.txt
FILE_002.txt
FILE_005.txt
FILE_006.txt
FILE_008.txt
FILE_009.txt
FILE_010.txt
FILE_014.txt
Output:
FILE_003.txt
FILE_004.txt
FILE_007.txt
FILE_011.txt... (5 Replies)
Discussion started by: Arun1992
5 Replies
4. Shell Programming and Scripting
Hi,
I have a file like below.
1,2,3,4,5,6,7,8,9I would like to print or copied to a file based of line count in perl
If I gave a condition 1 to 3 then it should iterate over above file and print 1 to 3 and then again 1 to 3 etc.
output should be
1,2,3
4,5,6
7,8,9 (10 Replies)
Discussion started by: Anjan1
10 Replies
5. UNIX for Dummies Questions & Answers
Hello All ,
I have a file which needs to split based on the blank lines
Name ABC
Address London
Age 32
(4 blank new line)
Name DEF
Address London
Age 30
(4 blank new line)
Name DEF
Address London (8 Replies)
Discussion started by: Pratik4891
8 Replies
6. Shell Programming and Scripting
I have two files.
File1
>gi|11320906|gb|AF197889.1|_Buchnera_aphidicola
ATGAAATTTAAGATAAAAAATAGTATTTT
>gi|11320898|gb|AF197885.1|_Buchnera_aphidicola
ATGAAATTTAATATAAACAATAAAA
>gi|11320894|gb|AF197883.1|_Buchnera_aphidicola
ATGAAATTTAATATAAACAATAAAATTTTT
File2
AF197885 Uroleucon aeneum... (2 Replies)
Discussion started by: pathunkathunk
2 Replies
7. Shell Programming and Scripting
This is a variation of an earlier post found here:
unixcom/shell-programming-scripting/159821-merge-two-non-consecutive-lines.html
User Bartus11 was kind enough to solve that example.
Previously, I needed help combining two lines that are non-consecutive in a file. Now I need to do the... (7 Replies)
Discussion started by: munkee
7 Replies
8. Shell Programming and Scripting
I have a file with ~200K lines, I need to delete 4K lines in it. There is no range.
I do have the line numbers of the lines which I want to be deleted.
I did tried using
> cat del.lines
sed '510d;12d;219d;......;3999d' file
> source del.lines
Word too long.
I even tried... (2 Replies)
Discussion started by: novice_man
2 Replies
9. Shell Programming and Scripting
Hi all,
I have a file with little blocks beginning with a number 761XXXXXX, and 0, 1, 2 or 3 lines below of it beginning with STUS as follow:
761625820
STUS ACTIVE 16778294
STUS NOT ACTIVE
761157389
STUS ACTIVE 16778294
761554921
STUS ACTIVE 16778294
STUS NOT ACTIVE
STUS ACTIVE OP... (4 Replies)
Discussion started by: cgkmal
4 Replies
10. Shell Programming and Scripting
I need to have an if statement in a script to run if there are certain processes running. Easiest way I can see to do this is to run a ps and grep the results based on what I am looking for:
$ ps -ef | grep wtrs
---
webtrend 5046 1 0 May 12 ? 0:28 /webtrends/versions/6.1/wtrs_ui... (6 Replies)
Discussion started by: LordJezo
6 Replies