Announcement

Collapse
No announcement yet.

Weekly Logon Report for particular User

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Weekly Logon Report for particular User

    Hi,

    we are using windows 2003 domain controllers

    is it possible to the logon reports for a particular user. example i want a logon time report for user "X" for a week of time. i want the following details in that

    1. username
    2. login time.
    3. from which system he logged in.

    any scripts or tools available for this ?
    Regards,
    Venkatesan S

  • #2
    Re: Weekly Logon Report for particular User

    It is very easy to do.

    What type of logon script are you running??

    Comment


    • #3
      Re: Weekly Logon Report for particular User

      Hi,

      I am not using any logon script yet.
      Regards,
      Venkatesan S

      Comment


      • #4
        Re: Weekly Logon Report for particular User

        Originally posted by Venkatesan View Post
        Hi,

        I am not using any logon script yet.
        Create a script called logon.cmd and add the following line to it

        Code:
        echo logon %username% %computername% %date% %time% >> \\DOMIANNAME\netlogon\logon.log
        Add the logon script to the user account in AD and start watching them log on.

        Comment


        • #5
          Re: Weekly Logon Report for particular User

          Is it possible to use more than one logon script?

          Comment


          • #6
            Re: Weekly Logon Report for particular User

            Hi wullieb1

            I have configure logon script its working fine, thanks for your help.

            i am getting the following informations in the log
            username, computername,date, time

            Is it possible to get Group details in the same log?
            Regards,
            Venkatesan S

            Comment


            • #7
              Re: Weekly Logon Report for particular User

              Originally posted by jules818 View Post
              Is it possible to use more than one logon script?
              Not directly no - but the logon script can "call" as many other scripts as you need.


              Tom
              For my own and your protection, I do not provide support by private message under any circumstances. All such messages will be deleted and ignored.

              Anything you say will be misquoted and used against you

              Comment


              • #8
                Re: Weekly Logon Report for particular User

                Originally posted by Venkatesan View Post
                Hi wullieb1

                I have configure logon script its working fine, thanks for your help.

                i am getting the following informations in the log
                username, computername,date, time

                Is it possible to get Group details in the same log?
                Nice to se it works.

                To do that i would recommend using VBScript and not batch files as it would be easier to use.

                You could of course call a vbs file from your batch file and do it that way.

                Comment


                • #9
                  Re: Weekly Logon Report for particular User

                  Thanks Wullie, was using something similar but I like your method better. I added it to the bottom of my logon.bat but after recording 3-4 user logons it simply overwrites itself. Any idea why?

                  Comment


                  • #10
                    Re: Weekly Logon Report for particular User

                    Originally posted by f21 View Post
                    Thanks Wullie, was using something similar but I like your method better. I added it to the bottom of my logon.bat but after recording 3-4 user logons it simply overwrites itself. Any idea why?
                    In short nope.

                    It should just keep appending to the bottom of the file.

                    Comment


                    • #11
                      Re: Weekly Logon Report for particular User

                      Hi wullieb1

                      As you mentioned can you please post the vbscript for the same

                      i want these type of log.

                      logon/logoff username ipaddress date time

                      note : in the previous batch file i am getting the computer name in which the user login is it possible to get the ip address of the computer.

                      Hi F21,

                      with out any problem its working for me last 2 days i am getting more than 100 logs no issues found.
                      Regards,
                      Venkatesan S

                      Comment


                      • #12
                        Re: Weekly Logon Report for particular User

                        ipconfig /all > \\fileserver\%username%@%computername%.txt
                        echo logon %username% %computername% %date% %time% >> \\fileserver\@logon.log

                        I'm just using a simple batch file for this (is there any advantage to making this a command file vs batch?). Wanted the full ipconfig readout and found it easier to sort through users as individual files than in a log and many of our users use multiple machines. Added benefit for me of doing it this way is that it overwrites old IPs if users are assigned a new one and only creates new logs according to user/computername.

                        I'd love to put it all into a spreadsheet with the same overwrite functionality(ip/mac address/gateway/dns/dhcp/pc name/username/time logged on/off) but I don't know how. If anyone knows a good script to do this, please let me know.

                        Comment


                        • #13
                          Re: Weekly Logon Report for particular User

                          Originally posted by f21 View Post
                          I'd love to put it all into a spreadsheet with the same overwrite functionality(ip/mac address/gateway/dns/dhcp/pc name/username/time logged on/off) but I don't know how. If anyone knows a good script to do this, please let me know.
                          Ahummm.. ,

                          f21 you are Hijacking someonce's Thread now!


                          If you have a question, start a new thread instead! (adding a cross reference to previous posts if you want to). And give your post a good subject title, reflecting the question's intentions.

                          This posting is provided "AS IS" with no warranties, and confers no rights.

                          __________________

                          ** Remember to give credit where credit's due **
                          and leave Reputation Points for meaningful posts

                          Comment


                          • #14
                            Re: Weekly Logon Report for particular User

                            Actually if you look at the first five lines, I was trying to answer the original posters question in the previous reply regarding how to get IPs in his batch, and simply asked if anyone knew a better way than my personal suggestion

                            Also didn't want to start what I thought would be a redundant thread.

                            Comment


                            • #15
                              Re: Weekly Logon Report for particular User

                              to get the group membership of the currently logged in user you could use the following

                              Code:
                              dsquery user -upn *%username%* | dsget user -memberof >> \\server\path\logname.log
                              Technology is only as good as those who use it

                              My tech blog - wiredtek.wordpress.com

                              Comment

                              Working...
                              X