Unix Technical Forum

Snap problem

This is a discussion on Snap problem within the AIX Operating System forums, part of the Unix Operating Systems category; --> Hi to all, When I execute snap -a /snap -r command, I have get the following error: # snap ...


Go Back   Unix Technical Forum > Unix Operating Systems > AIX Operating System

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 01-05-2008, 06:48 AM
mk
 
Posts: n/a
Default Snap problem

Hi to all,
When I execute snap -a /snap -r command, I have get the following error:
# snap -a
Must be root user [0] to use this utility.
# snap -r
Must be root user [0] to use this utility.
But exactly, i'm root (am i really??!?)
# whoami
root

What can be the problem which produce such a silly output?

Any help will be appreciated.

Thanks
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 01-05-2008, 06:48 AM
Laurenz Albe
 
Posts: n/a
Default Re: Snap problem

mk <b_eagle7@yahoo.com> wrote:
> # snap -a
> Must be root user [0] to use this utility.
> # snap -r
> Must be root user [0] to use this utility.
> But exactly, i'm root (am i really??!?)
> # whoami
> root
>
> What can be the problem which produce such a silly output?


Hard to say. What is the output of the 'id' command in this situation?

Can you check if snap is an executable or a shell script? If it is the
latter, look into it.

Yours,
Laurenz Albe
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 01-05-2008, 06:48 AM
Mark Taylor
 
Posts: n/a
Default Re: Snap problem

userid=`id -ru`
if [ "$userid" != 0 ]
then
echo "Must be root user [0] to use this utility."
exit 2
fi


What does id -ru produce on your system for the root user ?

Rgds
Mark Taylor

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 01-05-2008, 06:48 AM
mk
 
Posts: n/a
Default Re: Snap problem

Both id and id -ru commands produce the following output:

uid=0(root) gid=0(system) groups=2(bin),3(sys),7(security),8(cron),10(audit) ,11(lp)


"Mark Taylor" <mky@talk21.com> wrote in message news:<1107945328.276906.327480@g14g2000cwa.googleg roups.com>...
> userid=`id -ru`
> if [ "$userid" != 0 ]
> then
> echo "Must be root user [0] to use this utility."
> exit 2
> fi
>
>
> What does id -ru produce on your system for the root user ?
>
> Rgds
> Mark Taylor

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #5 (permalink)  
Old 01-05-2008, 06:48 AM
Mark Taylor
 
Posts: n/a
Default Re: Snap problem

So, it looks like the id command is screwed up.. it should produce this
output.

/home/root> id
uid=0(root) gid=0(system)
groups=2(bin),3(sys),7(security),8(cron),10(audit) ,11(lp)

/home/root> id -ru
0

Can you run some debug info, 1st check your ML levels etc..

lppchk -v
oslevel -r
instfix -i | grep ML
lslpp -h bos.rte.security
type id

Then run file and what on the path to id given from the above command
to see if anyone has corrupted, or hacked your id command i.e.

file /usr/bin/id
what /usr/bin/id

Or to cut out the middle man, you could just update bos.rte.security to
the latest level, or you could run truss against the id command to see
what its doing.

Cheers
Mark Taylor

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 06:57 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com