10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
In the bash below the user selects the file to be used. The digits of each file are unique and used to automatically locate the next file to be used in the process. The problem I can not seem to fix is that the full path needs to be referenced in the second portion and it is not currently. Is... (7 Replies)
Discussion started by: cmccabe
7 Replies
2. Shell Programming and Scripting
hello,
i need a bit of help on how to do this effectively in bash without a lot of extra looping or massive switch/case
i have a long array of M elements and a short array of N elements, so M > N always. M is not a multiple of N.
for case 1, I want to stretch N to fit M
arrayHuge
H = (... (2 Replies)
Discussion started by: f77hack
2 Replies
3. Shell Programming and Scripting
I am new to bash scripting. I want write a script that reads from the first argument file and run nslookup, then prints out each nslookup. Something like below:
File name = ip
8.8.8.8
8.8.4.4
Bash shell script: nslookup.sh
#!/bin/bash
for i in $1
do
nslookup $i
done
I... (7 Replies)
Discussion started by: boldnbeautiful
7 Replies
4. Shell Programming and Scripting
Trying to do some control flow parsing based on the index postion of an array member. Here is the pseudo code I am trying to write in (preferably in pure bash) where possible. I am thinking regex with do the trick, but need a little help.
pesudo code
if == ENDSINFIVEINTS ]]; then
do... (4 Replies)
Discussion started by: briandanielz
4 Replies
5. UNIX for Dummies Questions & Answers
Hi,
I have an input file which contain below records:
a,1
b,2
c,3
a,10
b,34
i have a reference file which contains below records:
a,AA
b,BB
c,CC
My required output is : (3 Replies)
Discussion started by: pandeesh
3 Replies
6. Shell Programming and Scripting
I'm at wits end with this issue and my troubleshooting leads me to believe it is a problem with the file formatting of the array referenced by my script:
awk -F, '{if (NR==FNR) {a=$4","$3","$2}\
else {print a "," $0}}' WBTSassignments1.txt RNCalarms.tmp
On the WBTSassignments1.txt file... (2 Replies)
Discussion started by: JasonHamm
2 Replies
7. UNIX for Advanced & Expert Users
Write a quick shell snippet to find all of the IPV4 IP addresses
in any and all of the files under /var/lib/output/*, ignoring
whatever else may be in those files. Perform a reverse lookup on
each, and format the output neatly, like "IP=192.168.0.1,
... (0 Replies)
Discussion started by: choco4202002
0 Replies
8. UNIX for Dummies Questions & Answers
i am having one file which is of CSV format with two fields client_id and client_nbr.The sample data is lke below
ABC,1250
CDE,1520
EFG,1000
PQR,1800
The client nbr for these clients change frequently.So i want to create one lookup file every week for the changed client and run a script... (3 Replies)
Discussion started by: dr46014
3 Replies
9. Shell Programming and Scripting
Hi All
I have got a fixed length file of 80bytes long.The first 4bytes of each record represents a client_number.I need to modify the client number based on another lookup file.
The lookup file contains 2 fields and a comma delimited file.The first line of the lookup file contains the header... (5 Replies)
Discussion started by: dr46014
5 Replies
10. UNIX for Dummies Questions & Answers
We have Unix configured as our external DNS, forward DNS is working properly, however Reverse lookup is not working. Any idea what the problem is? I have checked the named.boot and .rev file and everything seems to be correctly. However it appears that the reverse zone file in the named.boot... (2 Replies)
Discussion started by: cassy
2 Replies