Riaan's SysAdmin Blog

My tips, howtos, gotchas, snippets and stuff. Use at your own risk!

Solaris

Solaris Samba with Local Users

Most users would now be using Solaris 11 with the CIFS integrated modules and manage SMB sharing from ZFS directly.  So this post is not applicable to the "right" way of doing things.  I recently had to support a Solaris 11 Express server running samba and using local users.  So I made a few useful notes here.

Server specifics:

root@server1:/etc/samba# uname -a
SunOS server1 5.11 snv_151a i86pc i386 i86pc Solaris

# prtdiag
System Configuration: Sun Microsystems Sun Fire X2200 M2 with Quad Core Processor
BIOS Configuration: Sun Microsystems S39_3D12 10/06/2008
BMC Configuration: IPMI 1.5 (KCS: Keyboard Controller Style)
...

# smbd -V
Version 3.5.5

# svcs | grep samba
online         2011     svc:/network/samba:default

# ps -ef | grep mbd
root  1621     1   0   Nov 20 ?          64:55 /usr/sbin/nmbd -D
root  3421  1617   0   Dec 10 ?           0:07 /usr/sbin/smbd -D

...

Add user:


# useradd rrosso

# mkdir /server1/home/rrosso

# chown rrosso /server1/home/rrosso

# grep rrosso /etc/passwd
rrosso:x:151:10:Riaan Rossouw:/server1/home/rrosso:/bin/ksh

# pwconv

# smbpasswd -a rrosso
New SMB password:
Retype new SMB password:
Added user rrosso.

# pdbedit -L -v rrosso
Unix username:        rrosso
NT username:
Account Flags:        [U          ]
User SID:             S-1-5-21-1747637251-3107012253-2823653391-1004
Primary Group SID:    S-1-5-21-1747637251-3107012253-2823653391-513
Full Name:            Riaan Rossouw
Home Directory:       \\server1\rrosso
HomeDir Drive:
Logon Script:
Profile Path:         \\server1\rrosso\profile
Domain:               SERVER1
Account desc:
Workstations:
Munged dial:
Logon time:           0
Logoff time:          never
Kickoff time:         never
Password last set:    Tue, 11 Dec 2012 14:00:22 EST
Password can change:  Tue, 11 Dec 2012 14:00:22 EST
Password must change: never
Last bad password   : 0
Bad password count  : 0
Logon hours         : FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

Share specifics:


# testparm
Load smb config files from /etc/samba/smb.conf
rlimit_max: rlimit_max (256) below minimum Windows limit (16384)
Processing section "[homes]"
Processing section "[Backups]"
...
[Backups]
comment = IT Backups Folder
path = /server1/backup
valid users = rrosso
read only = No
create mask = 0777
force create mode = 0777
force directory mode = 0777
force directory security mode = 0777
volume = FileServer
follow symlinks = No
...

admin

Bio Info for Riaan