You must already be a member of said group to change to it as your primary GID.
Use the command ‘groups’ to see what groups you’re a member of, first in the list is primary.
[warthogs@lab1-23 ~]$ groups
csugrad mech_adm telerobotics mechoffice mechprof mediashare src cs6090 cei manu
To change your primary GID for your current session, run the command ‘newgrp’ followed by the name of the group:
[warthogs@lab1-23 ~]$ newgrp telerobotics
[warthogs@lab1-23 ~]$ groups
telerobotics csugrad mech_adm mechoffice mechprof mediashare src cs6090 cei man
If you want the change to persist, either add the command to your login script or contact us and request that we change your accounts primary GID.
Posted in: SSH Related, Unix