centos7安装配置samba
程序员文章站
2022-05-17 14:01:23
...
1、安装samba
执行yum -y install samba
2、配置samba
mkdir -p samba/share 创建共享目录
chmod 777 /samba/share/ 设置目录权限,否则windows下访问不能修改
修改samba配置文件:
cd /etc/samba/ 定位到配置文件目录
cp smb.conf smb.conf.bak 备份配置文件
vim smb.conf 编辑配置文件
[global]
workgroup = WORKGROUP
security = user
map to guest = Bad User
passdb backend = tdbsam
printing = cups
printcap name = cups
load printers = yes
cups options = raw
#[homes]
# comment = Home Directories
# valid users = %S, %D%w%S
# browseable = No
# read only = No
# inherit acls = Yes
#
#[printers]
# comment = All Printers
# path = /var/tmp
# printable = Yes
# create mask = 0600
# browseable = No
#
#[print$]
# comment = Printer Drivers
# path = /var/lib/samba/drivers
# write list = @printadmin root
# force group = @printadmin
# create mask = 0664
# directory mask = 0775
[share]
comment = share file
path = /samba/share
writable = yes
browseable = yes
guest ok = yes
systemctl disable firewalld 禁用防火墙
vim /etc/selinux/config 修改"SELINUX=enforcing"为"SELINUX=disabled"
systemctl enable smb 自动启动smb服务
reboot 重启
3、访问共享目录
上一篇: CentOS7.2中安装MongoDB
下一篇: PHP 错误之引号中使用变量_PHP教程
推荐阅读
-
CentOS 6安装Nginx centos nginx 启动 centos6.5 nginx centos7 安装 ngin
-
MySql 5.6.14 winx64配置方法(免安装版)
-
centos下nginx+tomcat安装配置 nginx结合tomcat
-
MySQL性能监控软件Nagios的安装及配置教程_MySQL
-
CentOS7安装和配置MySQL
-
PHP pear安装配置教程
-
详细介绍MySQL之-Centos安装多个mysql数据库的配置实例
-
mysql 5.7.13 winx64安装配置方法图文教程
-
mysql5.6安装配置方法图文教程
-
在Mac OS上安装配置mongoDB