Sorting results of ps by start time Sorting results of ps by start time unix unix

Sorting results of ps by start time


You use etime. That's elapsed time, in days, hours, etc. which is suitable for sorting numerically. If it's the first column, I think ps will sort by it automatically.

Otherwise, you can override sort order by using --sort, but make sure it is after the -o option, example:

ps -o pid,user:32,start,etime,state,time,vsz,args --sort=etime