1825803 Members
2468 Online
109687 Solutions
New Discussion

Re: /etc/group

 
EY
Occasional Contributor

/etc/group

Hi all,

In /etc/group, there is a group ID named "guest", what is it for? Can I delete this group ID? Does it have any impact to the system if I deleted this group ID?

Thanks
5 REPLIES 5
Ivan Krastev
Honored Contributor

Re: /etc/group

Check which users belong to that group.
Check also for files with group ownership guest.

Bu default there is no such group in HP-UX.

regards,
ivan
Steven E. Protter
Exalted Contributor

Re: /etc/group

Shalom,

The answer is, it depends.

If you delete the group and its in use you may cause problems.

What it depends on is how the group is used.

This group name is itself a red flag and guest users should be discouraged. You need to find out how the user is used and then do a complete delete once you understand the implications, the group id, the users in /etc/passwd, all things associated.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Dennis Handly
Acclaimed Contributor

Re: /etc/group

To find Ivan's files with that group you can do:
find / -group gname

To find those users:
awk -F: -v grp=$(awk -F: '/guest/ {print $3}' /etc/group) \
'$4 == grp {print}' /etc/passwd
Vinoyee Madashery Poulo
Frequent Advisor

Re: /etc/group

Find out the group id for guest group from /etc/group file and grep for this group id in the /etc/passwd file. If there is no users then you can delete this group as this is not the default group. If there are any users who belongs to this group find out purpose of those users and act accordingly.
Rasheed Tamton
Honored Contributor

Re: /etc/group

Hi,

As told, there is no default group called guest in HP-UX. If this group exists in your system, before you remove it, what you have to do is to search all the files belong to that group

find / -group guest -exec ll {} +

The above command will list all the files belong to the guest group, if exist

then

grep guest /etc/group
(you will get the numerical group ID)
i.e, if the groupd id is 106, just grep the passwd file to see who are the users belong to this particular group

awk -F: ' $4 == 106 {print }' /etc/passwd

Based on the results, you can decide what to do - remove the group or keep it.