×
Linux 教程Linux 简介Linux 安装Linux 系统启动过程Linux 系统目录结构Linux 忘记密码解决方法Linux 远程登录Linux 文件基本属性Linux 文件与目录管理Linux 用户和用户组管理Linux 磁盘管理Linux vi/vimlinux yum 命令

Shell 教程

Shell 教程Shell 变量Shell 传递参数Shell 数组Shell 运算符Shell echo命令Shell printf命令Shell test 命令Shell 流程控制Shell 函数Shell 输入/输出重定向Shell 文件包含

Linux 参考手册

Linux 命令大全Nginx 安装配置MySQL 安装配置

Linux testparm命令


Linux 命令大全Linux 命令大全


Linux testparm命令用于测试Samba的设置是否正确无误。

执行testparm(test parameter)指令可以简单测试Samba的配置文件,假如测试结果无误,Samba常驻服务就能正确载入该设置值,但并不保证其后的操作如预期般一切正常。

语法

testparm [-s][配置文件][<主机名称><IP地址>]

参数说明

  • -s 不显示提示符号等待用户按下Enter键,就直接列出Samba服务定义信息。

实例

查看Ssmba配置

# testparm     
Load smb config files from /etc/samba/smb.conf
Processing section '[homes]'
Processing section '[printers]'
Processing section '[uptech]'
Processing section '[home]'
Loaded services file OK.
Server role: ROLE_STANDALONE
Press enter to see a dump of your service definitions
      ///按下回车继续
# Global parameters
[global]
workgroup = MYGROUP
server string = Samba Server
security = SHARE
encrypt passwords = No
password server = None
log file = /var/log/samba/%m.log
max log size = 50
socket options = TCP_NODELAY SO_RCVBUF=8192 SO_SNDBUF=8192
printcap name = /etc/printcap
dns proxy = No
idmap uid = 16777216-33554431
idmap gid = 16777216-33554431
cups options = raw

[homes]
comment = Home Directories
read only = No
browseable = No

[printers]
comment = All Printers
path = /var/spool/samba
printable = Yes
browseable = No

[uptech]
comment = *
path = /home/uptech
read only = No
guest ok = Yes

[home]
comment = *
path = /home
read only = No
guest ok = Yes

Linux 命令大全Linux 命令大全


分类导航

关注微信下载离线手册

bootwiki移动版 bootwiki
(群号:472910771)