Hello to everybody in the list. I want to close a samba share using a command that can be executed when i need it or scheduled with at/cron. I found that 'smbcontrol close-share' command supposed to do that, but when i try to run command it doesn't work. sudo smbcontrol smbd close-share My_Share It returns the following: Ignoring unknown parameter "use client drivers" WARNING: [printers] service MUST be printable! Ignoring unknown parameter "use client drivers" I don't know how to make this command to work. My server is Ubuntu 12.04LTS running Samba Version 3.6.3 Please, i really appreciate any help how to run this command. Sincerely, Carlos
Hello Carlos, Am 08.09.2015 um 17:42 schrieb Carlos R.P.Evertsz:> I found that 'smbcontrol close-share' command supposed to do that, but > when i try to run command it doesn't work. > > sudo smbcontrol smbd close-share My_ShareHave you read the manpage of smbcontrol? "close-share" just closes all connections to a share, without affecting other client connections. It doesn't remove a share.> It returns the following: > > Ignoring unknown parameter "use client drivers" > WARNING: [printers] service MUST be printable! > Ignoring unknown parameter "use client drivers"This doesn't mean that this command failed. It just tells you, what's wrong with your smb.conf. See "testparm".> I want to close a samba share using a command that can be executed > when i need it or scheduled with at/cron.https://lists.samba.org/archive/samba/2011-September/164268.html Regards, Marc
Hi Marc, Thank you for your email. I think something is wrong with the command or syntax. For example, I open the share folder in a Win workstation(\\server\My_Share) and then run the program to close that share in the server console. The workstation continues to have normal access to that share. Nothing change. I think If the command were running correctly the workstation would not be able to access the share. Is there other way to do this? I can try. Carlos On Sep/08/2015 12:08 PM, Marc Muehlfeld wrote:> Hello Carlos, > > Am 08.09.2015 um 17:42 schrieb Carlos R.P.Evertsz: >> I found that 'smbcontrol close-share' command supposed to do that, but >> when i try to run command it doesn't work. >> >> sudo smbcontrol smbd close-share My_Share > Have you read the manpage of smbcontrol? "close-share" just closes all > connections to a share, without affecting other client connections. It > doesn't remove a share. > > > >> It returns the following: >> >> Ignoring unknown parameter "use client drivers" >> WARNING: [printers] service MUST be printable! >> Ignoring unknown parameter "use client drivers" > This doesn't mean that this command failed. It just tells you, what's > wrong with your smb.conf. See "testparm". > > > > >> I want to close a samba share using a command that can be executed >> when i need it or scheduled with at/cron. > https://lists.samba.org/archive/samba/2011-September/164268.html > > > Regards, > Marc >
Reasonably Related Threads
- Please Help!!! smbcontrol close-share
- Please Help!!! smbcontrol close-share
- smbcontrol reload & close-share not working like previous version
- Does the command line "smbcontrol ALL reload-config" force a connected share to flush parameter ?
- smbcontrol smbd ping also answered by nmbd and winbindd