What does awk -F: '!($3 < 512 && $4 < 30)' /etc/passwd do in Linux? I only find awk is a scripting language but cant understand all this is doing.
>Solution :
This is shorthand for
awk -F: '!($3 < 512 && $4 < 30) { print; }' /etc/passwd
and means "show all lines where NOT (:-separated field #3 is less than 512 and field #4 is less than 30)" from /etc/passwd
With the help of man 5 passwd and DeMorgan’s law, this corresponds to "show the user account list where the user id is greater than 512 or the group id is greater than 30".
This logic is likely intended to only show human users on the system, since a common convention is to assign them higher UIDs than non-human, system users like apache and mysql.