ubuntu下共享文件到windows
version: ubuntu:16.04, windows 7 64bit
软件安装
Install Samba
sudo apt-get update
sudo apt-get install samba
Set a password for your user in Samba
sudo smbpasswd -a <user_name>
eg.
a@a-pc:~$ sudo smbpasswd -a myname
New SMB password:
Retype new SMB password:
直接点要共享的文件,使能共享就行,后面的内容可选。
Create a directory to be shared
mkdir /home/<user_name>/<folder_name>
sudo cp /etc/samba/smb.conf ~ //bak the cfg file
sudo nano /etc/samba/smb.conf
Once "smb.conf" has loaded, add this to the very end of the file:
[<folder_name>]
path = /home/<user_name>/<folder_name>
valid users = <user_name>
read only = no
restart smbd
sudo service smbd restart