Share your local files under Linux and Mount shared files from other computers __linux

Source: Internet
Author: User

Understanding:Samba is a freeware software that implements the SMB protocol on Linux and UNIX systems, consisting of servers and client programs. SMB (Server Messages block, information service blocks) is a communication protocol that shares files and printers on a local area network, providing shared services for resources such as files and printers between different computers in a local area network. The SMB protocol is a client/server protocol through which clients can access shared file systems, printers, and other resources on the server. By setting up "NetBIOS over TCP/IP", samba can not only share resources with local network hosts, but also share resources with computers around the world. first, use Yum to install the Samba software. 1, Input command: Yum install Samba to perform the installation
2, after the installation completes, the input vi/etc/samba/smb.conf modifies smb.conf file. Enter in last line mode: Set number shows the travel numbers, enters insert mode and modifies user to share in 101.

Add at the end of smb.conf text:
[Bingji_share] (shared directory name, can be arbitrarily taken)
Comment=share
Pate=/home (Shared path)
Volid Users=nobody (valid owner, nobody says no owner)
Writable=yes
Public=yes Write List=+staff
Save and exit
3. Start Samba services: Service SMB start 4, enter my computer, input \ \ Share the computer's IP address, enter, you can view the shared out of the file. (Note: ①, you must first turn off the firewall under Linux.) Service iptables stop ②, sometimes need to restart the network card: Server network Restart to see the shared files. )

This allows you to successfully view the files that are shared on the virtual machine. (Note: If you want to do this to the file, modify the permissions by using the chmod command.) )

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.