How do I identify the number (integer value) of a particular group associated with a file?
ls -l
drwxr-x--x root system 2014-11-26 10:59 xyz
I have managed to check that group id of root is 0
. What is the corresponding number of group id for system?
I need to change the group of my file to system. How do I do it using chown? gid_t is internally of int type. So what value should I pass to make it system? How do I know?
Check with AID_XXX Ex:
AID_SYSTEM
in the source code. The corresponding value is the integer value of it.Similarly it can be found for other groups as well.
I don't know if there is a better way.