Im trying to automate a long list of database experiments. I would like to save vmstat output while specific parts of the experiments are running.
Does something exist along the lines of time(1) or script(1) that I could use to say:
" While this command is running, save
vmstat 2(or similar) output to a file " in my bash scripts
I am aware that vmstat gives my vmstat for the complete system including other processes, but that is OK for my usage.
(Running Ubuntu 9.10 if that makes a difference)