Sponsored Content
Top Forums Shell Programming and Scripting Comparing file ownership/permission and content of files located on two different servers Post 302808605 by Pranav Bhasker on Friday 17th of May 2013 04:29:43 AM
Old 05-17-2013
Hammer & Screwdriver Comparing file ownership/permission and content of files located on two different servers

Hi All,

can some one suggest me a tool to compare file ownership/permission and contents of files located at two different unix servers?


Thanks,
Pranav
 

10 More Discussions You Might Find Interesting

1. Linux

files ownership/permission problem

all the files and directories in my system are owned by root only.i try to(from root loggin) change the permission on the file but not permitted.can any one help to fix my problem .also while installing any software always error occur like no makefile available (1 Reply)
Discussion started by: jop
1 Replies

2. Shell Programming and Scripting

comparing files content

hi i have a set of files , i need to compare one file content with other file content, i am using cmp -s abc.1 def.2 , but it is not giving theproper o/p even if the content is different.Please help thanks Satya (1 Reply)
Discussion started by: Satyak
1 Replies

3. Shell Programming and Scripting

unix shell script which inserts some records into a file located in remote servers...

All, I need to write an unix shell script which inserts some records into a file located in remote servers. * Get the input from the user and insert according the first row. It should be in ascending order. 123451,XA,ABA 123452,XB,ABB 123453,XC,ABC 123455,XE,ABE 123456,XF,ABF 123458,XG,ABG... (2 Replies)
Discussion started by: techychap
2 Replies

4. UNIX for Advanced & Expert Users

Need help to change the content for remote located file

Hi All, I have one file that sits on 4 diffrent servers, those servers are diffrent region based and they are authentication protected and that file has a diff port numbers, so when run the script it must ask my login details,region of server and port no for that file once it took from me... (1 Reply)
Discussion started by: tmarjuna
1 Replies

5. Shell Programming and Scripting

Need help to change the content for remote located file

Hi All, I have a file that sits on 4 diffrent servers, those servers are diffrent region based and they are authentication protected and that file has a diff port numbers, so when run the script it must ask my login details,region of server and port no for that file once it took from me it... (1 Reply)
Discussion started by: tmarjuna
1 Replies

6. Shell Programming and Scripting

Comparing files names in directory over two servers

Hi folks I need to write a shell script to check whether source and the destination has the same files. The source and destination are over two servers and connecting through ssh. It should even compare the date i.e, the complete file name, date stamp and size should match. Should list out all the... (3 Replies)
Discussion started by: Olivia
3 Replies

7. Shell Programming and Scripting

comparing 2 files and creating third file with uncommon content

I want to compare 2 files and create third file with uncommon content. e.g. file1 ajay suhas tom nisha vijay mahish file2 ajay suhas tom nisha expected output file content vijay mahish Is it possible in single command ? Thanks, Ajay (6 Replies)
Discussion started by: ajaypatil_am
6 Replies

8. Solaris

Need to transfer files between 2 UNIX servers, with same folder permission

I need to transfer directories/files between 2 Unix servers, with same folder permission. I tried scp, but it retains the the permissions, but changes the owner of the directory/file to the user used to copy them to the destination. I don't want that to happen. If possible without any other... (6 Replies)
Discussion started by: Pandee
6 Replies

9. Solaris

How to set multiple ownership permission on a file/directory?

Hi, Any ideas to set multiple ownership permission on a file/directory on Solaris? I need a folder to have multiple ownership on the 2 nodes servers. The 2 nodes servers require to mount a SMBFS with different user ID. Please assist. Thanks. (6 Replies)
Discussion started by: freshmeat
6 Replies

10. UNIX for Beginners Questions & Answers

Comparing two files and list the difference with common first line content of both files

I have two file as given below which shows the ACL permissions of each file. I need to compare the source file with target file and list down the difference as specified below in required output. Can someone help me on this ? Source File ************* # file: /local/test_1 # owner: own #... (4 Replies)
Discussion started by: sarathy_a35
4 Replies
cpacl(3C)																 cpacl(3C)

NAME
cpacl(), fcpacl() - copy the access control list (ACL) and mode bits from one file to another (HFS and JFS File Systems only) SYNOPSIS
Remarks To ensure continued conformance with emerging industry standards, features described in this manual entry are likely to change in a future release. DESCRIPTION
Both (HFS and JFS file systems) and (HFS file systems only) copy the access control list and mode bits (that is, file access permission bits and miscellaneous mode bits; see chmod(2)) from one file to another, and transfer ownership much like chown(2). can only copy HFS ACLs to other HFS files and JFS ACLS to other JFS files; it does not covert HFS ACLs to JFS ACLs or vice versa. and take the following parameters: o Path names (fromfile and tofile) or open file descriptors (fromfd and tofd). o A mode value (frommode, typically the value returned by - see stat(2)) containing file miscellaneous mode bits which are always copied, and file access permission bits which are copied instead of the access control list if either file is remote. o User ID and group ID of the file (fromuid, touid and fromgid, togid) for transferring ownership. (Typically fromuid and fromgid are the and values returned by and touid and togid are the return values from and - see geteuid(2) and getegid(2) in getuid(2)). When both files are local, the routines copy the access control list and call (HFS only; see chownacl(3C)) to transfer ownership from the fromfile to the tofile, if necessary. handles remote copying (via NFS) and copying from HFS to JFS or vice versa after recognizing failures of or (see acl(2) and setacl(2)). When copying the mode from fromfile (fromfd) to tofile (tofd), copies the entire frommode (that is, the file miscellaneous mode bits and the file access permission bits) to tofile (tofd) using Some of the miscellaneous mode bits can be turned off; see chmod(2). can copy an access control list from fromfile (fromfd) to tofile (tofd) without transferring ownership, but ensuring error checking and handling of remote files. This is done by passing fromuid equal to touid and fromgid equal to togid (that is, four zeros). For remote files, fromuid, touid, fromgid, and togid are ignored. RETURN VALUE
If successful, and return zero. If an error occurs, they set to indicate the cause of failure and return a negative value, as follows: -1 Unable to perform or on a local fromfile (fromfd). -2 Unable to perform on tofile (tofd) to set its file miscellaneous mode bits. attempts this regardless of whether a file is local or remote, as long as fromfile (fromfd) is local. -3 Unable to perform or on a local tofile (tofd). As a consequence, the file's optional ACL entries are deleted (HFS only), its file access permission bits are zeroed, and its miscellaneous mode bits might be altered. -4 Unable to perform on tofile (tofd) to set its mode. As a consequence, if fromfile (fromfd) is local, tofile's (tofd's) optional ACL entries are deleted (HFS only), its access permission bits are zeroed, and its file miscellaneous mode bits might be altered, regardless of whether the file is local or remote. EXAMPLES
The following code fragment gets stat information on and copies its file miscellaneous bits and access control list to owned by the caller. If either file is remote, only the on is copied. DEPENDENCIES
and are only supported on HFS and JFS file systems on standard HP-UX operating systems. AUTHOR
and were developed by HP. SEE ALSO
acl(2), chown(2), getacl(2), getegid(2), geteuid(2), getuid(2), setacl(2), stat(2), acltostr(3C), chownacl(3C), strtoacl(3C), acl(5), aclv(5), thread_safety(5). cpacl(3C)
All times are GMT -4. The time now is 11:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy