Bug 13868 - Configuration is not reloaded without restart
Configuration is not reloaded without restart
Status: NEW
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Other
4.9.1
x64 Linux
: P5 normal
: ---
Assigned To: Andrew Bartlett
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-03-29 12:12 UTC by Miguel A. Pina
Modified: 2019-03-29 14:44 UTC (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Miguel A. Pina 2019-03-29 12:12:19 UTC
Samba does not seem to reload its configuration when instructed to do so via one of the following options:

smbcontrol [destination] reload-config
kill -SIGUP <PID>
systemctl reload smbd
service smbd reload

In order to apply a configuration change, Samba must be restarted. I only found this for version 4.9.1-4 on RHEL8 Beta (kernel 4.18.0-32.el8.x86_64). Previous versions of Samba up to 4.7.1 do not show this problem.

The following debug log events appears on any of the aforementioned reload scenarios:

[2019/03/28 13:04:56.568158,  1] ../source3/smbd/server.c:1437(smbd_parent_sig_hup_handler)
  parent: Reloading services after SIGHUP
[2019/03/28 13:04:56.568833,  0] ../lib/param/loadparm.c:784(lpcfg_map_parameter)
  Unknown parameter encountered: "auth methods"
[2019/03/28 13:04:56.569011,  0] ../lib/param/loadparm.c:1810(lpcfg_do_global_parameter)
  Ignoring unknown parameter "auth methods"
[2019/03/28 13:04:56.569121,  1] ../lib/param/loadparm.c:1822(lpcfg_do_global_parameter)
  WARNING: The "client use spnego principal" option is deprecated
[2019/03/28 13:04:56.569314,  2] ../source3/param/loadparm.c:2803(lp_do_section)
  Processing section "[homes]"
[2019/03/28 13:04:56.569419,  2] ../source3/param/loadparm.c:2803(lp_do_section)
  Processing section "[rhel8]"
[2019/03/28 13:04:56.575008,  2] ../source3/lib/interface.c:345(add_interface)
  added interface eth0 ip=158.168.9.154 bcast=158.168.9.255 netmask=255.255.255.0
[2019/03/28 13:04:56.575112,  1] ../source3/printing/printer_list.c:234(printer_list_get_last_refresh)
  Failed to fetch record!
[2019/03/28 13:04:56.575316,  1] ../source3/printing/queue_process.c:236(bq_sig_hup_handler)
  Reloading pcap cache after SIGHUP
[2019/03/28 13:04:56.580365,  2] ../lib/util/tevent_debug.c:66(samba_tevent_debug)
  samba_tevent: EPOLL_CTL_DEL EBADF for fde[0x559644cc46d0] mpx_fde[(nil)] fd[16] - disabling

Steps to reproduce the test:
  1. Create any share giving a user R/O permissions.
  2. Start or restart Samba.
  3. Check that the user cannot create/remove/modify files.
  4. Change the configuration to allow R/W to the user.
  5. Reload the configuration.
  6. Check that the user still cannot create/remove/modify files.