Operating System - HP-UX
1834555 Members
3274 Online
110069 Solutions
New Discussion

Re: Directory comparison command does not go across the file system boundaries

 
SOLVED
Go to solution
Amy Ng_2
Occasional Contributor

Directory comparison command does not go across the file system boundaries

We have frequent needs to do storage migrations. We have a script to
allow us to copy file systems on the old storage to new storage. To ensure that we have copied everything correctly, we have been using the command "dircmp" to compare the original and new directories.

e.g.

dircmp -s /dba08 /new/dba08

However, we do not want the directory comparison to go across the file system boundaries.
e.g.
/oracle/dba01

The /oracle is a file system and /oracle/dba01 is another file system. We want to check the /oracle file system only ... not /oracle and /oracle/dba01.

Does anyone know any utilities on HPUX that can do this?

Thanks,

Amy Ng

3 REPLIES 3
A. Clay Stephenson
Acclaimed Contributor
Solution

Re: Directory comparison command does not go across the file system boundaries

Dircmp is nothing but a shell script. Make a copy and modify to your heart's content.
If it ain't broke, I can fix that.
TwoProc
Honored Contributor

Re: Directory comparison command does not go across the file system boundaries

well "diff" on the two directories would do it - but the output isn't nearly as good as dircmp.

But, since you're copying oracle data files - the database MUST be down right?

Well, since Oracle is down just unmount /oracle/dba01 and temporarily at say, /compare/dba01.
Run dircmp /oracle /compare/dba01
and then unmount it from /compare and put it back on /oracle.

[ copy files from /oracle to /oracle/db01 ]
umount /oracle/db01
mount /dev/vgxxx/lvolxxx /compare/dba01
dircmp /oracle /compare/dba01 > report.out
umount /compare/dba01
mount /dev/vgxxx/lvolxxx /oracle/dba01

We are the people our parents warned us about --Jimmy Buffett
Amy Ng
New Member

Re: Directory comparison command does not go across the file system boundaries

It's good to know that dircmp is only a script. I can certainly look into changing the script ... I was hoping someone already did this before. Is there any freeware on the web that can do this?