I'm running a remote subsonic installation on an Atom-based Kimisufi server (Ubuntu 12.10). It workls perfectly in all aspects, except real-time transcoding, where the CPU just can't cut it.
So I must pre-convert my audio from flac to mp3 to keep performance optimal. Since everything was already on my server, I needed to do this via command line. For reference, I've put the process here:
Convert flac to 320kbp mp3...
- Code: Select all
sudo apt-get install lame
sudo apt-get install flac
...then issue from the folder with the flac files...
- Code: Select all
for f in *.flac; do flac -cd "$f" | lame -b 320 - "${f%.*}".mp3; done
I then like to run my files through mp3gain to level out the volumes (a non-destructive and reversible process - and it works)
- Code: Select all
sudo apt-get install mp3gain
$find . -type f -iname '*.mp3' -print0 | xargs -0 mp3gain -r -k
Converting video to flv is also required and can be achieved thus:
- Code: Select all
sudo apt-get install ffmpeg mencoder lame
Convert AVI to FLV:
ffmpeg -i video.avi video.flv
MP4 to FLV:
ffmpeg -i video.mp4 -ar 22050 -acodec libmp3lame -ab 32K -r 25 -s 320x240 -vcodec flv video.flv
To find out which codecs are supported by your version, type:
- Code: Select all
ffmpeg -formats
mencoder -ovc help