[global]
workgroup = WORKGROUP
server string = Manjaro
server role = standalone server
log file = /usr/local/samba/var/log.%m
max log size = 50
server min protocol = NT1
ntlm auth = yes
[homes]
comment = Home Directories
browseable = no
writable = yes
[data]
comment = Data Directories
path = /data
public = yes
writable = no
printable = no
write list = @staff
sudosmbpasswd-a<your_username>
sudomkdir-p/data
sudogroupaddstaff# Create staff groupsudousermod-aGstaff<your_username># Add user to staff groupsudochownroot:staff/data# Change group ownership to staff groupsudochmod770/data# Change group permission to allow read and write
---
tags:
- Manjaro
- Linux
---
# Install and Configure SMB service on Manjaro KDE
!!! warning "文档时效性说明"
本文为早期笔记,可能存在版本过时、命令失效、链接失效、最佳实践变化等问题。请以官方最新文档为准。
## Install required packages
```bash
yay -Sy samba
yay -Sy wsdd
Note: wsddis required for local network discovery. Although samba server can run without wsdd, windows would not discover the network drives shared when the server's wsdd is down.
[global]
workgroup = WORKGROUP
server string = Manjaro
server role = standalone server
log file = /usr/local/samba/var/log.%m
max log size = 50
server min protocol = NT1
ntlm auth = yes
[homes]
comment = Home Directories
browseable = no
writable = yes
[data]
comment = Data Directories
path = /data
public = yes
writable = no
printable = no
write list = @staff
sudosmbpasswd-a<your_username>
sudomkdir-p/data
sudogroupaddstaff# Create staff groupsudousermod-aGstaff<your_username># Add user to staff groupsudochownroot:staff/data# Change group ownership to staff groupsudochmod770/data# Change group permission to allow read and write