My ongoing experiences with Ubuntu, and later Mythbuntu, as a media center with MythTV. I'm also using the system for a virtual machine server, a mediawiki server and a general all around home infrastructure base.

Saturday, January 27, 2007

Ubuntu 6.10, Rythmbox and Sound Juicer: Enabling MP3 Ripping

First, a hint about setting up sound. This HowTo is very helpful. The only thing I had to do was double-click on the speaker icon in the upper right and then move the PCM volume up. Until I did that I got no sound output. I found putting the PCM level at about 1/3rd of max worked out about right.

This thread and this help page were useful to figuring this out. Ultimately brian g's post at the end of this thread gave me the right GStreamer encoding stream. What's below is what worked for me taken from all of those postings.
  1. If you haven't already done so, make sure you have gstreamer0.10-plugins-ugly installed:
    sudo apt-get install gstreamer0.10-plugins-ugly

  2. Then do the following install (Thanks to Gordon for confirming it is needed).
    sudo apt-get install gstreamer0.10-plugins-ugly-multiverse

  3. Open Sound Juicer.
  4. Select Edit/Preferences
  5. Click on Edit Profiles
  6. Click on New
  7. Name it "MP3"
  8. Select the new profile, and click on Edit
  9. Set the GStreamer Pipeline to:
    audio/x-raw-int,rate=44100,channels=2 ! lame name=enc vbr=4 vbr-quality=2 ! xingmux ! id3v2mux
  10. Set the File Extension to mp3
  11. Make sure Active? is selected.
  12. Click OK
  13. Close the Audio Profiles window and the Sound Juicer preferences
  14. At this point I couldn't select my newly created profile in Sound Juicer, so I had to...
  15. Close and restart Sound Juicer.
  16. Now select Edit/Preferences again.
  17. For Output Format select your newly created MP3 format.
  18. Close the Preferences pane.
Now if you Extract in Sound Juicer you should end up with MP3 files.

Note: It looks like one should be able to use Rythmbox to rip MP3 directly using its "Copy to library function" but it doesn't work for me. I select Edit/Preferences and then selecting your new MP3 format as the Preferred Format. But then when I try to Copy to library I get the following error:
Error transferring track
no element "xingmux"
Note 2: Apparently these changes will only make MP3 ripping available to the current user. This post has directions for making MP3 ripping available to all users on the system.

Ubuntu 6.10: Getting ITunes to see Rythmbox

My next step was to share music from Rythmbox to ITunes running on the Winsows XP and MacOS laptops. This turned out to be non-obvious.

First, in Rythmbox, click on Edit/Preferences then select the Sharing tab and select Share my music and give it a name of your choosing. I also required a password.

At this point I still couldn't see Rythmbox from ITunes or vice versa.

The next thing to do was to turn on the Avahi daemon. Do this by selecting System/Administration/Networking and then select the General tab and make sure the checkbox for Automatic service discovery is checked.

And then I had to do one more then, which was to enable something called D-Bus. I did this by opening a Terminal and editing /etc/avahi/avahi-daemon.conf

sudo vi /etc/avahi/avahi-daemon.conf

And uncomment the following line:
#enable-dbus=yes
so that it looks like:
enable-dbus=yes
Then restart avahi:

sudo /etc/init.d/avahi-daemon restart

This lets me see Rythmbox from ITunes. I still can't see ITunes from Rythmbox. This post may give the reason why.

Getting Rythmbox to Recognize MP3s

After I copied over my Itunes library to my Ubuntu 6.10 system I was somewhat surprised to find it didn't recognize MP3s. Poking around the net a little turned up this was do to intelletual property issues and there were a number of different fixes posted (for example).

I tried various ones and here's what I think ended up working for me. I say I think because I tried a number and it started working after what I did below. It's possible some of the prior steps I took were important.

First you have to allow your system to download software from universe and mutliverse. Select System/Administration/Software Sources. Make sure "Community maintained Open Source software (universe)" and "Software restricted by copyright or legal issues (multiverse)" are checked. Then click Close.

Then I ran the following command:

sudo apt-get install gstreamer0.10-plugins-ugly

And restarted Rythmbox. After that it recognized MP3 just fine.

Note that it still doesn't seem to be able to rip CDs into MP3s. That's still on the todo list...

For the record, here are some of the other things I found on the net that I tried (after adding universe and multiverse to my software sources), which either didn't work or didn't seem to have any effect:

apt-get install gstreamer0.10-ffmpeg gstreamer0.10-gl gstreamer0.10-plugins-base gstreamer0.10-plugins-good gstreamer0.10-plugins-bad gstreamer0.10-plugins-bad-multiverse gstreamer0.10-plugins-ugly gstreamer0.10-plugins-ugly-multiverse libxine-extracodecs w32codecs

apt-get install gstreamer0.8-mad

apt-get install gstreamer0.8-plugins

apt-get install gstreamer0.10-plugins