[Bug 1310792] Re: dfree command is not working anymore in samba

Peter de Kraker 1310792 at bugs.launchpad.net
Tue Apr 22 10:56:37 UTC 2014


I did some more digging through the logs, and it turns out that the command is called, but fails due to not being called as root user.
For access to the zfs stats you need to be root. This worked ok in 13.10, but it looks like the dfree command is not executed as root user anymore. I would call this a regression, but maybe this is intentional? Still,  it makes my dfree command useless...

[2014/04/22 12:48:52.745632,  0] ../source3/smbd/dfree.c:128(sys_disk_free)
  disk_free: file_lines_load() failed for command '/home/peter/scripts/zfs_free.sh .'. Error was : No child processes
Unable to open /dev/zfs: Permission denied.
Unable to open /dev/zfs: Permission denied.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to samba in Ubuntu.
https://bugs.launchpad.net/bugs/1310792

Title:
  dfree command is not working anymore in samba

Status in “samba” package in Ubuntu:
  New

Bug description:
  I have a ZFS On Linux setup as my main backup/fileserver that uses
  RaidZ1 (similar to raid 5: 3 disks, 1 parity).  Because Linux doesn't
  show the free space correctly for the complete disk/mount point, the
  disk space indicator on my Windows machine for this share gives the
  wrong info. The solution in Samba 3 / Ubuntu 13.10 was to add a "dfree
  command = scriptname" configuration option to smb.cnf that knew how to
  figure out the correct disk space/usage. This was all working and the
  total disk space was displayed correctly in Windows Explorer on the
  client.

  However, now after upgrading to 14.04, the diskspace suddenly gets
  displayed all wrong again.  I checked the script (it worked ok) and
  even let it output "0 0" to see if it actually gets called by samba,
  but nothing changed on the indicator of my windows machine. I did
  reboots of the server, and the client, and nothing changed. I also
  changed the "dfree command" to a invalid scriptname, and moved it from
  global to a share section. Nothing worked.

  Testparm gives no errors, so it looks like samba somehow just ignores
  this parameter. Manpage for smb.conf shows that the "dfree command"
  option is available.

  Looks like a regression to me, and is frustrating, because I can't see
  how much space I am using on my fileserver.

  ProblemType: Bug
  DistroRelease: Ubuntu 14.04
  Package: samba 2:4.1.6+dfsg-1ubuntu2
  ProcVersionSignature: Ubuntu 3.13.0-24.46-generic 3.13.9
  Uname: Linux 3.13.0-24-generic x86_64
  NonfreeKernelModules: zfs zunicode zavl zcommon znvpair
  ApportVersion: 2.14.1-0ubuntu3
  Architecture: amd64
  CurrentDesktop: Unity
  Date: Mon Apr 21 22:43:53 2014
  InstallationDate: Installed on 2013-09-29 (204 days ago)
  InstallationMedia: Ubuntu-Server 13.04 "Raring Ringtail" - Release amd64 (20130423.1)
  NmbdLog:
   
  OtherFailedConnect: Yes
  SambaServerRegression: Yes
  SmbConfIncluded: Yes
  SourcePackage: samba
  UpgradeStatus: Upgraded to trusty on 2014-04-21 (0 days ago)

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/samba/+bug/1310792/+subscriptions



More information about the foundations-bugs mailing list