LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-07-2009, 12:38 PM   #1
wyzgreg
LQ Newbie
 
Registered: Aug 2007
Posts: 27

Rep: Reputation: 15
Song and artist information incorrect or garbled using cdrecord


Here are the steps I take to burn an audio cd under debian 4.0:

1. Run the following script in the directory containing mp3 or flac audio

For mp3:

# mp32wav 2.6.2001 / uk
#
for i in *.mp3
do
wavfile=`echo "$i" | sed s/\\.mp3/.wav/`
lame --decode "$i" "$wavfile"
done

For flac:

#!/bin/bash
for i in *.flac
do
flac -d "$i"
done

Then, I run cdrecord:

cdrecord -v dev=/dev/hdc -dao -pad -audio *.wav

This worked fine for months, until this morning when I burned a cd and the track information (TOC) given was indeed not the same as what the tag information was on the source mp3. The same for flac: It gave "お菓子CD No.3-06 ドカベン", for what should have been "Jerusalem" and "こおろぎ'7" for what should have been "ELP".

Any help/suggestions will be appreciated.

Last edited by wyzgreg; 02-07-2009 at 05:34 PM.
 
Old 02-07-2009, 11:56 PM   #2
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
Very odd. I don't see anything in there for handling tag information, or for adding cd-text to the final disk. All these commands do is convert the tracks to .wav files and then burn them to cd-audio. There shouldn't be any track information at all, according to this.

There must be something else going on here. Is this everything? The stuff you posted isn't even a proper script. Are these two separate scripts? Is there anything else you do outside of running these commands?

OTOH, Google shows that "Okashi CD No. 3-06 Dokaben" is the name of an anime CD single.

Last edited by David the H.; 02-07-2009 at 11:59 PM. Reason: updated cd information
 
Old 02-08-2009, 08:50 AM   #3
wyzgreg
LQ Newbie
 
Registered: Aug 2007
Posts: 27

Original Poster
Rep: Reputation: 15
Thanks for the reply.

These are two separate scripts. If I want to burn flac files I run the one for flac, if mp3 I run the one for mp3. Then I run the cdrecord command.

Up until yesterday the burned cd would have all the correct tag info, without doing anything outside of the process described above.

Around the time I burned the cd I found the following in syslog:
****
Feb 7 11:41:34 CPE0007e93d1b62-CM00152fc76afa NetworkManager: <debug info>^I[1234024894.396580] nm_hal_device_removed (): Device removed (hal udi is '/org/freedesktop/Hal/devices/volume_part_1_size_427292672').
Feb 7 11:43:33 CPE0007e93d1b62-CM00152fc76afa kernel: cdrom: This disc doesn't have any tracks I recognize!
Feb 7 11:43:33 CPE0007e93d1b62-CM00152fc76afa NetworkManager: <debug info>^I[1234025013.902019] nm_hal_device_added (): New device added (hal udi is '/org/freedesktop/Hal/devices/volume_empty_cd_r').
****

I googled kernel: cdrom: This disc doesn't have any tracks I recognize! and found posts of it, but no explanations.

Once again, thanks for the reply.
 
Old 02-08-2009, 10:00 AM   #4
wyzgreg
LQ Newbie
 
Registered: Aug 2007
Posts: 27

Original Poster
Rep: Reputation: 15
After some more experimenting I have discovered that this problem only happens with certain files. I guess it has something to do with the tags on the flac/mp3 files.
 
Old 02-08-2009, 10:37 AM   #5
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
Well, as I said, I can't understand how ANY of your disks can have track info in them. The only way I know of to store such things on a CD is with cd-text, and your cdrecord command doesn't have that enabled. And since the input is .wav, and .wav doesn't have any metadata capability, there's nowhere for it to get the track info in the first place. And your two scripts don't touch the metadata either, as the the only thing they both do is decode the tracks to .wav. Finally, the majority of CD players ignore cd-text anyway.

I'm going to make an educated guess here that what you're calling the "TOC" info is in fact coming from a CDDB lookup in your music player. Most software players these days do automatic lookups in the online CD DataBase* to get track info, which contains listings for the vast majority of commercial disks. But it's hit-or-miss as to whether a burned copy will have a correct disk ID. Straight copies can often match correctly, but not always, and may instead give you either nothing or a false match in return. And mixed disks will certainly fail.

Frankly I'm surprised that copies match as often as they do.

=====
*Actually, most of them use FreeDB or MusicBrainz these days, since the original CDDB was bought out and the new owners implemented some unfavorable terms of service.)

Last edited by David the H.; 02-08-2009 at 10:41 AM. Reason: added a link and made a correction
 
Old 02-08-2009, 11:00 AM   #6
wyzgreg
LQ Newbie
 
Registered: Aug 2007
Posts: 27

Original Poster
Rep: Reputation: 15
I suspect it is the CDDB stuff you mentioned. When I loaded the cd into a cd player that uses cddb the "garbled" name came up, first on the list. Now, I don't know how this is happening. I'm not doing anything when I burn to invoke a cddb lookup, at least explicitly.

I burned another cd using the steps mentioned above and it came out with the artist and track information that matched the songs.

So I retried the song that was causing problems and the information was, again, incorrect. Very odd, indeed.

Last edited by wyzgreg; 02-08-2009 at 11:02 AM.
 
Old 02-08-2009, 11:21 AM   #7
David the H.
Bash Guru
 
Registered: Jun 2004
Location: Osaka, Japan
Distribution: Arch + Xfce
Posts: 6,852

Rep: Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037Reputation: 2037
The burn has nothing to do with the CDDB lookup, other than in creating the disk ID. It's your player that takes the ID number and sends it to the database for matching.

Now I haven't the foggiest idea how the CD's ID number is determined. If you make an exact copy from clean files it will sometimes (and surprisingly, in my opinion) come out the same as the CD it was originally ripped from, but it's not at all guaranteed.

If your CD player has local CDDB ability (some programs have can use a local database, usually found at ~/.cddb), you could add the correct data to it, and configure the player to read from there instead.
 
Old 02-08-2009, 05:48 PM   #8
wyzgreg
LQ Newbie
 
Registered: Aug 2007
Posts: 27

Original Poster
Rep: Reputation: 15
Smile

I get it now. My mistake was in thinking that the information was somehow coded into the disk. Thanks for your help and replies.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Streamtuner: Show song Artist/Title MargNat Linux - Software 4 12-09-2006 10:32 AM
XMMS producing garbled song titles on mp3's (and others?) overhangingtrees Linux - Desktop 1 11-17-2006 04:49 AM
Amarok sorting song list - Artist THEN Title? ironfistchamp Linux - Software 0 06-02-2006 05:56 PM
how do I modify .mp3 information (artist/title)? servnov Linux - General 5 11-12-2004 03:21 AM
cdrecord -scanbus shows incorrect device (external USB CD-RW) Avatar Linux - Hardware 2 04-14-2004 09:53 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 09:02 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration