Win Server2008 - How to know who/hostname accessing by RDP

Discussion in 'Windows Server Forums' started by NewComer01, Dec 31, 2014.

  1. NewComer01

    NewComer01 Member

    Joined:
    Dec 31, 2014
    Messages:
    2
    Likes Received:
    0
    Dear All,

    I would know who/hostname/date/time that accessing to my Win server 2008 R2 via a remote desktop connection, so i have a script with command ECHO to show these information to text file once user logon, but i donot know which environment variables for exactly who is remoting session and which host name (remote computer). Pls help!

    echo Log ON %Date% %TIME% %USERNAME% %COMPUTERNAME% >> %RDP%.log

    %computername%: is my server name 2008 (not remoting computer name)

    Thanks for your advise!
     
  2. NewComer01

    NewComer01 Member

    Joined:
    Dec 31, 2014
    Messages:
    2
    Likes Received:
    0
    actually, i can find out remoting host name by netstat, but i am appreciated if you share the batch file or script which I can extract a a log auto.
     

Share This Page

Loading...