$ sudo apt update
$ sudo apt upgrade
$ curl -LO https://download.samba.org/pub/samba/samba-latest.tar.gz
$ tar xzvf samba-latest.tar.gz
$ cd samba-x.y.z/ # x.y.z is the Samba version
Reference: https://wiki.samba.org/index.php/Package_Dependencies_Required_to_Build_Samba#Debian_.2F_Ubuntu
$ sudo apt-get install acl attr autoconf bind9utils bison build-essential \
debhelper dnsutils docbook-xml docbook-xsl flex gdb libjansson-dev krb5-user \
libacl1-dev libaio-dev libarchive-dev libattr1-dev libblkid-dev libbsd-dev \
libcap-dev libcups2-dev libgnutls28-dev libgpgme-dev libjson-perl \
libldap2-dev libncurses5-dev libpam0g-dev libparse-yapp-perl \
libpopt-dev libreadline-dev nettle-dev perl perl-modules pkg-config \
python-all-dev python-crypto python3-dbg python-dev python-dnspython \
python3-dnspython python3-gpg python-markdown python3-markdown \
python3-dev xsltproc zlib1g-dev liblmdb-dev lmdb-utils libdbus-1-dev
make install
$ ./configure --sysconfdir=/etc/samba/
$ make -j 2
$ sudo make install
$ sudo cp ./examples/smb.conf.default /etc/samba/smb.conf
$ sudo su -
# echo "PATH=/usr/local/samba/bin:/usr/local/samba/sbin:\$PATH" > /etc/profile.d/samba4.sh
Recommended Posts