[Samba] preexec with win 10
Roberto Tagliaferri - Tosnet srl
r.tagliaferri at tosnet.it
Fri Feb 21 11:39:32 UTC 2020
Il 19/02/20 10:22, Rowland penny via samba ha scritto:
> 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.
Ok, this change is in to-do list :)
>
>> 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
>
>
The share is connected as letter L: in windows and the file was updated many
time
Windows don't close the connection when the operator disconnect windows.
This is an extract of smbstatus
root at robytnuovo~# smbstatus |grep 246
1877 emissionefatture emissionefatture 192.168.0.246
(ipv4:192.168.0.246:49701) SMB3_00
lavori-ilaria 1877 192.168.0.246 Wed Feb 19 14:37:30 2020
appoggio 1877 192.168.0.246 Wed Feb 19 14:37:30 2020
praticx 1877 192.168.0.246 Wed Feb 19 14:37:30 2020
But the operator use this share
root at roberto/lavori/ILARIA# v
totale 4808
-rwxr-xr-x 1 root root 4900596 3 feb 12.59 ADSL_scadenze.ods*
-rwxr-xr-x 1 root root 18099 *21 feb 11.05* CLIENTI\ BASE-FACILE.ods*
Yesterday the operator not work at all.
--
TosNet.it
Roberto Tagliaferri
Responsabile Progettazione & Produzione
TosNet s.r.l. - Internet Service Provider
*Office*: +39 0574 875 100
*Mobile*: +39 329 591 3899
*Fax*: +39 0574 875 199
*Email*: r.tagliaferri at tosnet.it <mailto:r.tagliaferri at tosnet.it>
*Web*: www.tosnet.it <http://www.tosnet.it>
*Skype*: ilrobyt <skype:ilrobyt?call>
More information about the samba
mailing list