[Samba] How to get users last Login time

Marco Gaiarin gaio at sv.lnf.it
Tue Apr 23 15:20:31 UTC 2019


Mandi! Fosiul Alam via samba
  In chel di` si favelave...

> I am just wondering, is there any command to check in Samba4 to get user
> Last login time  ?

	ldbsearch ${LDB_OPTS} -b "${BASEDN}" "(&(objectClass=user)(sAMAccountName=$1))" lastLogonTimestamp | grep "^lastLogonTimestamp: " | cut -d ' ' -f 2-

-- 
dott. Marco Gaiarin				        GNUPG Key ID: 240A3D66
  Associazione ``La Nostra Famiglia''          http://www.lanostrafamiglia.it/
  Polo FVG   -   Via della Bontà, 7 - 33078   -   San Vito al Tagliamento (PN)
  marco.gaiarin(at)lanostrafamiglia.it   t +39-0434-842711   f +39-0434-842797

		Dona il 5 PER MILLE a LA NOSTRA FAMIGLIA!
      http://www.lanostrafamiglia.it/index.php/it/sostienici/5x1000
	(cf 00307430132, categoria ONLUS oppure RICERCA SANITARIA)



More information about the samba mailing list