Linux Samba Server Configuration

Source: Internet
Author: User

The Linux system already has Samba installed by default, but the Samba service is not installed:

1, first check the installation: Rpm-qa|grep Samba

650) this.width=650; "src=" Http://images.cnitblog.com/i/18055/201406/190944406763234.png "style=" margin:0px; padding:0px;border:0px; "/>

Depending on the installation of the system, choose to download or install the missing RPM package through the optical drive.

My installation situation is:

Use command: mount/dev/cdrom1/mnt/cdrom1

Mount the CDROM1 to the system temp directory via Mount/mnt/cdrom1, using the command under the packets package: RPM-IVH samba.*.rpm package installation.

Switch to the directory where the RPM files are placed

[Email protected]_server root]# RPM-IVH samba-common-3.6.9-151.el6.x86_64

This is a necessary program for Samba and must be installed

[Email protected]_server root]# RPM-IVH samba-3.6.9-151.el6.x86_64

Installing the Samba server program allows my Windows host to access the resources shared by the Samba server.

If you need to enable Linux hosts to access shared resources on Windows hosts, you should also install the Samba client program.

[Email protected]_server root]# RPM-IVH samba-client-3.6.9-151.el6.x86_64

2, after installing the RPM package for Samba

SAMBA-COMMON-3.6.9-151.EL6.X86_64//Main provision Samba server settings file and set file grammar check program Testparm
SAMBA-CLIENT-3.6.9-151.EL6.X86_64//client software that mainly provides the tool instruction set required by the Linux host as a client
SAMBA-SWAT-3.6.9-151.EL6.X86_64//HTTPS protocol-based Samba server Web configuration interface
SAMBA-3.6.9-151.EL6.X86_64//server-side software, mainly provide Samba server daemon, share documents, log rotation, boot default options

After the Samba server is installed, the configuration file directory/etc/samba and some other Samba executable command tools are generated,/etc/samba/smb.conf is the core profile of Samba,/ETC/INIT.D/SMB is the start of samba/ Close the file.

5. View Samba service startup status

# Service SMB Status

650) this.width=650; "src=" Http://images.cnitblog.com/i/18055/201406/190950263959018.png "style=" margin:0px; padding:0px;border:0px; "/>

6. Set Boot from boot

# chkconfig--level SMB on//AT level 3, 5 to automatically run Samba services

650) this.width=650; "src=" Http://images.cnitblog.com/i/18055/201406/190952010204561.png "style=" margin:0px; padding:0px;border:0px; "/>

7. Configuring the SMB Service

[Global]

Workgroup = Workgroup
Server string = Samba Server Version%v

NetBIOS name = ImgPath05

[Imgpath]
Comment = Public stuff
Path =/usr/local/nginx/html/img
Public = yes
writeable = yes
browseable = yes
Guest OK = yes

Shared directory is:/usr/local/nginx/html/img, shared directory name is: Imgpath is the directory name that you see in Windows.

Set shared directory permissions: Chown-r nobody:nobody/usr/local/nginx/html/img/

8. Start or restart the SMB service

Restarting the SMB service

650) this.width=650; "src=" http://pic002.cnblogs.com/images/2012/370046/2012121415310439.jpg "style=" margin:0px; padding:0px;border:0px; "/>

Test smb.conf configuration is correct

650) this.width=650; "src=" http://pic002.cnblogs.com/images/2012/370046/2012121813363063.jpg "style=" margin:0px; padding:0px;border:0px; "/>

9 Windows accesses the shared directory, but does not have write permission to modify the firewall settings in the following ways.

Add the Linux SMB service to the exception of the firewall to execute the Setup command #setup popup with the root user ... Restart in effect, if you do not want to restart, with the command #setenforce 0


This article is from the "Dream to Reality" blog, please be sure to keep this source http://lookingdream.blog.51cto.com/5177800/1880670

Linux Samba Server Configuration

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.