On Mon, Oct 17, 2011 at 08:31:28PM +0530, Preethi Ramesh wrote: > I've been trying to run virt-top to save the usage statistics to a csv file > from my Java code using process builder. However, this gets executed in the > Java file but I don't seem to find the file created anywhere. Is executing > virt-top possible via a Java code? I'm using the example > here<http://forums.devx.com/showthread.php?t=147403>replacing ls -l > with virt-top --csv file2.csv. > > I plan to generate the graphs from the csv files to load them on to my Java > UI. If there are other alternatives to my method, please tell me as I've > been trying to get one for almost a week now.
I suspect you want to add some other flags, at least --script. If you don't use --script then virt-top will try to start up the ncurses display and that could fail in odd ways when run from a program. virt-top --script --csv /tmp/file.csv -n 5 Rich. -- Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones virt-df lists disk usage of guests without needing to install any software inside the virtual machine. Supports Linux and Windows. http://et.redhat.com/~rjones/virt-df/ _______________________________________________ virt-tools-list mailing list [email protected] https://www.redhat.com/mailman/listinfo/virt-tools-list
