Announcement

Collapse
No announcement yet.

Problems writing a Script using -cnf switch with Logman.exe

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

  • Problems writing a Script using -cnf switch with Logman.exe

    I am trying to write a script that will automatically start perfmon with a specific set of counters. I need the logs to snap every 15 minutes and a new one be created. I can get everything to work except the creating of a new log every 15 minutes. I have copied the script below. If someone could tell me what I am doing wrong it would be a great help.

    logman create counter Test_Perf_log -rf 15:00 -cnf 15:00 -o c:\perflogs\trdperf -f bin -c "\Processor(_Total)\% Processor Time" "\Memory\Available Bytes" "\Memory\Cache Bytes" "\Memory\Committed Bytes" "\Memory\Pages/sec" "\Memory\Page Faults/sec" "\Memory\Pool Nonpaged Bytes \Process(*)\(*)" "\Network Interface(*)\Bytes Total/sec" "\Paging File(_Total)\% Usage" "\System\Context Switches/sec" "\System\Processor Queue Length"

    Thank You
    John

  • #2
    Re: Problems writing a Script using -cnf switch with Logman.exe

    Hi there,

    Could you set up a scheduled task to run a batch file every 15 mins (calling first your perfmon bat and then another batch file that, using robocopy, would copy and rename the log files

    This script would continue running until you stopped the scheduled task.

    Alternatively you could insert a date and time at the start of each scan and then append to a single file (maybe you intentionally want separate log files though, in which case ignore me!)

    Dave

    Edit:

    Oops, just seen the date on this one. It's kind of old! He's probably figured it out already!
    Last edited by gingerbeast121; 11th March 2010, 16:18.

    Comment


    • #3
      Re: Problems writing a Script using -cnf switch with Logman.exe

      I thought about doing it that way but it is not possible with the users. These users are extremely picky high end users. I was looking for the least intrusive way of getting the log to restart.

      The restart switch is the only switch that I can not get to work.

      Comment

      Working...
      X