Last active
December 2, 2019 14:55
-
-
Save linuxfemale/be6a40956de1cd7c4d769dfaede0a7db to your computer and use it in GitHub Desktop.
Samba Server(SMB/CIFS) on Ubuntu 18.04 LTS
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt update | |
sudo apt install samba | |
sudo systemctl status nmbd | |
sudo ufw allow 'Samba' | |
sudo cp /etc/samba/smb.conf /etc/samba/smb.conf.backup | |
sudo nano /etc/samba/smb.conf | |
server role = standalone server | |
interfaces = 127.0.0.0/8 eth0 | |
bind interfaces only = yes | |
sudo systemctl restart nmbd | |
sudo mkdir /samba | |
sudo chgrp sambashare /samba | |
sudo useradd -M -d /samba/jack -s /usr/sbin/nologin -G sambashare jack | |
sudo mkdir /samba/jack | |
sudo chown jack:sambashare /samba/jack | |
sudo chmod 2770 /samba/jack | |
sudo smbpasswd -a jack | |
sudo smbpasswd -e jack | |
sudo nano /etc/samba/smb.conf | |
[samba-share] | |
comment = Samba on Ubuntu | |
path = /samba/jack | |
browseable = yes | |
read only = no | |
force create mode = 0660 | |
force directory mode = 2770 | |
valid users = jack @sambashare | |
sudo systemctl restart nmbd | |
#vedio tutorial | |
https://www.youtube.com/watch?v=6hNdXmQH0q0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment