CentOS Installation Configuration Samba server

Source: Internet
Author: User

Suppose we have such a scene
share name path permissionsSharedoc/smb/docs all personnel, including guests, can accessrddocs /smb/tech only allow read and write access for users of specific groups
The group name of the specific group is Rd, currently has Quwenzhe, Zhanghongjie two people
1. Installing Samba yum-y Install samba samba-client Samba-common 2, create a shared directory (assuming a file in the shared/SMB directory)# mkdir-p/smb/docs # mkdir-p/smb/tech 3. Configuring Kernel Parameters# ulimit-n 16384 # vi/etc/security/limits.conf at the end, add the following : *-Nofile 163844. Configuring the Samba server # vi/etc/samba/smb.conf Delete all content (vi delete all contents command: Go to the end of the file with G-->esc-->:1,.d), add the following:
[Global]  Workgroup=bigcloud  NetBIOS name=zzsrv2  Server String=samba server  #security =share  security=user  map to Guest = bad User[sharedocs]  path=/smb/docs  readonly=yes  browseable=yes  Guest ok=yes[ Rddocs]  Path =/smb/tech/public  = no  writable = yes  Write list = @RD  validusers = @RD
5. Create users and assign permissions//Create operating system user# Useradd quwenzhe # Useradd Zhanghongjie # Useradd RD //Modify the user's group# Usermod-a-G RD Quwenzhe # Usermod-a-G RD Zhanghongjie //Create Samba users# smbpasswd-a quwenzhe # smbpasswd-a Zhanghongjie //Modify directory Permissions# chown rd:rd/smb/tech/ # chmod 770/smb/tech //View service status# ll-d/smb/tech
6. Start the Samba server# systemctl restart SMB # Systemctl enable SMB # systemctl status SMB
7. Test Connectivity//testing on Linux# Smbclient-l localhost-u [email protected]
Test on//windowsRun window input \\192.168.24.244
pull the target file directly into the target folder for resource sharing8. Linux access to Samba server smbclient//192.168.24.244/rddocs-u quwenzhe
to this, we completed the installation of the Samba server configuration, Windows access to the Samba server, Linux access to the Samba server operation, I hope that my explanation can help you progress.

CentOS Installation Configuration Samba server

Related Article

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.