Exemplo avançado:
Exibe a localização dos programas que controlam os processos python ativos.
netstat -naltpu|grep python |sort |grep -i LIST|awk '{print $7}'|awk -F/ '{print $1}'|while read a; do ps aux|grep $a|grep python|awk '{print $14}'|awk -F/ 'BEGIN {OFS="/"} {print $2,$3,$4,$5}'; done|sort -u
opt/p255/prod/PRTemaSimples
opt/p255/prod/SecretariaPR
opt/p255/prod/SignupSheet
opt/pzp255/app/saf_fccr_8100_1355154265
opt/pzp255/app/saj_legislacao_8105_1355163139
opt/pzp255/prod/cluster8220
opt/pzp255/prod/saf_fccr_8225_1353602041
Comentários