Ubuntu – Is it possible to filter top to show specific processes

performance-monitoringtopUbuntu

I'm run top and I want to always see java/tomcat/redis/mysql/mongo, is that possible?

Best Answer

You could to something like this

top -p `pgrep -d ',' "java|tomcat|redis|mysql|mongo"`

This gets pgrep to produce a comma separated list of pid's that are passed to top -p

Related Topic