10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hello,
I have a src code file where I need to uncomment many lines.
The lines I need to uncomment look like,
C CALL l_r(DESNAME,DESOUT, 'Gmax', ESH(10), NO_APP, JJ)
The comment is the "C" in the first column. This needs to be deleted so that there are 6 spaces preceding "CALL".... (7 Replies)
Discussion started by: LMHmedchem
7 Replies
2. Shell Programming and Scripting
Hello,
I need to collect some statistical results from a series of files that are being generated by other software. The files are tab delimited. There are 4 different sets of statistics in each file where there is a line indicating what the statistic set is, followed by 5 lines of values. It... (8 Replies)
Discussion started by: LMHmedchem
8 Replies
3. Shell Programming and Scripting
I need to create a shell script to delete multiple items (Strings) at a time from a file.
I need to iterate through a list of strings.
My plan is to create an array and then iterate through the array.
My code is not working
#!/bin/bash -x
declare -a array=(one, two, three, four)... (5 Replies)
Discussion started by: bash_in_my_head
5 Replies
4. UNIX for Dummies Questions & Answers
I am performing a regular check on UNIX servers which involves logging onto UNIX servers and using the grep command to check if a GID exists in the /etc/group directory
e.g. grep 12345 /etc/group
I have five to check on each server, is there anyway I can incorporate them into one command and... (2 Replies)
Discussion started by: @MeDaveT
2 Replies
5. Shell Programming and Scripting
Hello,
I am new to shell scripting. I need to write a shell script where i can grep the name of file ie. .sh file and log file from crontab -l.
#51 18 * * * /home/oracle/refresh/refresh_ug634.sh > /home/oracle/refresh/refresh_ug634.sh.log 2>&1
#40 17 * * * /home/oracle/refresh/refresh_ux634.sh... (1 Reply)
Discussion started by: guptra
1 Replies
6. UNIX for Advanced & Expert Users
I have a file against which I can grep a string for. I can also check for that string count using wc -l (or grep -c). I need to display the results of both in one output i.e. 'line containing string' and 'count' - what would be the most efficient way of managing this? Thanks in advance. (3 Replies)
Discussion started by: haider1
3 Replies
7. Shell Programming and Scripting
Hi All,
Need help on this
I have 2 files
one file file1 which has several entries as :
define service{
hostgroup_name !host1,!host5,!host6,.*
service_description check_nrpe
}
define service{
hostgroup_name !host2,!host4,!host6,.*
service_description check_opt
}
another... (2 Replies)
Discussion started by: namitai
2 Replies
8. Shell Programming and Scripting
I have a need to compare 2 files, then print results to file. Need to find items from file2 that are not found in file 1. thanks in advance!
example:
file 1:
abcde=12
fffff=6
bbbb=35
file2:
abcde=12
fffff=6
bbbb=35
ccccc=10
kkkkk=45 (8 Replies)
Discussion started by: discostu
8 Replies
9. Shell Programming and Scripting
Hi,
i need a script, which deletes doulbe items in a file.
My file looks like:
-
-
-
xxx
xxx
G123
G234
G234
G234
o
o
...
First i want to sort the file an then i want to delete double items.
Can anyone help me. I work under solaris10. (3 Replies)
Discussion started by: free2k
3 Replies
10. Shell Programming and Scripting
Please assist with awk scirpts:
I need to remove items from a file in a batch:
The file that I will remove from has the following format:
abc00tef:10.81.12.3
abc01tef:10.81.12.3
abc02tef:10.81.12.3
abc03tef:10.81.12.3
abc04tef:10.81.12.3
abc05tef:10.81.12.3
I have a file which... (5 Replies)
Discussion started by: amir07
5 Replies