1, install Samba
sudo apt-get Insall Samba
sudo apt-get install SMBFS use the command "sudo apt-get insall samba" installation times wrong: Dpkg:error processing Package Samba (--configure) later Google to may be The Samba configuration file is missing "/etc/samba/smb.conf", so you create a new document and copy the basic content from the Web. There's no error. Not sure whether this error and configuration file missing is directly related, because in the middle tried a lot of methods, such as various delete, reload. 2, set the configuration file in the configuration file "/etc/samba/smb.conf" and finally add the following configuration:
[Share]
Path=/srv/public
Available=yes
Browseable=yes
Public=yes
Writable=yes
Guest Ok=yes
3, use the command "sudo testparm" to test the configuration document for errors.
No error after pressing ENTER, and the following interface shows that the configuration document does not have a problem:
4. Start Samba Service
I started the Samba service using the "sudo systemctl start Samba" command. View status and the service will stop after the restart.
Execute the Enable command error:
[Email protected]:~# sudo systemctl enable Samba
Samba.service is isn't a native service, redirecting to Systemd-sysv-install
Executing/lib/systemd/systemd-sysv-install Enable Samba
Update-rc.d:error:samba Default-start contains no runlevels, aborting.
It is not affected by the temporary use, so temporarily ignore this error.
Access shared files on 5:ubuntu:
To install the smbclient, the installation process is quite smooth here:
sudo aptitude install-y smbclient
Use the command:
Smbclient//192.168.189.128/share link to shared folder: ' 192.168.189.128 ' is my Ubuntu native IP address that can be queried by ifconfig command.
Share is added in the configuration document "/etc/samba/smb.conf" above.
6,windows (Win7 64) Access the shared folder:
Enter the file path: \\192.168.189.128\share, you can manipulate the folder.
Problems encountered during configuration refer to the following linked article:
Issue List
/etc/samba/smb.conf Content
Ubuntu 16.04 (VM) enables Samba service to share files with Windows