10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
i have a file say test with the below mentioned details
Folder Name Total space Space used
/test/test1 500.1GB 112.0 GB
/test/test2 3.2 TB 5TB
/test/test3 3TB 100GB
i need to calculate percentage of each row based on total space and space used and copy... (9 Replies)
Discussion started by: venkitesh
9 Replies
2. Shell Programming and Scripting
Hi, i have a large file like this:
Contig1 1 5
Contig1 2 4
Contig1 3 3
Contig1 4 5
Contig1 5 3
Contig1 6 4
Contig2 1 3
Contig2 2 7
Contig2 3 2
Contig2 4 9
Contig2 5 10
Contig2 6 3
Contig2 7 7
Contig2 8 2
Contig2 9 7
Contig2 10 5
contig1 2 4
contig1 3 3
contig1 4 5 (3 Replies)
Discussion started by: the_simpsons
3 Replies
3. Shell Programming and Scripting
for i in `lsvg`
do
echo "VG Name:" $i
echo "Total VG Size:"
lsvg $i |grep "TOTAL PPs:" |awk '{print $7}' | cut -c2-
echo "Free VG Size:"
lsvg $i |grep "FREE PPs:" | awk '{print $7}' | cut -c2-
done
The PP Sizes are in MB. I like to have the sizes in GB.
Also, I like to have the... (14 Replies)
Discussion started by: Daniel Gate
14 Replies
4. Shell Programming and Scripting
nawk -F, 'NR==FNR{file=FILENAME;a++;next} a{if(FILENAME~file)next;b++;}
END{ for(i in a){if(a && !b){print "NEW: "i}} for(i in b){if(b)print i"\t\t"b}}' OFS=, 123.csv *.csv
I need to include 123.csv into the equation for the total output currently it compares whatever is on 123.csv against... (27 Replies)
Discussion started by: llcooljatt
27 Replies
5. Shell Programming and Scripting
Hi All,
I have a text file which is only one column. I want to multiply all these values in file1.txt by 0.01 and get the output.txt
file1.txt
65
85
90
...
output.txt
0.65
0.85
0.90
...
Thanks.
Please use code tags when posting data and code samples! (2 Replies)
Discussion started by: senayasma
2 Replies
6. Shell Programming and Scripting
Hi Gurus,
I am working with a korn shell script to simplify some operations of calculation number of lines inside compressed file.
The called function (inside a cycle) is the following:
#########################################
# F.ne: CheckCount
#########################################... (3 Replies)
Discussion started by: GERMANICO
3 Replies
7. Shell Programming and Scripting
Could someone till me what this calculation really means
let foo=`date "+(1%H-106)*60+1%M-100"` bar=foo+1440 (4 Replies)
Discussion started by: freddie999
4 Replies
8. Shell Programming and Scripting
Hello Friends,
Im calculating file sizes with below AWK script. I do this before some spesific files are transferred. I run the script it works but after several running it stuck with a limit of 2147483647 (2 Gbytes -1 byte) and cant exceed this. Something is wrong and I can't proceed, would... (1 Reply)
Discussion started by: EAGL€
1 Replies
9. UNIX for Dummies Questions & Answers
Trying to do some simple maths on a large file. Excel works fine but I have 1 million entries:
If the difference between a number in column 2 and the one above it is more than 100 the insert a new line
8 4001 4100
8 4101 4200
8 4201 4300
8 15901 16000
8 15910 ... (1 Reply)
Discussion started by: dr_sabz
1 Replies
10. Shell Programming and Scripting
Hi, I am in ksh88
I am trying to get the result of the calculation using 3 variables:
TOTAL
CAPACITY
and get the following error:
$DB_CAPACITY=(( $DB_SIZE * 100 / $TOTAL ))
ksh: syntax error: `((' unexpected
I cannot figure out what am I doing wrong... Thanks for any help -A (2 Replies)
Discussion started by: aoussenko
2 Replies