Execute the two commands, that is, adding current user to tcpdump
group, then check the result by querying groups
. BUT, groups
does not report I'm a member of tcpdump
why?
Screenshot from Ubuntu 22.04:
At this time, I checked /etc/group
file, it has been added.
tcpdump:x:117:chj
In order to see tcpdump
listed in groups
command, I have to completely log out my desktop session then re-login.
How come it has to be so cumbersome? Am I missing something?
Try
groups $USER
to see the changes. Now, you are listing the groups for the current process, which may differ if the groups database has changed.