diff --git a/src/backgroundthread.h b/src/backgroundthread.h
index 81dccbf68..04590b4d7 100644
--- a/src/backgroundthread.h
+++ b/src/backgroundthread.h
@@ -6,13 +6,42 @@
 
 #include <boost/shared_ptr.hpp>
 
+#ifdef Q_OS_LINUX
+#  include <sys/syscall.h>
+#endif
+
 class BackgroundThreadBase : public QThread {
   Q_OBJECT
  public:
-  BackgroundThreadBase(QObject* parent = 0) : QThread(parent) {}
+  BackgroundThreadBase(QObject* parent = 0) : QThread(parent), io_priority_(IOPRIO_CLASS_NONE) {}
   virtual ~BackgroundThreadBase() {}
+
+  // Borrowed from schedutils
+  enum IoPriority {
+    IOPRIO_CLASS_NONE = 0,
+    IOPRIO_CLASS_RT,
+    IOPRIO_CLASS_BE,
+    IOPRIO_CLASS_IDLE,
+  };
+
+  void set_io_priority(IoPriority priority) { io_priority_ = priority; }
+
  signals:
   void Initialised();
+
+ protected:
+  // Borrowed from schedutils
+  static inline int ioprio_set(int which, int who, int ioprio);
+  static inline int gettid();
+
+  enum {
+    IOPRIO_WHO_PROCESS = 1,
+    IOPRIO_WHO_PGRP,
+    IOPRIO_WHO_USER,
+  };
+  static const int IOPRIO_CLASS_SHIFT = 13;
+
+  IoPriority io_priority_;
 };
 
 template <typename T>
@@ -49,6 +78,13 @@ BackgroundThread<T>::~BackgroundThread() {
 
 template <typename T>
 void BackgroundThread<T>::run() {
+#ifdef Q_OS_LINUX
+  if (io_priority_ != IOPRIO_CLASS_NONE) {
+    ioprio_set(IOPRIO_WHO_PROCESS, gettid(),
+               4 | io_priority_ << IOPRIO_CLASS_SHIFT);
+  }
+#endif
+
   worker_.reset(new T);
 
   emit Initialised();
@@ -57,4 +93,20 @@ void BackgroundThread<T>::run() {
   worker_.reset();
 }
 
+int BackgroundThreadBase::ioprio_set(int which, int who, int ioprio) {
+#ifdef Q_OS_LINUX
+  return syscall(SYS_ioprio_set, which, who, ioprio);
+#else
+  return 0;
+#endif
+}
+
+int BackgroundThreadBase::gettid() {
+#ifdef Q_OS_LINUX
+  return syscall(SYS_gettid);
+#else
+  return 0;
+#endif
+}
+
 #endif // BACKGROUNDTHREAD_H
diff --git a/src/library.cpp b/src/library.cpp
index ed749454f..7d88286d2 100644
--- a/src/library.cpp
+++ b/src/library.cpp
@@ -35,7 +35,9 @@ void Library::StartThreads() {
   Q_ASSERT(waiting_for_threads_);
 
   backend_->start();
-  watcher_->start();
+
+  watcher_->set_io_priority(BackgroundThreadBase::IOPRIO_CLASS_IDLE);
+  watcher_->start(QThread::IdlePriority);
 }
 
 void Library::BackendInitialised() {