Configuring the Samba server on the Bananapi
Configuring the samba server and having it use the attached 2,5″ HDD was actually pretty easy.
Step 1: Mounting the harddisk
From http://mein.homelinux.com/wiki/linux/mounten I learnt how to add the attached harddisk to the fstab
. blkid
gave me the UUID of the disk (which I had previously partioned and formated with gparted
), so I just had to a) create a directory /media/storage
, b) set the access rights with chmod 777 /media/storage
and add the following line to the fstab:
UUID=b06c9eb6-7cc3-429b-9176-44896e712319 /media/storage ext4 auto,defaults 0 2
Step 2: Installing samba
sudo apt-get install samba
installed samba, but not smbpasswd
. A quick sudo apt-get install samba-common-bin
fixed this.
After I had created a „bananapi“ user on the machine I added this account to the list of samba users with the command smbpasswd -a bananapi
. I then took the sample configuration for the /etc/samba/smb.conf
from https://www.thomas-krenn.com/de/wiki/Einfache_Samba_Freigabe_unter_Debian and rebooted the machine.
From my Windows machine I can connect now to \\bananapiip\public
and use it as a samba server. When copying a 1 GB iso image to the \public share I got an avaerage of 35 MB per second.
Remarks 2020-06-06:
[global] workgroup = smb security = user map to guest = Bad Password [homes] comment = Home Directories browsable = no read only = no create mode = 0750 [public] # chmod -R 777 /home/uwe makes it publicly accessible path = /home/uwe/ public = yes writable = yes comment = smb share printable = no guest ok = yes