ubuntu之搭建samba文件服务器

1. 在服务器端安装samba程序

sudo apt-get install samba

sudo apt-get install smbclient

2.配置samba服务

sudo gedit /etc/samba/smb.conf

在文件末尾追加入以下配置

[develop_share]

valid users = ancy

path = /home/ancy

public = yes

writable = yes

create mask = 0644

force create mode = 0644

directory mask = 0755

force directory mode = 0755

available = yes

3. 添加samba用户

sudo smbpasswd -a ancy

4.重启samba服务器

sudo /etc/init.d/samba restart

或者

sudo /etc/init.d/smbd restart

5.windows上访问samba服务器

在下面窗口输入: \\ + ip

注意:

1.增加samba用户提示Failed to add entry for user

[root@ubuntu ~]# smbpasswd -a ancy

New SMB password:

Retype new SMB password:

Failed to add entry for user test.

解决办法:

这是因为没有加相应的系统账号,所以会提示Failed to add entry for user的错误,只需增加相应的系统账号ancy就可以了

相关推荐
leoufung30 分钟前
vim 多个关键字高亮插件介绍
linux·编辑器·vim
Nerd Nirvana3 小时前
软考—系统架构设计(案例 | 论文)
linux·系统架构·软件工程·软考·计算机基础
勤奋的凯尔森同学5 小时前
webmin配置终端显示样式,模仿UbuntuDesktop终端
linux·运维·服务器·ubuntu·webmin
月光水岸New5 小时前
Ubuntu 中建的mysql数据库使用Navicat for MySQL连接不上
数据库·mysql·ubuntu
莫忘初心丶5 小时前
在 Ubuntu 22 上使用 Gunicorn 启动 Flask 应用程序
python·ubuntu·flask·gunicorn
丁卯4045 小时前
Go语言中使用viper绑定结构体和yaml文件信息时,标签的使用
服务器·后端·golang
chengooooooo5 小时前
苍穹外卖day8 地址上传 用户下单 订单支付
java·服务器·数据库
人间打气筒(Ada)7 小时前
MySQL主从架构
服务器·数据库·mysql
落笔画忧愁e8 小时前
FastGPT快速将消息发送至飞书
服务器·数据库·飞书
小冷爱学习!8 小时前
华为动态路由-OSPF-完全末梢区域
服务器·网络·华为