You are not logged in.
Pages: 1
I have a rather simple NAS setup that was converted recently to ZFS.
For windows sharing I still have the samba installed but I see that I can also have zfs directly publish SMB or CIFS devices. I consulted the oracle docs in http://docs.oracle.com/cd/E19253-01/819 … index.html and the arch wiki.
When on
$ sudo zfs list
NAME USED AVAIL REFER MOUNTPOINT
zdata 1.48T 1.19T 41.9K /mnt/zdata
zdata/backup 177G 323G 177G /srv/backup
zdata/media 1.25T 216G 1.25T /srv/media
zdata/sw 50.5G 49.5G 50.5G /srv/software
I try
$ sudo zfs set sharesmb=on zdata/media
I get following error
cannot share 'zdata/media': smb add share failed
I looked in dmesg but couln't find anything specific to this, nor in journalctl
What could be the cause of this
Last edited by theking2 (2015-01-18 14:54:22)
archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR
Offline
ZFSonLinux does not implement SMB itself; it just adds/removes shares to an SMB provider. It's trying to add a share to your provider, but that fails - at a guess I'd say your SMB provider (samba?) is not running.
Offline
Yes, I guess you need to edit samba.conf.
And, I may have a more decent/recent guide for you from the same club: http://docs.oracle.com/cd/E23824_01/htm … gayne.html
Offline
Thank you both.
Interesting (but a bit confusing). I already had this
[media]
comment = Media files
path = /srv/media
browseable = yes
guest ok = yes
writable = yes
in my smb.conf.
For my understanding what is the effect of sharesmb=on? Is it required for a mounted volume to share over samba?
Or is it a way of sharing a volume without mounting it localy?
Last edited by theking2 (2014-08-20 01:57:23)
archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR
Offline
Or is it a way of sharing a volume without mounting it localy?
I don't use samba myself, but yes, that is what I understand from: http://zfsonlinux.org/faq.html#HowDoISetupShares
Offline
I'm still confused why or if I should set up shares on both zfs AND on smbd.conf. Do I set this in both? or only one? why would I need a sharesmb if it already is shared in smbd.conf should I remove these from smbd.conf and only specify sharesmb in zfs? Should I set them up in both? and when so why?
It is confusing that one need to setup share in two just remotely connected places.
Puzzled
archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR
Offline
According to that page(see #5) you need to set only one.
You can share a ZFS file system by setting the sharenfs or sharesmb file system property.
Offline
In smb.conf I have
[backup]
comment = Bakcup Files
path = /srv/backup
browseable = yes
# guest ok = yes
writable = yes
How do I configure this with zfs sharesmb? Apart from zfs set sharesmb=on
EDIT---
BTW:
$ sudo zfs get sharesmb
NAME PROPERTY VALUE SOURCE
zdata sharesmb off local
zdata/backup sharesmb off local
zdata/media sharesmb off local
zdata/sw sharesmb off local
although sharesmb is off I can access the share from a Win box.
Last edited by theking2 (2014-12-23 16:49:31)
archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR
Offline
Not a Sysadmin issue, moving to NC...
Offline
Well, I guess that's because smb.conf is set. Name it smb.bak.
Then set the share again for zfs, 'sudo zfs set sharesmb=on share/path'.
I,m not familiar with this, so I could be wrong..
Offline
I've switch off sharesmb from all the datasets and instead user smbd.conf to share the mounted volumes which seems to work just fine..
archlinux on a Gigabyte C1037UN-EU, 16GiB
a Promise PDC40718 based ZFS set
root on a Samsung SSD PB22-J
running LogitechMediaServer(-git), Samba, MiniDLNA, TOR
Offline
I don't mean to necro bump this thread, but it turns up as first result on the big G, and beeing marked as solved it deserves an actual solution.
Configure /etc/samba/smb.conf
[global]
...
usershare path = /var/lib/samba/usershares
usershare max shares = 100
usershare allow guests = yes
usershare owner only = no
Create that usershare directory and set proper permissions on it. As root:
mkdir /var/lib/samba/usershares
chmod +t /var/lib/samba/usershares
Create users using smbpasswd, restart smbd. Works.
Offline
Pages: 1