I recently purchased a set of Sonos speakers to play some media of a linux network share (smb).

To my dismay it cant play certain files (flac 24 bit 96khz) and I wasn’t able to find a good software transcoder in subsonic or xbmc to handle the case.

After some searching around I found this [http://khenriks.github.io/mp3fs/] and tried it out, and, it worked!

Sonos was now able to play my entire media library. The loss in quality has not bothered me since the Play 1 speaker isnt going to benefit much from the difference between mp3-320kb and flac.

I’m not sure if this will help anyone else, but as I couldn’t find this information on google myself, I figured I’d post it [at the least I will find it again this way in the future]

The following is how I set it up on a Ubuntu 12.04 server, given that your music is in /mnt/music, and you have a samba share setup for user mp3.

In a linux terminal run the following commands



% git clone https://github.com/khenriks/mp3fs.git

% cd mp3fs

% sudo aptitude install libfuse-dev libflac++-dev libmp3lame-dev libid3tag0-dev asciidoc

% ./autogen.sh

% ./configure

% make

% sudo make install

% sudo mkdir -p /mnt/mp3Music



Then in /etc/fstab i added



/mnt/music /mnt/mp3Music fuse.mp3fs allow_other,ro,bitrate=320 0 0



And in /etc/samba/smb.conf i added



[mp3Music]↩

comment = mp3Music↩

path = /mnt/mp3Music↩

valid users = mp3↩

browsable = no↩

guest ok = no↩

read only = yes↩

create mask = 0755↩



Once again in a terminal





% sudo mount -a

% sudo service smbd restart



at this point you can use your Sonos player, [i used windows] to map a network share for your music library at \\servername\mp3Music using the mp3 user [you can find how to setup samba shares on linux elsewhere.]