Using bash ps and cut together
ps
is printing out space separators, but cut
without -d
uses the tab character. The tr -s
squeezes the spaces together to get more of the separation that you want, but remember that there is the initial set of spaces (squeezed to one) hence why you need to add 1 to each field. Also, there are spaces in the commands for each word. This should work:
ps -L u n | tr -s " " | cut -d " " -f 2,3,14-