Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

id -a

Status
Not open for further replies.

bluedragon2

IS-IT--Management
Jan 24, 2003
2,642
US
I have two mostly identical servers (Solaris 10). They have the same /etc/group file with the same permissions. On one server if I am logged in as myself (my username) and do id -a, I get the correct 6 groups. If I do id -a $myusername, I get the correct 6 groups.

On server 2, if I do id -a, I get the correct 6 groups, if I do id -a $myusername, it only shows three groups.

This happens for any username and is causing errors in an application.

Does anyone have any ideas on this?

Thanks

[Blue]Blue[/Blue] [Dragon]

If I wasn't Blue, I would just be a Dragon...
 
-r-xr-xr-x 1 root bin 81648 Aug 18 2008 /opt/sfw/bin/id*
-r-xr-xr-x 1 root bin 10280 Jan 22 2005 /usr/bin/id*
-r-xr-xr-x 1 root bin 10280 Jan 22 2005 /usr/xpg4/bin/id*


you may want to see which "id" your system is using

drsun [606278]-> /opt/sfw/bin/id --help
Usage: /opt/sfw/bin/id [OPTION]... [USERNAME]
Print information for USERNAME, or the current user.

-a ignore, for compatibility with other versions
-g, --group print only the effective group ID
-G, --groups print all group IDs
-n, --name print a name instead of a number, for -ugG
-r, --real print the real ID instead of the effective ID, with -ugG
-u, --user print only the effective user ID
--help display this help and exit
--version output version information and exit

Without any OPTION, print some useful set of identified information.

Report bugs to <bug-coreutils@gnu.org>.
drsun [606279]-> /opt/sfw/bin/id --version
id (GNU coreutils) 5.97
Copyright (C) 2006 Free Software Foundation, Inc.
This is free software. You may redistribute copies of it under the terms of
the GNU General Public License <There is NO WARRANTY, to the extent permitted by law.

Written by Arnold Robbins and David MacKenzie.


A great teacher, does not provide answers, but methods to teach others "How and where to find the answers"

bsh

35 years Bell, AT&T, Lucent, Avaya
Tier 3 for 25 years and counting
 
I am using /usr/bin/id (verified)

/usr/sfw/bin/id has been deleted.

[Blue]Blue[/Blue] [Dragon]

If I wasn't Blue, I would just be a Dragon...
 
Check /etc/nsswitch.conf (if using nis)

I would check the /etc/group file for syntax and long lines (I believe by default it is 512).
 
Thanks edgrandeperro,

nsswitch.conf is correct on both servers: files ldap

There are no long lines in the /etc/group file.

It is strange that id -a works, but id -a username does not.



[Blue]Blue[/Blue] [Dragon]

If I wasn't Blue, I would just be a Dragon...
 
How weird.

Might be worth copying the /etc/passwd file from the working server temporarily and see if makes a difference. Also check the cksums of your /etc/group files to be sure they're identical. Maybe also compare the output of truss id -a and truss id -a username to see if there are any clues there...

Annihilannic.
 
Everything is identical that I can see, I went through the truss's last Friday and there are differences (still trying to hash through them)...

Thanks for everyones input.

[Blue]Blue[/Blue] [Dragon]

If I wasn't Blue, I would just be a Dragon...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top