Hello I am using samba Version 4.11.2 compiled. To start the daemon I using /samba10/samba-4.11.2/bin/samba -s /etc/samba/smb.conf To stop correctly, what is recommended ? Actually I using kill -9 ... Regards.
On 21/09/2020 13:47, jmpatagonia via samba wrote:> Hello I am using samba Version 4.11.2 compiled. > > To start the daemon I using > > /samba10/samba-4.11.2/bin/samba -s /etc/samba/smb.conf > > To stop correctly, what is recommended ? > > Actually I using kill -9 ... > > Regards.What OS are you using ? Rowland
Am 21.09.20 um 14:47 schrieb jmpatagonia via samba:> Hello I am using samba Version 4.11.2 compiled. > > To start the daemon I using > > /samba10/samba-4.11.2/bin/samba -s /etc/samba/smb.conf > > To stop correctly, what is recommended ? > > Actually I using kill -9 ...SIGTERM or use a OS which a proper service manager like systemd which sends SGTERM to any process in the cgroup at stop [root at srv-rhsoft:~]$ cat /etc/systemd/system/smb.service [Unit] Description=Samba SMB Daemon After=network-up.service Requires=network-online.target network-up.service [Service] Type=notify NotifyAccess=all LimitNOFILE=32768 ExecStart=/usr/sbin/smbd --foreground --no-process-group ExecReload=/usr/bin/kill -HUP $MAINPID PermissionsStartOnly=true Restart=always RestartSec=1 Nice=19 PrivateTmp=yes PrivateDevices=yes ProtectKernelTunables=yes ProtectKernelModules=yes ProtectControlGroups=yes MemoryDenyWriteExecute=yes CapabilityBoundingSet=CAP_CHOWN CAP_SETGID CAP_SETUID CAP_DAC_OVERRIDE CAP_NET_BIND_SERVICE CAP_IPC_LOCK CAP_SYS_CHROOT SystemCallFilter=@system-service @network-io @privileged @resources SystemCallFilter=~@debug @module @mount @reboot
Reindl on the compiled version the samba binary file is not in /usr/sbin/smbd and i think start whith samba file not with smbd El lun., 21 sept. 2020 10:41, Reindl Harald <h.reindl at thelounge.net> escribi?:> > > Am 21.09.20 um 14:47 schrieb jmpatagonia via samba: > > Hello I am using samba Version 4.11.2 compiled. > > > > To start the daemon I using > > > > /samba10/samba-4.11.2/bin/samba -s /etc/samba/smb.conf > > > > To stop correctly, what is recommended ? > > > > Actually I using kill -9 ... > > SIGTERM or use a OS which a proper service manager like systemd which > sends SGTERM to any process in the cgroup at stop > > [root at srv-rhsoft:~]$ cat /etc/systemd/system/smb.service > [Unit] > Description=Samba SMB Daemon > After=network-up.service > Requires=network-online.target network-up.service > > [Service] > Type=notify > NotifyAccess=all > LimitNOFILE=32768 > ExecStart=/usr/sbin/smbd --foreground --no-process-group > ExecReload=/usr/bin/kill -HUP $MAINPID > PermissionsStartOnly=true > Restart=always > RestartSec=1 > Nice=19 > > PrivateTmp=yes > PrivateDevices=yes > ProtectKernelTunables=yes > ProtectKernelModules=yes > ProtectControlGroups=yes > MemoryDenyWriteExecute=yes > CapabilityBoundingSet=CAP_CHOWN CAP_SETGID CAP_SETUID CAP_DAC_OVERRIDE > CAP_NET_BIND_SERVICE CAP_IPC_LOCK CAP_SYS_CHROOT > > SystemCallFilter=@system-service @network-io @privileged @resources > SystemCallFilter=~@debug @module @mount @reboot >
On 22/09/2020 01:58, jmpatagonia wrote:> ubuntu 18.04 lts >Then can I suggest (again), that you stop compiling Samba yourself and use Louis's repo: http://apt.van-belle.nl/ This will get you Samba installed in the correct places and the required systemd units. Rowland