- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Find by GID (13)
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:45 AM
05-03-2007 05:45 AM
drwxrwxrwx 2 autosys sys 8192 Apr 28 03:14 Autolog
drwxr-xr-x 2 psa 13 96 Nov 21 09:24 DBA
drwxr-xr-x 2 psa sys 96 Nov 21 09:24 EBR
drwxrwxr-x 2 psa 13 96 Nov 21 09:24 SAP
drwxr-xr-x 2 root sys 96 Nov 21 09:24 UX
I've tried find / -group 13 -xdev -exec ll {} \; just to see if my syntax is correct but it isn't even close.
Can show how to pick out that GID 13 which no longer exists in group file?
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:51 AM
05-03-2007 05:51 AM
Re: Find by GID (13)
Find all files:
find / -group dba1 -xdev -exec ll{} \;
After that change group ownership to 130 and delete group dba1.
regards,
ivan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:52 AM
05-03-2007 05:52 AM
Re: Find by GID (13)
I'm just guessing because the man page confuses me. It says "True if the file belongs to the group gname. If gname is numeric and does not appear in the /etc/group file, it is taken as a group ID."
Unable to interpret that particular phrasing, I would suggest creating an entry for GID 13 that names some fictitious group and then searching on the group name.
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:54 AM
05-03-2007 05:54 AM
Re: Find by GID (13)
Thanks,
Tonya
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:57 AM
05-03-2007 05:57 AM
Re: Find by GID (13)
# find /path -xdev -group 13 -exec chgrp dba {} \+
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:57 AM
05-03-2007 05:57 AM
Re: Find by GID (13)
Do a "type ll" to make sure that it is the command you want and not an alias or use ls -l
find / -group 13 -xdev -exec ls -l {}
should do just what you want and the lack of a corresponding group entry shouldn't matter.
Of course, if all you want to do to list those files then
find / -group 13 -xdev > /tmp/mylist
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 05:59 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 06:11 AM
05-03-2007 06:11 AM
Re: Find by GID (13)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 06:20 AM
05-03-2007 06:20 AM
Re: Find by GID (13)
I would suggest skipping the -xdev option. Your find command starts in the / directory and the -xdev option prevents you from crossing mount points, i.e. you will never enter other file systems than root - and the other filesystems are probably where the interesting files are located.
regards,
John K.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2007 06:21 AM
05-03-2007 06:21 AM