10-15-2015
Thank you
RavinderSingh13 for the comment. Query 1 is resolved if I place the file with less lines as file1 and that with more lines as file 2. But I need a script irrespective of the file order. And it should be applied to many files (42 in my case).
Query 2 still persists, but it is not a major issue. I will overcome it.
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
Hi,
Could anyone help me in changing a tabular format output to comma seperated file pls in K-sh. Its very urgent.
E.g : username empid
------------------------
sri 123
to
username,empid
sri,123
Thanks,
Hema:confused: (2 Replies)
Discussion started by: Hemamalini
2 Replies
2. Shell Programming and Scripting
Hi,
I have a list of 70 files in a directory and I need to merge the content of each file into one big matrix file (71 columns x 3060 rows).
Each file has the following format only two columns per file:
unique identifier1
randomtext1 randomtext1
a 5
b 3
c 6
d 3
e 2... (11 Replies)
Discussion started by: labrazil
11 Replies
3. AIX
Hello.
Could you please help to know the command to merge multiple text files into one?
I am thinking to use:
cat f1.txt f2.txt f3.txt > f4.txt
Is it okay to use cat command for same purpose - Or could there be any disadvantage in using it?
Thank you (4 Replies)
Discussion started by: panchpan
4 Replies
4. UNIX for Dummies Questions & Answers
hi all,
i have three files naming file1 , file2, file3 .
i want to merge the content of these three files, sort them and display the sorted output on the screen page by page. (1 Reply)
Discussion started by: sonu_pal
1 Replies
5. Shell Programming and Scripting
Hello, hopefully this is an easy on for the AWK guru's out there. I'm having some trouble figuring out how to match+merge data in 2 files into 1 single report.
I've got my 2 files filtered and delimited, just need to MATCH $3 in file1 to $1 in file2, then put $0 from File1 and $2+$3 from File2... (6 Replies)
Discussion started by: right_coaster
6 Replies
6. Shell Programming and Scripting
Hi,
I have a data file with :
01/28/2012,1,1,98995
01/28/2012,1,2,7195
01/29/2012,1,1,98995
01/29/2012,1,2,7195
01/30/2012,1,1,98896
01/30/2012,1,2,7083
01/31/2012,1,1,98896
01/31/2012,1,2,7083
02/01/2012,1,1,98896
02/01/2012,1,2,7083
02/02/2012,1,1,98899
02/02/2012,1,2,7083
I... (1 Reply)
Discussion started by: himanish
1 Replies
7. Shell Programming and Scripting
Hi,
I have directory with multiple files from which i need to extract portion of specif lines and insert it in a new file, the new file will contain a separate columns for each file data.
Example:
I need to extract Value_1 & Value_3 from all files and insert in output file as below:
... (2 Replies)
Discussion started by: belalr
2 Replies
8. UNIX for Dummies Questions & Answers
Hello,
I'm new to this forum. I have always made good use of all the wise hints shown here. But this time I'm struggling with an issue that is driving me crazy.
I have two text files, I have to merge them based on the first column, resulting file must contain all record from the first file... (4 Replies)
Discussion started by: emare
4 Replies
9. Shell Programming and Scripting
I have to sort below output in text file in unix bash
20170308
DA,I,113
20170308
PM,I,123
20170308
DA,U,22
20170308
PM,U,123
20170309
DA,I,11
20170309
PM,I,23
20170309
DA,U,123
20170309
PM,U,233 (8 Replies)
Discussion started by: Adfire
8 Replies
LEARN ABOUT DEBIAN
bup-margin
bup-margin(1) General Commands Manual bup-margin(1)
NAME
bup-margin - figure out your deduplication safety margin
SYNOPSIS
bup margin [options...]
DESCRIPTION
bup margin iterates through all objects in your bup repository, calculating the largest number of prefix bits shared between any two
entries. This number, n, identifies the longest subset of SHA-1 you could use and still encounter a collision between your object ids.
For example, one system that was tested had a collection of 11 million objects (70 GB), and bup margin returned 45. That means a 46-bit
hash would be sufficient to avoid all collisions among that set of objects; each object in that repository could be uniquely identified by
its first 46 bits.
The number of bits needed seems to increase by about 1 or 2 for every doubling of the number of objects. Since SHA-1 hashes have 160 bits,
that leaves 115 bits of margin. Of course, because SHA-1 hashes are essentially random, it's theoretically possible to use many more bits
with far fewer objects.
If you're paranoid about the possibility of SHA-1 collisions, you can monitor your repository by running bup margin occasionally to see if
you're getting dangerously close to 160 bits.
OPTIONS
--predict
Guess the offset into each index file where a particular object will appear, and report the maximum deviation of the correct answer
from the guess. This is potentially useful for tuning an interpolation search algorithm.
--ignore-midx
don't use .midx files, use only .idx files. This is only really useful when used with --predict.
EXAMPLE
$ bup margin
Reading indexes: 100.00% (1612581/1612581), done.
40
40 matching prefix bits
1.94 bits per doubling
120 bits (61.86 doublings) remaining
4.19338e+18 times larger is possible
Everyone on earth could have 625878182 data sets
like yours, all in one repository, and we would
expect 1 object collision.
$ bup margin --predict
PackIdxList: using 1 index.
Reading indexes: 100.00% (1612581/1612581), done.
915 of 1612581 (0.057%)
SEE ALSO
bup-midx(1), bup-save(1)
BUP
Part of the bup(1) suite.
AUTHORS
Avery Pennarun <apenwarr@gmail.com>.
Bup unknown- bup-margin(1)