- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Coping data from one file system to other file sys...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 05:23 AM
05-28-2001 05:23 AM
Coping data from one file system to other file system?
Sometimes, bdf shows a slightly differnet output, that is, it looks like data has been shrinked.
Thank you for your help.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 05:29 AM
05-28-2001 05:29 AM
Re: Coping data from one file system to other file system?
see:
man diff
federico
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 05:48 AM
05-28-2001 05:48 AM
Re: Coping data from one file system to other file system?
If you want to be absolutely, positively sure then use the cksum command on both the original and copied versions of each file and directory.
You could drive it with a find -exec statement on the original filesystem for each file/directory to
1) cksum origfile > /tmp/f1
2) cksum copyfile > /tmp/f2
3) diff /tmp/f1 /tmp/f2
This will account for every byte in the original filesystem.
Regards, Clay
3)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 06:02 AM
05-28-2001 06:02 AM
Re: Coping data from one file system to other file system?
2) sum copyfile > /tmp/f2
3) sdiff /tmp/f1 /tmp/f2
See man sdiff and sum.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 09:33 AM
05-28-2001 09:33 AM
Re: Coping data from one file system to other file system?
You can use:
dircmp -s $dir1 $dir2
If you receive no output, the directories $dir1 and $dir2 are identical.
HTH
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 03:27 PM
05-28-2001 03:27 PM
Re: Coping data from one file system to other file system?
This generally happens when you have different file system size due to the metadata structures, etc.
You can try du -sk on the directories and if the match close enough , it should be alright.
Sundar.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-28-2001 08:51 PM
05-28-2001 08:51 PM
Re: Coping data from one file system to other file system?
When you create a new directory, it has very few slots to hold names so it must be expanded to hold new names. If a directory is filled with hundreds or thousands of names, then most of the names are removed, the directory will be shown as having a large size (with ls -ld) but only a few files--the directory does not return the empty name slots. Thus, a copy of a directory will be significantly smaller because the unneeded slots are not created. But the copy is just fine even though the occupied amount of space is smaller.
On the other hand, copying files may result in a larger copy. This is due to sparse files. All Unix system can be directed to create a sparse file by writing an inital record, then, using lseek(2), writing record number 1 million. The files contains 2 records with a million imaginary spaces in between so the file is small on the disk.
But copy this file serially (it was never created serially) and all the missing (undefined) records are supplied as a stream of zeros, thus the copy is significantly larger. The most common sparse file is a core dump which can have empty spaces where gaps in the memory allocation exist. Now the file is identical to any program that reads the data whether it is the original or larger copy--they produce the same exact records when read by an application.
Note also that cksum is a good way to verify files and will produce the same result for sparse files and their copies.
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-29-2001 03:25 AM
05-29-2001 03:25 AM
Re: Coping data from one file system to other file system?
If your copying to a newly created file system, I beleive you could use a bdf -i, and compare the inodes. I have done that
when copying file systems, and made sure that they match up, which tells me all the files I intended to copy indeed copied.
scott
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-01-2001 12:31 AM
06-01-2001 12:31 AM
Re: Coping data from one file system to other file system?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
06-01-2001 05:24 AM
06-01-2001 05:24 AM
Re: Coping data from one file system to other file system?
You can copy using find and cpio in this form:
Change Directory (cd) to the directory to be copied
Then "find . -depth -print| cpio -dump /target directory"
Then use wc command to verify the number of characters and words copy with the original.
If you have large files use bdiff, instead of diff.