Unable to save traces from a Java program RRS feed

  • Question

  • Using the nmcap with a filter IPv4.Address==

    The traces are not saved, when I start the tool from Java program.

    But the same command works fine when executed directly from the command-promptgard?.

    Please can you help me in this regard?

    • Edited by prasad.phmd Wednesday, July 11, 2012 8:40 AM
    Wednesday, July 11, 2012 8:39 AM

All replies

  • Hi Prasad,

    We haven't done any testing with executing the command from Java, but if you're just calling nmcap; I can't see why you would be facing issues.  Can you run another program using your method?

    What functions are you using to execute the program?  Are you escaping your strings?


    Michael Hawker | Program Manager | Network Monitor

    Wednesday, July 11, 2012 3:45 PM
  • Hi Michael,

    Thanks for your support.

    I am executing a command : 

    Command = nmcap /network * /capture "(IPv4.Address ==" /file test.cap

    In Java I use the escaping, as below:

    String cmd = "nmcap /network * /capture /"(IPv4.Address ==" /file test.cap";


    This will start the process and I want to process the output of the process, obtained every second.

    Capturing   | Received: 29 Pending: 4 Saved: 0 Dropped: 0 | Time: 5 seconds.

    Here, If I remove the filtering, then, captured frames are saved. 

    Capturing   | Received: 43 Pending: 4 Saved: 43 Dropped: 0 | Time: 8 seconds.


    Thursday, July 12, 2012 5:07 AM
  • Hi Michael,

    Thanks for your support.

    After running the program for some long time, frames are getting saved.

    The problem seems to be just a delay in saving the frames.


    Thursday, July 12, 2012 6:33 AM