3

I don't know any solution to my problem. I don't even know the cause and have a hard time trying to find it.

I am ripping my Audio CDs using abcde, which is, basically, working well. It is configured to create both FLAC and MP3 output files as I want to have a lossless archive of my CDs in case they get damaged or lost. The MP3 files are for daily use.

Now to the problem: While the FLAC files get the correct play times written in their metadata, all of my MP3 files get wrong durations written in their tags.

Here is an example exiftool reading (while it's basically for image files, it works with pretty much metadata formats, and yes, ID3 tag readers show the same results):

$ exiftool -Duration *
======== 01 - Rock or Bust.flac
Duration                        : 0:03:03
======== 01 - Rock or Bust.mp3
Duration                        : 0:25:02 (approx)
======== 02 - Play Ball.flac
Duration                        : 0:02:47
======== 02 - Play Ball.mp3
Duration                        : 0:02:15 (approx)
======== 03 - Rock the Blues Away.flac
Duration                        : 0:03:24
======== 03 - Rock the Blues Away.mp3
Duration                        : 0:02:45 (approx)
======== 04 - Miss Adventure.flac
Duration                        : 0:02:57
======== 04 - Miss Adventure.mp3
Duration                        : 0:23:18 (approx)
======== 05 - Dogs of War.flac
Duration                        : 0:03:35
======== 05 - Dogs of War.mp3
Duration                        : 0:29:40 (approx)
======== 06 - Got Some Rock & Roll Thunder.flac
Duration                        : 0:03:22
======== 06 - Got Some Rock & Roll Thunder.mp3
Duration                        : 0:02:42 (approx)
======== 07 - Hard Times.flac
Duration                        : 0:02:44
======== 07 - Hard Times.mp3
Duration                        : 0:02:14 (approx)
======== 08 - Baptism by Fire.flac
Duration                        : 0:03:30
======== 08 - Baptism by Fire.mp3
Duration                        : 0:27:25 (approx)
======== 09 - Rock the House.flac
Duration                        : 0:02:42
======== 09 - Rock the House.mp3
Duration                        : 0:02:44 (approx)
======== 10 - Sweet Candy.flac
Duration                        : 0:03:09
======== 10 - Sweet Candy.mp3
Duration                        : 0:25:18 (approx)
======== 11 - Emission Control.flac
Duration                        : 0:03:41
======== 11 - Emission Control.mp3
Duration                        : 0:30:57 (approx)
   22 image files read

I just don't get the clue, why this is happening. Does anyone know a solution to this?

Solution

Thanks to Phreds hint on missing VBR headers, I discovered the reason for this to happen.

As it turns out, lame's --nogap option was activated in .abcde.conf. It's mentioned neither in the lame manpage nor in the .abcde.conf comments (my version, at least), that enabling this option disables the Xing header. In the abcde manpage, however, this behaviour is mentioned regarding the -g flag. Corresponding variable in .abcde.conf is NOGAP

1

I was having a very similar problem (except that I wasn't using FLAC - the original rip was to WAV instead, I believe). I used a program called mp3diags (running on Ubuntu 14.04) to track it down.

Turns out in my case the problem was that the encoder had written the mp3 files without a "Xing header" (whatever that might be). mp3diags claimed that VBR without the Xing header would confuse some players. There is an option in mp3diags to "Repair VBR Data". I used this option on the affected mp3 files and they now display correct times in Clementine (audio player).

  • Could you please detail the usage of the command for the benefit of the OP? – Rui F Ribeiro Nov 17 '15 at 16:58
  • Walkthrough, assuming mp3diags (mine: version 1.0.12.079) is already installed and working: 1) Launch mp3diags; select dir with malformed files. Allow to scan files. 2) Verify that your files have same problem as mine did. In the listing below files (middle "pane" of the window), in the "L" column, flag is labeled "bg" and description is "The MPEG audio stream uses VBR but a Xing header wasn't found..." 3) Click hammer/downarrow icon just to right of path to bring down menu. From menu, select option "Repair VBR data". Answer "Yes" to "Apply transformation..." dialog. 4) Wait, then quit. – Phred Nov 17 '15 at 17:26
  • Thank you, that helped. For clarity: I'm ripping to WAV and converting to FLAC and MP3 from there. I still have to find out, why abcde creates these files. As I just tested encoding a (decoded FLAC-) WAV-file manually (with lame --preset extreme), it obviously generated valid Xing headers. – WolleTD Dec 9 '15 at 13:41
  • Just fond the reason for this to happen. Updated my question. – WolleTD Dec 15 '15 at 21:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.