Convert .m4b to .mp3 using bash.
A couple days ago my dad downloaded some audio books and they were all .m4b .. So he was like: what is this? We have tried to find some converters but they were not really working very well. After trying a couple windows programs I finally found a freeware one for windows — click HERE!
This one worked pretty good. But I was not satisfied yet, I searched the web for a .m4b to .mp3 converter in SSH/Terminal and I found one. Here some steps.
1. First you need to download and install the “Faad” package and the “Lame” package on your server. (Easy to find @ google.com)
2. Make sure you have “python” on your server. (if not — yum install python)
3. Now, download the plugin to your server — wget http://dl.getdropbox.com/u/22008/scripts/m4b2mp3.py
4. Start the script and it will convert your .m4b files to .mp3.
How to use the script?
#python m4b2mp3.py
– Decodes m4b files in current directory and sub directories and consequently encodes the output to mp3.
#python m4b2mp3.py -d /media/audiobook/Bourne\ Supremacy
– Decodes m4b files in supplied directory and sub directories and encodes the output to mp3.
Need help? Just leave a comment and I’ll get back to you!

Comments
Hey Bob,
I’m getting an unsupported audio format error, with two m4b files, anything else I can do to debug more?
G
gareth
I’m not quite sure what you should do, It seems odd to me that two of your .m4b files won’t convert. Maybe you should try to convert these two throughout a online converter such as: http://media-convert.com
Bob