Sponsored Content
Full Discussion: file comparision by line
Top Forums Shell Programming and Scripting file comparision by line Post 302260210 by aaysa123 on Thursday 20th of November 2008 12:59:15 AM
Old 11-20-2008
file comparision by line

i have two files and i want to compare these two
it shoud print those lines which are not in 2nd file
a.txt
1236,AB,0
2345,CD,1
5679,EF,1
9123,AA,1
9223,AA,0

b.txt
1234,AB,0
2345,CD,1
5678,EF,1
9123,AA,0
o/p
1236,AB,0
5679,EF,1
9123,AA,1
9223,AA,0
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Unix File Comparision

I have a file named file1 which contains numbers in sequence like... 1 2 3 7 8 Then i have file File 2 that contains 4 5 ........so i need to compare both files so that i can find out the missing entry in the sequence is 6.......These files are flat files which contain and so i need to... (5 Replies)
Discussion started by: coolguy01
5 Replies

2. Shell Programming and Scripting

file size comparision local file and remote file

Hi, I have written a script which would FTP a dump file to the FTP server and log the whole activity into a file. to confirm the success of the file copy i grep for "226 file receive OK" and then send out an email saying success. Now i want to make sure the bytes of the local file and... (4 Replies)
Discussion started by: dba.admin2008
4 Replies

3. Shell Programming and Scripting

File comparision

HI, I would like to know how to compare two files and replace non-matching lines with "_" . I can get non-mathing lines with grep -v -f file1 file2 i just want to knw how to display 'file2' with non-matching lines from 'file1' replaced by "_" for exmaple file1: a b c d ... (2 Replies)
Discussion started by: maddy81
2 Replies

4. Shell Programming and Scripting

Date Comparision in the File

Hi All, I have thefollowing files in the directory inbox/sat ras.sat.trn.20090103.001902.00004358 ras.sat.trn.20090612.001903.00005339 ras.sat.trn.20090723.001902.00004358 The above file contains the date of the file creation. We just need to write a ksh shell script to check the... (5 Replies)
Discussion started by: satheesh_color
5 Replies

5. Shell Programming and Scripting

File comparision

Hi All I have to files cat a.txt AAA BBB CCC DDD and cat b.txt AAA CCC EEE i want to compare these two files and o/p should have content of file a.txt which is not in file b.txt c.txt BBB DDD Please help me (1 Reply)
Discussion started by: aaysa123
1 Replies

6. Shell Programming and Scripting

File comparision

Hi All I have to files cat a.txt AAA BBB CCC DDD and cat b.txt AAA CCC EEE i want to compare these two files and o/p should have content of file a.txt which is not in file b.txt c.txt BBB DDD Please help me (3 Replies)
Discussion started by: aaysa123
3 Replies

7. Shell Programming and Scripting

Line by Line Comparision of 2 files and print only the difference

Hi, I am trying to find an alternative way to do tkdiff. In tkdiff the gui compares each line and highlights only the differences. for eg: John works at McDonalds s(test) He was playing guitar tywejk John works in McDonalds 9908 He was playing guitar I am... (1 Reply)
Discussion started by: naveen@
1 Replies

8. Shell Programming and Scripting

File Comparision

Hi All, I want to write a script which will compare two files and tell me if the files are different. Actually my files will be same but order of lines will be different,so diff is not working. I have written a script to do this:- while read line; do cnt=`grep -i $line... (6 Replies)
Discussion started by: prasson_ibm
6 Replies

9. Shell Programming and Scripting

perl: comparision of field line by line in two files

Hi everybody, First I apologize if my question seems demasiad you silly, but it really took 4 days struggling with this, I looked at books, forums ... And Also ask help to a friend that is software developer and he told me that it is a bad idea do it by perl... but this is my problem. I moved to... (8 Replies)
Discussion started by: Thelost
8 Replies

10. Shell Programming and Scripting

File comparision line by line

Hi, I want to compare 2 files and get output file into seperate folder. Both file names will change daily with timestamp (ex: file1_06_17_2013_0514), so i can't mention the file names in the script to compare, but i need to compare these 2 files daily and generate output to another... (28 Replies)
Discussion started by: rkrish123
28 Replies
P10CFGD(1)						      General Commands Manual							P10CFGD(1)

NAME
p10cfgd - remote configuration daemom for Gracilis PackeTen SYNOPSIS
p10cfgd [IP_PORT] COPYRIGHT
Copyright (c) 1993 by Colorado Digital Eclectics (CODE) All rights reserved. DESCRIPTION
Rmtcfgd is a server program used to send configuration files to a Gracilis PackeTen. It can be run in background or it can be run by inetd. If p10cfgd is to be run by inetd, add the following line to /etc/services rmtcfg 1236/tcp # Remote Configuration of PackeTen and add the following to /etc/inetd.conf # Remote configuration service for PackeTen rmtcfg stream tcp nowait root /usr/bin/p10cfgd p10cfgd P10cfgd normally does not require the IP_PORT parameter. It listens for connections on IP Port 1236 as a default. The program will send on a line by line basis the file requested by the client that connects on the IP Port. The only expected input from the client is the file name. When the file has been sent, the connection is closed. The requested file must be in the directory /etc/p10cfgd. Rmtcfgd maintains a log of its activity in the file /var/log/p10cfgd.log. Program startup and all connections are logged in the file with GMT time stamps. The file is opened in append mode. The protocol used by the PackeTen is very simple. The PackeTen opens a tcp connection to port 1236 on a host system. Once the connection is made, the PackeTen sends the name of the file it wants to the host. The host then opens the file and sends it line by line to the Pack- eTen until all lines have been sent. The files to be transfered must be plain text files and each line must have at least one character in addition to the newline at the end. P10cfgd replaces all blank lines with lines that contain two spaces. If you wish to send a blank line, to stop loading of part of a LocalInfo file for example, place an underscore '_' at the begining of the line. The entire contents of the line will be deleted and a blank line will be sent to the client. At the end of the file, the server sends a time command ( time MMD- DYYHHMM ) with the UTC time on the server. This will either set the time on the PackeTen or add a time stamp to the LocalInfo file. The server then closes the connection. The remote configuration command used on the PackeTen is rmtcfg <server_host> <filename> [options] The valid options are -t <timeout in seconds> default is 60 sec -p <IP port #> default is 1236 -i the file is for LocalInfo -h <secondary server> if the primary does not answer The rmtcfg commands would be placed in to the EEPROM on the PackeTen so that they would be executed during a reboot. The information stored in the EEPROM should include enough information to set the PackeTen up to allow communications with the primary and the secondary server. This would include commands to set MYCALL and the IP_ADDRESS, to attach an interface to the channel with the server, routing information and so forth. A sample EEPROM configuration for a PackeTen, empire.wd0fhg.ampr.org [44.32.0.32], that gets its configuration from a remote system winfree.n3eua.ampr.org [44.32.0.2], over a 9600 baud ax25 path would be: # first the general setup of the PackeTen ee hostname gw.wd0fhg ee sitename empire ee ipaddr 44.32.0.32 ee mycall WD0FHG # Then we attach a 9600 ax25 interface as ax1 ee attach sync302 1 hdx ax25 ax1 8192 256 9600 ext ext nrzi # and set the default route to send every thing out ax1 ee route add default ax1 44.32.0.1 ee password sure-thing # # Now we will ask for the remainder of the setup # from the server winfree.n3eua.ampr.org [44.32.0.2] # Note that we have a secondary server available at # [44.20.0.195] that would be used if winfree is down. # first the Local Information file ee com 0 rmtcfg 44.32.0.2 empire.info -i -h 44.20.0.195 # and then the remaining configuration command file ee com 1 rmtcfg 44.32.0.2 empire.cfg -h 44.20.0.195 # ee save # end-of-eeprom setup Rmtcfgd started life as the simple server program in PERL by Larry Wall and R.L. Schwartz published by ORA,Inc. ENVIRONMENT
No environment variables are used. FILES
/etc/p10cfgd/* - files that can be accessed remotely /var/log/p10cfgd.log - p10cfgd log file AUTHOR
John Conner, WD0FHG, conner@empire.com hacked on by Bdale Garbee, N3EUA, bdale@gag.com. SEE ALSO
Gracilis, Inc. PackeTen Manual and NOS User's Manual DIAGNOSTICS
Complains if it can't open a file to remote client and to log file. 7th Edition July 29, 1993 P10CFGD(1)
All times are GMT -4. The time now is 03:30 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy