S
snoopy_
Hello,
I am looking for help or suggestion for a way to compare
filesystems between two different systems. I have two development
environments, one is stable the other is not. I like to get a report
of how similar they are, and if the permissions are similar.
I tried rsync, but it doesn't tell you what is wrong with the file
or why it needs to be synced.
The other method is to run a find on one server, capture that as a
source csv file, then write a script to run through all those files and
compare them against the second hosts. I tried to use Perl's
File::stat for this, but was unsuccessful. I resorted to the
following:
find /d00 -print | xargs ls -ld | awk '{print $1","$3","$4","$9}' | tee
/tmp/find.out.csv
It results in a csv file contining perms on one system, then I could
use this to compare:
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/ss.runtime.tar
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/trn.modules.dat
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/trn.runtime.tar
Not how to interpret "-rwx" fields. Thought of perl with expression
matching, or using the File:stat modules. Doesn't seem pratical.
Any other ideas?
Thanks,
Snoopy_
I am looking for help or suggestion for a way to compare
filesystems between two different systems. I have two development
environments, one is stable the other is not. I like to get a report
of how similar they are, and if the permissions are similar.
I tried rsync, but it doesn't tell you what is wrong with the file
or why it needs to be synced.
The other method is to run a find on one server, capture that as a
source csv file, then write a script to run through all those files and
compare them against the second hosts. I tried to use Perl's
File::stat for this, but was unsuccessful. I resorted to the
following:
find /d00 -print | xargs ls -ld | awk '{print $1","$3","$4","$9}' | tee
/tmp/find.out.csv
It results in a csv file contining perms on one system, then I could
use this to compare:
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/ss.runtime.tar
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/trn.modules.dat
-rw-rw----,egatereg,egateg,/d00/app/home/egatereg/schemas/trn.runtime.tar
Not how to interpret "-rwx" fields. Thought of perl with expression
matching, or using the File:stat modules. Doesn't seem pratical.
Any other ideas?
Thanks,
Snoopy_