8 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi All,
I am getting a syntax error message while trying to compare 2 files using the compare function (LINUX)
command substitution: line 79: syntax error near unexpected token `('
command substitution: line 79: `cmp -s <(tr , \n < $COMMON_TMP/nt_per_gs.done | sort) <(tr , \n <... (5 Replies)
Discussion started by: dsfreddie
5 Replies
2. Shell Programming and Scripting
Moderator, please, delete this topic (1 Reply)
Discussion started by: optik77
1 Replies
3. Shell Programming and Scripting
i recently copied 400GB of data from a NTFS drive to a ext4 drive. I want to verify that the data is 100% identical to the original.
I wanted to use cmp but it only does two files. The directory that was copied contains many subdirectories and all sorts of files (not just text).
So I guess... (5 Replies)
Discussion started by: fuzzylogic25
5 Replies
4. Solaris
Dear all,
for i in <List of Filename>
FILENAME=`echo $i`
do
cp -p $FILENAME /temp
/bin/cmp $FILENAME /temp/$FILENAME
done
I am planning to do something like this on a daily basis, so i want to ask that, if the comparison on the files encounter error,
... (2 Replies)
Discussion started by: beginningDBA
2 Replies
5. Shell Programming and Scripting
Hi All,
I have to compare set of files so I created a case statement with the option to give more than one file to compare. The Problem now i am facing is, if I compare the files directly, from prompt or just using the script only for a particular file then It's saying No difference, but If I... (4 Replies)
Discussion started by: Sudhar
4 Replies
6. Shell Programming and Scripting
Please don't count this as a similar post.....I got the ftp part working....I am stuck how to find the files between two dates.
I have 5 files
filename.20090505.txt
filename.20090504.txt
filename.20090503.txt
filename.20090502.txt
filename.20090501.txt
My load date is 20090501 and run date... (5 Replies)
Discussion started by: RubinPat
5 Replies
7. UNIX for Dummies Questions & Answers
Hi I have two variables contining a set of near identical lines, i'd like to list the lines that differ? Prefereably i'd like not to save the variables into a file first.
i.e
var1
tag:val1
tag:val2
tag:val3
var2
tag:val1
tag:val4
tag:val3
i'd like the result to print out... (2 Replies)
Discussion started by: nickrick
2 Replies
8. Shell Programming and Scripting
Hello,
I want to compare two files. All records in file 2 that are not in file 1 should be output to file 3.
For example:
file 1
123
1234
123456
file 2
123
2345
23456
file 3 should have
2345
23456
I have looked at diff, bdiff, cmp, comm, diff3 without any luck! (2 Replies)
Discussion started by: blt123
2 Replies
bdiff(1) User Commands bdiff(1)
NAME
bdiff - big diff
SYNOPSIS
bdiff filename1 filename2 [n] [-s]
DESCRIPTION
bdiff is used in a manner analogous to diff to find which lines in filename1 and filename2 must be changed to bring the files into agree-
ment. Its purpose is to allow processing of files too large for diff. If filename1 (filename2) is -, the standard input is read.
bdiff ignores lines common to the beginning of both files, splits the remainder of each file into n-line segments, and invokes diff on cor-
responding segments. If both optional arguments are specified, they must appear in the order indicated above.
The output of bdiff is exactly that of diff, with line numbers adjusted to account for the segmenting of the files (that is, to make it
look as if the files had been processed whole). Note: Because of the segmenting of the files, bdiff does not necessarily find a smallest
sufficient set of file differences.
OPTIONS
n The number of line segments. The value of n is 3500 by default. If the optional third argument is given and it is numeric, it is
used as the value for n. This is useful in those cases in which 3500-line segments are too large for diff, causing it to fail.
-s Specifies that no diagnostics are to be printed by bdiff (silent option). Note: However, this does not suppress possible diagnos-
tic messages from diff, which bdiff calls.
USAGE
See largefile(5) for the description of the behavior of bdiff when encountering files greater than or equal to 2 Gbyte ( 2**31 bytes).
FILES
/tmp/bd?????
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWesu |
+-----------------------------+-----------------------------+
|CSI |enabled |
+-----------------------------+-----------------------------+
SEE ALSO
diff(1), attributes(5), largefile(5)
DIAGNOSTICS
Use help for explanations.
SunOS 5.10 14 Sep 1992 bdiff(1)