Sponsored Content
Top Forums Shell Programming and Scripting Tool to compare two Linux machines Post 302911568 by Corona688 on Friday 1st of August 2014 12:01:50 PM
Old 08-01-2014
diff? diff file1 file2 to show differences between the two.
 

10 More Discussions You Might Find Interesting

1. IP Networking

troubles networking Windows machines to RH7.1 Linux

i hear everyone talking about this SAMBA "service" that comes with Linux distros...im having no luck getting this to work, neither one of the boxes on the network sees each other. im only an intermediate level user of Linux...Networking with Windows machines is relatively new to me, so you can... (3 Replies)
Discussion started by: fuji250
3 Replies

2. Linux

trying to map win xp machines in a linux

How do I map some winxp machines on a linux machine using samba? any help will be apreciated Thanks (3 Replies)
Discussion started by: raulb
3 Replies

3. HP-UX

Windows and Linux OS for HP-UX machines

Hi All, I'm not sure if this has been posted before. Anyone knows a site how to do a hardware check (ex. ioscan) on an HP-UX machine that runs in Linux,Solaris and Windows? I'm checking the docs.hp.com and it gives me HP-UX stuff. does HP even supports such highlevel commands we use on HP-UX OS?... (2 Replies)
Discussion started by: grumash
2 Replies

4. UNIX for Advanced & Expert Users

Linux machines hangs for a short while.

Hello! I'm managing a SuSE Linux 10 server which alot of users are using as login server and also as a build server.. There is a wierd problem with it cus' it hangs for about 30seconds ever so often and then resumes like before, this is when using SSH. It's not that heavley loaded but there... (2 Replies)
Discussion started by: Esaia
2 Replies

5. Red Hat

Where is TERM variable set on linux machines ?

We have two machines, prod and uat. The TERM variable in both machines are different prod echo $TERM vt100 UAT echo $TERM xterm I have checked the .profile file and could not find any entry ? There are some scripts on the box which are run by Autosys scheduler they seem to run in... (1 Reply)
Discussion started by: amit1_x
1 Replies

6. UNIX for Dummies Questions & Answers

Copying files to different linux machines using scp

Hi alll i had a file authorized_keys on machine one. now i need to copy this authorized keys file into machine2,machine 3..... i use scp authorized_keys root@192.168.168.11:/tmp/ for copying file . is there ant way to copy the same filr to multiple machines at one go ... (1 Reply)
Discussion started by: kalyankalyan
1 Replies

7. What is on Your Mind?

What's your favorite SSH client to connect to UNIX/Linux machines?

I am curious about the most popular ssh client on Windows environment. Talking about me, I use PuTTY most of the time coupled with WinSCP to transfer files. But, I like Tera Term too. It has great drag-drop feature where you can drag a file/folder and drop on the window and it will transfer the... (14 Replies)
Discussion started by: admin_xor
14 Replies

8. Solaris

Different VMSTAT output on Linux and Solaris machines

Hi, I am porting a piece of code from Solaris to Linux. Code uses VMSTAT command. On Solaris machine VMSTAT output is following: uname -a: SunOS rgsm01 5.9 Generic_118558-03 sun4u sparc SUNW,Sun-Fire-V440 vmstat: kthr memory page disk faults cpu r b w swap free re mf pi po fr de sr m1 m2... (3 Replies)
Discussion started by: Basant Mishra
3 Replies

9. Shell Programming and Scripting

Date Compare tool

Hello Guys, Just joined today with a simple task i guess. I need to write a shell script which takes input from users which is a date and should be able to compare the date differences between the dates keeping in mind the leap year and all. Kindly Guide :) :D (9 Replies)
Discussion started by: barryallen
9 Replies

10. UNIX for Beginners Questions & Answers

Compare 2 files with different keywords : use server health-check tool

I have two files to be compared to get the output of the differences. File1 has a lot more lists than File2. After searching a lot on this thread I'am unable to find the exact code that im willing to get. This will be used as 'pre-check'/post-check utility (health check Tool) to compare... (1 Reply)
Discussion started by: GeekyJimmy
1 Replies
DIFF(1) 						      General Commands Manual							   DIFF(1)

NAME
diff - print differences between two files SYNOPSIS
diff [-c | -e | -C n] [-br]file1 file2 OPTIONS
-C n Produce output that contains n lines of context -b Ignore white space when comparing -c Produce output that contains three lines of context -e Produce an ed-script to convert file1 into file2 -r Apply diff recursively to files and directories of EXAMPLES
diff file1 file2 # Print differences between 2 files diff -C 0 file1 file2 # Same as above diff -C 3 file1 file2 # Output three lines of context with every diff -c file1 file2 # Same diff /etc /dev # Compares recursively the directories /etc and /dev diff passwd /etc # Compares ./passwd to /etc/passwd DESCRIPTION
the same name, when file1 and file2 are both directories" difference encountered" Diff compares two files and generates a list of lines telling how the two files differ. Lines may not be longer than 128 characters. If the two arguments on the command line are both directories, diff recursively steps through all subdirectories comparing files of the same name. If a file name is found only in one directory, a diagnostic message is written to stdout. A file that is of either block special, character special or FIFO special type, cannot be compared to any other file. On the other hand, if there is one directory and one file given on the command line, diff tries to compare the file with the same name as file in the directory directory. SEE ALSO
cdiff(1), cmp(1), comm(1), patch(1). DIFF(1)
All times are GMT -4. The time now is 12:05 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy