10 May 2013

412. system-config-samba on debian

I don't use samba anymore, but I do remember that Ubuntu had a very simple tool for setting up samba shares (turns out it's by redhat, not canonical). While it might be better in the long run to craft your own smb.conf, system-config-samba is convenient for quickly setting things up.

Anyway, someone at forums.debian.net asked for it, which got me thinking about making a post:

sudo apt-get install build-essential gfortran checkinstall python-all-dev cdbs debhelper quilt intltool python-central rarian-compat pkg-config gnome-doc-utils samba python-libuser libuser1 python-glade2
mkdir ~/tmp
cd ~/tmp
wget https://launchpad.net/ubuntu/+archive/primary/+files/system-config-samba_1.2.63.orig.tar.gz
tar xvf system-config-samba_1.2.63.orig.tar.gz
wget https://launchpad.net/ubuntu/+archive/primary/+files/system-config-samba_1.2.63-0ubuntu5.diff.gz
gunzip system-config-samba_1.2.63-0ubuntu5.diff.gz
patch -p0 < system-config-samba_1.2.63-0ubuntu5.diff
cd system-config-samba-1.2.63/
dpkg-buildpackage -uc -us
sudo dpkg -i ../system-config-samba_1.2.63-0ubuntu5_all.deb
sudo touch /etc/libuser.conf
gksu system-config-samba

And here we go:
i.e. it at the very least reads my /etc/samba/smb.conf accurately.

To make system-config-samba show up in your gnome menus, add it via Main Menu. Make sure to include gksu in the command to launch it.


  1. Thanks a million! This worked like a champ on #! Waldorf.

  2. Been looking for something like this for awhile thank you!

  3. Hi there, i have an debian8 jessie 3.16 and there isn't any python-central package, so it is not possible to build the package.... :(

    1. You should get the python-central package from debian wheezy (https://packages.debian.org/wheezy/python-central) and then run the command sudo dpkg -i /python-central_0.6.17_all.deb.
      I had the same issue while trying to build system-config-samba and that solved my problem. The Samba System Configuration GUI works like a charm!


  4. hi there python-central isn't available in jessie or debian8 so it is needed to download it from wheezy and then you are able to build the .deb package

    1. Thanks for the feedback. You're right -- python-central and a few other python packages have been removed: https://wiki.debian.org/Python/JessieRoadmap

      The newest files for system-config-samba are at:

      Looking at the debian/control files it doesn't depend on python-central anymore:
      Build-Depends: cdbs (>= 0.4.43), debhelper (>= 5.0.38), quilt, intltool, dh-python, python-all-dev (>= 2.3.5-11), rarian-compat, pkg-config, gnome-doc-utils

      dh-python is still current for jessie:

    2. Long story short: use the newer files listed above and you won't have to get anything from wheezy. Release mixing can be very bad, and so should be avoided.

  5. I was so close but got stuck with an error message
    while executing "dpkg-buildpackage -uc -us"
    Got an error like dh-desktop is against rules or something like that. Can you assist ? Thanks alot in advance!

    1. Which distro/release are you on? The post is quite old, so the way to build may have changed.

    2. You're in luck :)
      I tried building on deb 9, and I got the same error as you did. Turns out that dh_desktop is deprecated. Simply delete/comment out the dh_desktop line in debian/rules

    3. More info about dh_desktop here: http://manpages.ubuntu.com/manpages/xenial/man1/dh_desktop.1.html

  6. Thanks a lot!
    Very helpful :)