Hi all,
It has recently come to my attention that the linux "file" utility
reports some (but not all) of my flac files as having a mime type of
"audio/mpeg". Obviously this is incorrect, but why is it reported as
such? I've cut and paste a few commands below from my shell to
illustrate what I'm seeing:
black:/media/mildred/music/Tool/10,000 Days$ file -i *
01-Vicarious-10,000 Days-Tool.flac: audio/mpeg
02-Jambi-10,000 Days-Tool.flac: audio/mpeg
03-Wings For Marie (Part 1)-10,000 Days-Tool.flac: audio/mpeg
04-10,000 Days (Wings Part 2)-10,000 Days-Tool.flac: audio/mpeg
05-The Pot-10,000 Days-Tool.flac: audio/mpeg
06-Lipan Conjuring-10,000 Days-Tool.flac: audio/mpeg
07-Lost Keys (Blame Hofmann)-10,000 Days-Tool.flac: audio/mpeg
08-Rosetta Stoned-10,000 Days-Tool.flac: audio/mpeg
09-Intension-10,000 Days-Tool.flac: audio/mpeg
10-Right In Two-10,000 Days-Tool.flac: audio/mpeg
11-Viginti Tres-10,000 Days-Tool.flac: audio/mpeg
black:/media/mildred/music/Tool/10,000 Days$ metaflac --export-tags-
to=- 01-Vicarious-10\,000\ Days-Tool.flac
ARTIST=Tool
TRACKNUMBER=01
ALBUM_ARTIST=Tool
ALBUM=10,000 Days
TITLE=Vicarious
black:/media/mildred/music/Tool/10,000 Days$ flac -dc --totally-silent
01-Vicarious-10\,000\ Days-Tool.flac | flac --totally-silent -eo
Vicarious_test.flac - ; file -bi Vicarious_test.flac
audio/x-flac
black:/media/mildred/music/Tool/10,000 Days$ metaflac --show-md5sum 01-
Vicarious-10\,000\ Days-Tool.flac Vicarious_test.flac
01-Vicarious-10,000 Days-Tool.flac: 9269f0bbc4c4a8f48d72f0e380277206
Vicarious_test.flac: 9269f0bbc4c4a8f48d72f0e380277206
This led me to wonder if it was the tags..? Since in theory both flac
files are the same..?
black:/media/mildred/music/Tool/10,000 Days$ metaflac --remove-all-
tags 01-Vicarious-10\,000\ Days-Tool.flac
black:/media/mildred/music/Tool/10,000 Days$ file -ib 01-Vicarious-10\,
000\ Days-Tool.flac
audio/mpeg
No go... This is strange yes? I can write a script to convert them
all, transfer all the tags, etc, but, I'm still curious as to why this
is happening. If anyone has any ideas, I'd love to hear them.
Oh, and for the record books:
Ubuntu 8.04.1 LTS
black:/media/mildred/music/Tool/10,000 Days$ file -v
file-4.21
magic file from /etc/magic:/usr/share/file/magic
black:/media/mildred/music/Tool/10,000 Days$ uname -a
Linux black 2.6.24-18-server #1 SMP Wed May 28 21:25:52 UTC 2008 i686
GNU/Linux
black:/media/mildred/music/Tool/10,000 Days$ metaflac --version
metaflac 1.2.1
black:/media/mildred/music/Tool/10,000 Days$ flac --version
flac 1.2.1
Thanks,
e.
--
ericw at xmtp.net
"If the answer isn't violence, neither is your silence!"
-- Pop Will Eat Itself, "Ich Bin Ein
Auslander"
Eric, I believe that ID3 tags are not legal for FLAC, but they are accommodated. ID3 tags are supposed to be for MP3 only. The Linux "file" utility is probably finding ID3 tags and making a reasonable assumption that this is an MP3. I don't tag my FLAC files, so I do not know what to suggest. Perhaps there are some clues in the FLAC documentation on what are proper tag formats. All I can remember is that MP3/ID3 tags are not really legal. Brian Willoughby Sound Consulting On Dec 4, 2008, at 13:07, ericw at xmtp.net wrote: It has recently come to my attention that the linux "file" utility reports some (but not all) of my flac files as having a mime type of "audio/mpeg". Obviously this is incorrect, but why is it reported as such? This led me to wonder if it was the tags..? Since in theory both flac files are the same..? No go... This is strange yes? I can write a script to convert them all, transfer all the tags, etc, but, I'm still curious as to why this is happening. If anyone has any ideas, I'd love to hear them.
Bingo! And on the first guess too. Thank you! Now I just have to figure out which of my tools dares to add ID3 tags to my flac files, because I'm certainly not doing it intentionally. black:/media/mildred/music/Tool/10,000 Days$ id3info 01-Vicarious-10\, 000\ Days-Tool.flac *** Tag information for 01-Vicarious-10,000 Days-Tool.flac === TIT2 (Title/songname/content description): Vicarious === TPE1 (Lead performer(s)/Soloist(s)): Tool === TALB (Album/Movie/Show title): 10,000 Days === TYER (Year): 2006 === COMM (Comments): ()[]: === TCON (Content type): (92) === TRCK (Track number/Position in set): 1 black:/media/mildred/music/Tool/10,000 Days$ id3info Vicarious_test.flac *** Tag information for Vicarious_test.flac black:/media/mildred/music/Tool/10,000 Days$ cp 01-Vicarious-10\,000\ Days-Tool.flac id3_test.flac black:/media/mildred/music/Tool/10,000 Days$ id3convert -s id3_test.flac Converting id3_test.flac: attempting v1 and v2, stripped v1 and v2 black:/media/mildred/music/Tool/10,000 Days$ id3info id3_test.flac *** Tag information for id3_test.flac black:/media/mildred/music/Tool/10,000 Days$ file -ib id3_test.flac audio/x-flac Thank you very much Brian. e. On Dec 4, 2008, at 2:57 PM, Brian Willoughby wrote:> Eric, > > I believe that ID3 tags are not legal for FLAC, but they are > accommodated. ID3 tags are supposed to be for MP3 only. The Linux > "file" utility is probably finding ID3 tags and making a reasonable > assumption that this is an MP3. > > I don't tag my FLAC files, so I do not know what to suggest. > Perhaps there are some clues in the FLAC documentation on what are > proper tag formats. All I can remember is that MP3/ID3 tags are not > really legal. > > Brian Willoughby > Sound Consulting > > > On Dec 4, 2008, at 13:07, ericw at xmtp.net wrote: > It has recently come to my attention that the linux "file" utility > reports some (but not all) of my flac files as having a mime type of > "audio/mpeg". Obviously this is incorrect, but why is it reported as > such? > > This led me to wonder if it was the tags..? Since in theory both flac > files are the same..? > > No go... This is strange yes? I can write a script to convert them > all, transfer all the tags, etc, but, I'm still curious as to why this > is happening. If anyone has any ideas, I'd love to hear them. >-- ericw at xmtp.net "If the answer isn't violence, neither is your silence!" -- Pop Will Eat Itself, "Ich Bin Ein Auslander"
Also FWIW, I believe Vorbis Comments are appropriate for flac files, and those were the tags reported by metaflac. For some reason, I have some flac files which are tagged both with vorbis comments, AND ID3 tags. The ID3 tags are being stripped even as I type this. :) e. On Dec 4, 2008, at 2:57 PM, Brian Willoughby wrote:> Eric, > > I believe that ID3 tags are not legal for FLAC, but they are > accommodated. ID3 tags are supposed to be for MP3 only. The Linux > "file" utility is probably finding ID3 tags and making a reasonable > assumption that this is an MP3. > > I don't tag my FLAC files, so I do not know what to suggest. > Perhaps there are some clues in the FLAC documentation on what are > proper tag formats. All I can remember is that MP3/ID3 tags are not > really legal. > > Brian Willoughby > Sound Consulting > > > On Dec 4, 2008, at 13:07, ericw at xmtp.net wrote: > It has recently come to my attention that the linux "file" utility > reports some (but not all) of my flac files as having a mime type of > "audio/mpeg". Obviously this is incorrect, but why is it reported as > such? > > This led me to wonder if it was the tags..? Since in theory both flac > files are the same..? > > No go... This is strange yes? I can write a script to convert them > all, transfer all the tags, etc, but, I'm still curious as to why this > is happening. If anyone has any ideas, I'd love to hear them. >-- ericw at xmtp.net "If the answer isn't violence, neither is your silence!" -- Pop Will Eat Itself, "Ich Bin Ein Auslander"