Option 1: Number of processes run by a lsdyna_smp_s_r1
Sometimes we need to get the number of processes run by a lsdyna_smp_s_r1. For example if you are running a software named lsdyna_smp_s_r1 and you want to know how many processes were spawn, you can use the command
# ps -C lsdyna_smp_s_r1 | wc -l 183
OR if you are checking for the number of processes for SSH
# pgrep lsdyna_smp_s_r1 | wc -l 183
Option 2: Number of processes run by a User
# ps -U user1 | wc -l 333
I see that you also have discovered the incredible usefulness of the wc command. 😛
LikeLike