Announcements

Help Wizard

Step 1

NEXT STEP

FAQs

Please see below the most popular frequently asked questions.

Loading article...

Loading faqs...

VIEW ALL

Ongoing Issues

Please see below the current ongoing issues which are under investigation.

Loading issue...

Loading ongoing issues...

VIEW ALL

Spotify on lightweight Linux

Spotify on lightweight Linux

I wanted to convert an old laptop (~2005) to a Spotify box.

I ran into problems because Spotify won't run on Windows XP anymore.

I had trouble finding info about on which Linux lightweight distros can I expect Spotify to run, and also how much horsepower it takes.

So, I post my experience here now that I got the system running:

 

OS:

Ubuntu MATE 18.04

(had to install from DVD, no support for USB boot)

 

Machine:

Acer laptop, Intel Centrino Pentium M 1.6 GHz, 1280 MB of RAM, 25 GB disk

( apparently could do  with less disk space, but otherwise this is apparently pretty close to bare minimum for this OS )

 

Experience:

In the start of Linux install got a scary error message:

This kernel requires the following features not present on the CPU: pae

The issue was resolved with the "forcepae" trick:

https://help.ubuntu.com/community/PAE

 

Linux installation was really sluggish, but finally worked.

After the OS install the Spotify itself was easy to install through Ubuntu software.

Spotify runs mostly ok but the music loops/skips a fraction of second every know and then. I need to investigate how to recude the system load to get rid of the glitches.

Reply
3 Replies

Nice blog post.

I find Spotify can be quite RAM hungry (which may be the cause of your skips, though I'm just speculating), and I think it's fair to say MATE isn't the lightest-weight desktop environment. You could try installing something lighter-weight like LXDE which might help your situation. This is the first thing I would try if you're seeing heavy RAM usage. An even lighter-weight option is to forget the desktop environment and go for a plain window manager like i3.

Depending on your linux experience and how much time you want to spend setting up the box, you could also try some lighter-weight distros. Debian is one option, which should be familiar to you as Ubuntu is based on it. The ultimate light-weight distro would be Arch, though you'll likely spend a full day installing the operating system if you've never done it before. Manjaro (based on arch) will ease the installation process though it'll package some gumpf in with it.

If you go for a completely minimal arch installation, you might find you can run it directly in X. No need for even a window manager. If running spotify is your only goal, this is the ultimate solution.  (There is a Spotify package for Arch in the AUR.)

For reference, I run Spotify on my Arch installation with i3 as a window manager. It works with no problems for me. At the moment it's using about 300MB of RAM.

Thanks for the tips jezza5 🙂

 

I checked the system load with top.

Basically it was just two threads of spotify and one of pulseaudio loading the CPU,

everything else was peanuts, even xorg was just 1 % or less.

It looked like the RAM was not the limiting factor, although most of it was in use.

 

I did some digging on pulseaudio. Sure enough, this tip fixed the skipping problem altogether:

https://www.codeweavers.com/support/wiki/linux/faq/soundtrouble

 Toggling the Timer-based scheduling
this setting can be useful if the sound is skipping or glitching

Before making this adjustment, it may be best to read about it here.

With extreme caution, edit the configuration file at:

/etc/pulse/default.pa

look for the line that includes:

load-module module-udev-detect

And add tsched=0 to the end so that the above example would look like this:
if there are other parameters in this line, do not delete them, simply add tsched=0 to the end of the line.

load-module module-udev-detect tsched=0

After making the adjustment, restart PulseAudio from terminal with:

pulseaudio -k

 

Suggested posts