When experiencing networking problems on client machines, I\'d like to be able to run a few command lines and email the results of them to myself.
I\'ve found Runtim
Use ProcessBuilder. After calling start() you'll get a Process object from which you can get the stderr and stdout streams.
UPDATE: ProcessBuilder gives you more control; You don't have to use it but I find it easier in the long run. Especially the ability to redirect stderr to stdout which means you only have to suck down one stream.