In case of one program having multiple instances, running pidof program
gives:
`1 2 3`
top -p
accepts comma-delimited arguments: 1, 2, 3
.
This means that top -p `pidof program`
won't work:
top: unknown argument '1'
usage: top -hv | -bcisSH -d delay -n iterations [-u user | -U user] -p pid [,pid ...]
Can you show me how to do this. I'm not familiar with awk, sed, etc...