In RedHad9, create a Samba server-Linux Enterprise Application-Linux server application information. For more information, see. Author: zieckey (zieckey@yahoo.com.cn)
All Rights Reserved!
The simplest example is the implementation of readable and writable anonymous users.
Step 1: Configure smb. conf
Let's implement a simple function so that all users can read and write a folder shared by a Samba server;
We need to change smb. conf. First, back up the smb. conf file;
Then we write the following section into smb. conf;
[Global]
Workgroup = WuRuan
Netbios name = WuRuan01
Server string = Linux Samba Server TestServer
Security = share
Log file =/var/log/samba/% m. log
Max log size = 50
[Wuruan]
Path =/mnt/samba
Writeable = yes
Browseable = yes
Guest OK = yes
Note:
[Global] This section is a global configuration and is required. There are the following rows;
Workgroup is the working group displayed in Windows. Here I set WuRuan
Netbios name is the name of the computer displayed in Windows;
Server string is the description of the Samba server, which can be defined by yourself. This is not important;
Security is the authentication and login method. Here we use share. There are many authentication methods, one of which is also commonly used as the user authentication method. If share is used, fail to throw a pair of wonton moles? BR>
[Wuruan] the shared directory is displayed in Windows;
Path = You can set where the directory to be shared is stored;
Whether writeable can be written. Here I set it to writable;
Whether browseable can be viewed or not;
Guest OK anonymous users log on as guest;
Note: For nobody authorization, we first use the id command to view the information of the nobody user. We found that the user group is also nobody. We should take this as the standard. In some systems, the nobody user group is not the nobody;
Step 3: Start smbd and nmbd servers;
[Root @ localhost samba] # service smb restart
Step 4: Check the smbd process and check whether the Samba server is running;
[Root @ localhost ~] # Pgrep smbd
13564
13568
Step 5: Access Samba server sharing;
In Linux, you can use the following command for testing;
[Root @ localhost samba] # iptables-F
[Root @ localhost samba] # smbclient-L // 192.168.0.56
Password: Note: Press enter directly.
In Windows, you can use the following method to access;
Enter
\ 192.168.0.56
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.