In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-28 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article mainly introduces Centos7 how to build samba server, the article is very detailed, has a certain reference value, interested friends must read it!
The samba server is similar to file sharing on windows, accessing files through the / / ip address
Configure ip addr
Achieve interworking between intranets and mutual ping ip addresses
Install the samba server
Yum install-y samba
Note: this command is for centos, and the installation samba server for Redhat is below
Create a file management user
Useradd vina
Set vina to the login user of Samba
Pdbedit-a-u vina / / password is required for this step
View the list of accounts of existing samba servers
Pdbedit-L
Create a shared directory and set permissions
Mkdir / opt/mytoolschmod 777 / opt/mytools/
Edit the profile of the samba server
Cp-p / etc/samba/smb.conf / etc/samba/smb.conf.bak / / back up vim / etc/samba/smb.conf before editing
Add at the end
# Custom share parameters (multiple custom share parameters can be added) [tools] # [share name] comment=mytools # description of the share, can be any string path=/opt/mytools # share directory path public=no # public to specify whether the share allows guest accounts (anonymous accounts) to access writable=no # writable to specify whether the share path is writable valid user=vina # users who allow access to the share read only=no # whether the share service is read-only
Turn off the firewall and selinux
Service firewalld stop / / centos7 below service iptables stopsetenforce 0 / / temporary shutdown, restart failure
Start the samba server
Service smb startsystemctl enable smb.service / / Boot if necessary
Windows starts verification and creates a file under the shared directory
Touch / opt/mytools/test.txt
Verify on windows to open my computer address bar and enter\\ ip address, dialog box enter user and password
Redhat verification method, you also need to install samba on Redhat
The rpm package of samba is placed in the image. First mount the image to mnt/cdrom.
Mkdir / mnt/cdrommount / dev/cdrom / mnt/cdrom/cd / mnt/cdrom/Packages/
Start installing the samba server under the Packages working directory
Note: uninstall the samba installed by default on the system first, otherwise the installation will fail
Rpm-e samba-common samba-client-libs-- nodeps / /-- nodeps is mandatory
Start installation
Rpm-ivh samba*-- nodeps
Start verification
Smbclient / / IP address / tools-U vina / / enter the password to log in to ls / / View exit / / exit the samba server
Note: firewall and selinux shutdown
The above is all the contents of the article "how to build a samba server in Centos7". Thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.