|
|
Differences in file size (Linux / OS X)
|
|
|
|
Grizzled Veteran
Join Date: Mar 2001
Location: London, UK
Status:
Offline
|
|
I've copied a few files from my Powerbook (10.3.6) across to a linux box I have (running Suse) and while most of the files are the same size when I check them now, some of them are slightly different. Only by a few bytes, but different.
I've tried copying those files again, and it works ok with individual files. I've also tried to copy the files back again to see if they change going the other way, but it would seem now. File sizes remain as they were.
Here's an example (same file)
Pbook: 6,500,470
Same file copied to linux: 6,500,470
Linux (copied along with a few others last week): 6,500,356
Same copied to Pbook: 6,500,356
I hope I'm making myself clear. Does anyone know why this might be the case?
|
|
|
|
|
|
|
|
|
Mac Elite
Join Date: Mar 2000
Location: Allston, MA, USA
Status:
Offline
|
|
It's been a long day, but your numbers look the same to me . . .
Pbook: 6,500,470
Same file copied to linux: 6,500,470
Linux (copied along with a few others last week): 6,500,356
Same copied to Pbook: 6,500,356
-- Jason
|
|
|
|
|
|
|
|
|
Grizzled Veteran
Join Date: Mar 2001
Location: London, UK
Status:
Offline
|
|
Long day for me too - I don't think I'm making myself as clear as I need to
The two files I've listed are one and the same (copied from the Powerbook to the linux box about a week ago). The difference of 114 bytes shown is what's bothering me. The reason I showed the info you quoted was to show that it doesn't always happen, as the same file copied back and forth between the machines now appears not to change anything.
However, somewhere along the line there's something awry. Would love to know what, as I want to backup all these files.
|
|
|
|
|
|
|
|
|
Mac Elite
Join Date: Oct 1999
Location: San Jose, Ca
Status:
Offline
|
|
Are they text files? can you diff them?
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Oct 2001
Location: Yokohama, Japan
Status:
Offline
|
|
Could it be a filesystem thing?
|
|
|
|
|
|
|
|
|
Mac Enthusiast
Join Date: Mar 1999
Location: Portland, Oregon, United States
Status:
Offline
|
|
If the files contain resource forks then those will be stripped when copying to Linux, Windows, UFS, etc. Basically anything other than HFS or HFS+
For some files (w/o resource forks) there would be no size difference, but other files could be off by any amount up to the size of the file. (in the case of a file with no data fork)
|
--Laurence
|
|
|
|
|
|
|
|
Moderator Emeritus
Join Date: Mar 2001
Location: Austin, MN, USA
Status:
Offline
|
|
use md5 on them to see if the hashes are the same
|
|
|
|
|
|
|
|
|
Grizzled Veteran
Join Date: Mar 2001
Location: London, UK
Status:
Offline
|
|
Thanks for the replies, everyone.
Tried an MD5 hash (which was different - should have been, I guess, different file sizes and all).
Tried moving it around between other FS to see if that was anything to do with it, no joy.
Ended up bringing it up in TextEdit and finding that this was near the start of the bigger file:
Edit: See screenshot instead http://81.6.236.94/~ben/difference.gif
(
Last edited by all2ofme; Dec 1, 2004 at 10:57 AM.
)
|
|
|
|
|
|
|
|
|
Moderator Emeritus
Join Date: Mar 2001
Location: Austin, MN, USA
Status:
Offline
|
|
Originally posted by all2ofme:
Thanks for the replies, everyone.
Tried an MD5 hash (which was different - should have been, I guess, different file sizes and all).
Tried moving it around between other FS to see if that was anything to do with it, no joy.
Ended up bringing it up in TextEdit and finding that this was near the start of the bigger file:
EP
Well that's only 2 bytes difference. So there's more different than that.
|
|
|
|
|
|
|
|
|
Grizzled Veteran
Join Date: Mar 2001
Location: London, UK
Status:
Offline
|
|
|
|
|
|
|
|
|
|
|
Admin Emeritus
Join Date: Oct 1999
Location: Zurich, Switzerland
Status:
Offline
|
|
The differences there are in the ID3 tags. The filesystem will never alter the contents of a file: these differences weren't caused by the move to/from Linux. These differences are in the ID3 tags (where things like song title, genre, etc are stored). Presumably the Linux MP3 player decided to add more tags.
tooki
|
|
|
|
|
|
|
|
|
Grizzled Veteran
Join Date: Mar 2001
Location: London, UK
Status:
Offline
|
|
Interesting. I thought that ID3 tags were still stored at the end of files, but right you are. Actually it was iTunes adding data, so my best guess so far is that it was adding the more unusual tag info such as play count and ratings.
Originally posted by tooki:
The differences there are in the ID3 tags. The filesystem will never alter the contents of a file: these differences weren't caused by the move to/from Linux. These differences are in the ID3 tags (where things like song title, genre, etc are stored). Presumably the Linux MP3 player decided to add more tags.
tooki
|
|
|
|
|
|
|
|
|
Addicted to MacNN
Join Date: Dec 1999
Location: Tampa, Florida
Status:
Offline
|
|
Maybe if you make the file a read-only the file size will not change.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Forum Rules
|
|
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is Off
|
|
|
|
|
|
|
|
|
|
|
|