Opensolaris adventure, part 5; CIFS
A user asks
I am only a poor lowly windows user, but I want some of your storage. Can haz CIFS please?
CIFS and SMB are the way that windows shares work. And, as it happens, setting them up in opensolaris is nice and easy.
I used this as a guide, but NOTE THE TYPO where it says
add the packages SUNWsmbkr & SUNWsmbs, it should be
add the packages SUNWsmbskr & SUNWsmbs (note extra ’s’). As you can see below, if you fail to do this, it’s fixable, but painful.
So, here we go…
# pkg install SUNWsmbs SUNWsmbkr ... complains about non-existence of SUNWsmbkr # pkg install SUNWsmbs # svccfg import /var/svc/manifest/network/smb/server.xml # zfs create -o casesensitivity=mixed pool0/cifs0 # zfs set sharesmb=on pool0/cifs0 # smbadm join -w solcifs ... error about "SMB cannot start service"...
head-scratching follows. Eventually work out solution
# pkg install SUNWsmbskr ... next two steps probably not required if you do it right the first time # rem_drv smbsrv # add_drv -m '* 0640 root sys' smbsrv # svcadm clear smb/server # smbadm join -w solcifs # zfs set sharesmb=name=disk1 pool0/cifs0
victory! windows clients can now connect to ‘disk1’ on my server :-)
The only additional requirement is that, in order to generate the smbpasswd file, each user that wants to connect needs to do ‘passwd’, to regenerate their password. I’m going to see if we can switch to use an LDAP backend to get around that.