หมวด global
ทำให้แชร์ข้ามวงได้
hosts allow = 192.168.0.0/16
ทำเป็นปรินเตอร์เซิร์ฟเวอร์ผ่าน cups
load printers = yes
printing = cups
printcap name = cups
printer admin = @smbgroup
หมวด share
เร่งความเร็ว (ใช้กับแชร์ที่อ่านได้อย่างเดียว)
fake oplocks = yes
ต้องการอ่านจาก system backup ซึ่งปกติไม่ได้เมานต์ไว้
ดังนั้นก่อนใช้งานก็ต้องสั่งให้เมานต์ก่อน
[sysbak]
comment = System Backup Dir
path = /sysbak
valid users = @smbgroup
root preexec = mount /sysbakเครื่องพิมพ์เทียมเก็บไฟล์ pdf
[printtopdf]
path = /samba/data/smbprn/pdf
create mask = 0777
printing = bsd
printable= yes
Print command = DATE=`date +%F`;LOG="/samba/data/smbprn/pdf";gs -dBATCH -
sDEVICE=pdfwrite -sOutputFile=/samba/data/smbprn/$DATE-%s.pdf %s > $LOG/smb-pdf.l
og;rm %s
valid users = @smbgroup
public = yesเครื่องพิมพ์เทียมเก็บแฟกซ์เป็น tiff
[printtotiff]
path = /samba/data/smbprn/tif
create mask = 0777
printing = bsd
printable= yes
Print command = DATE=`date +%F`;LOG="/samba/data/smbprn/tif";gs -dBATCH -
sDEVICE=tiffg3 -sOutputFile=/samba/data/fax/FaxOut/$DATE-%s.tif %s >
$LOG/smb-FaxOut.log;rm %s
valid users = @smbgroup
public = yes
เป็นเครื่องแฟกซ์ โดยทำงานประสานกับ HylaFax-Server
(ต้องติดตั้ง hylafax-server ด้วย)
[hylafax]
path = /tmp
create mask = 0777
printable = yes
printcap name = lpstat
printing = cups
use client driver = Yes
print command = lp -d%p -oraw %s; rm %s
lpq command = lpstat -o%p
lprm command = cancel %p-%j
queuepause command = disable %p
queueresume command = enable %p
printer admin = @smbgroup