[Samba] preexec with win 10

Rowland penny rpenny at samba.org
Wed Feb 19 09:22:38 UTC 2020


On 19/02/2020 08:05, Roberto Tagliaferri - Tosnet srl via samba wrote:
> Sorry for the english :)
>
> Good morning, i've a little network with samba 4.2 on centos 6, NT 
> style domain and win7 client.

Excuse me, but do you not believe in updating things ?

Samba 4.2.x went EOL at the end of 2016

Win 7 went EOL in Januarary

NT-style domains are on the way out, they rely on SMBv1 and this will be 
removed from Samba.

> I've a root preexec and root postexec for tracking logon and logoff to 
> the share.
>
> root preexec = /usr/bin/log_access.php "%L" "%U" "%G"  "%S" "%I" "%m" ON
> root postexec = /usr/bin/log_access.php "%L" "%U" "%G"  "%S" "%I" "%m" 
> OFF
>
> I've add a win10 client, of course without domain but a simple set of 
> share.
> The preexec work in strange mode:
> This client logon approx at 9.00 am and logof near 01.00pm but in log 
> i see this:
>
> 14/02/2020 13:14 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt ON
> 14/02/2020 14:40 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt OFF
> 17/02/2020 13:31 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt ON
> 17/02/2020 15:30 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt OFF
> 18/02/2020 14:49 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt ON
> 18/02/2020 16:48 server-tosnet emissionefatture emissionefatture 
> lavori-ilaria 192.168.0.246 lenovo-emfatt OFF
>
> i've nothing logon at 9.00 but i've ON when the pc is disconnected 
> from the share
>
> Where is the problem?
>
>
Could this be that 'emissionefatture' logged into 'lenovo-emfatt' and 
then never went near the share 'lavori-ilaria' on the server 
'server-tosnet' ?

The scripts will only be executed when the share is contacted.

Rowland





More information about the samba mailing list