All groups configured on the local system (usually is all you need to know):
cut -d: -f1 /etc/group | sort
Really all groups including LDAP and other potential remotely controlled group assignments:
getent group | cut -d: -f1 | sort
All groups configured on the local system (usually is all you need to know):
cut -d: -f1 /etc/group | sort
Really all groups including LDAP and other potential remotely controlled group assignments:
getent group | cut -d: -f1 | sort