|
Bugzilla – Full Text Bug Listing |
| Summary: | AIX 5.3 with sudo version 1.6.9 odmget not working | ||
|---|---|---|---|
| Product: | Sudo | Reporter: | Pascal Froling <pascalf75> |
| Component: | Sudo | Assignee: | Todd C. Miller <Todd.Miller> |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | pascalf75 |
| Priority: | low | ||
| Version: | 1.6.9 | ||
| Hardware: | IBM | ||
| OS: | IRIX | ||
| Attachments: | sudo configure, make, make install | ||
It sounds like odmget needs something in the environment to work properly. Starting with sudo 1.6.9, sudo will clear the environment before executing a command. See the UPGRADE file that comes with sudo for details. The simple solution is probably to disable the environment clearing with a line like: Defaults !env_reset at the top of sudoers. A better solution is to find the environment variables you need and add them with lines like: Defaults env_keep += "SOMETHING" Thanks for your response Todd. I read the UPGRADE file but didnt think for the AIX odm there was a variable set. With your comment I had a closer look and found this while doing the env command as root:
ODMDIR=/etc/objrepos
Adding this to the /etc/sudoers file like:
Defaults env_keep += "ODMDIR"
solved the issue I had with the AIX ODM commands.
Sudo version 1.6.9p17
AsRoot: sudo odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID"
PdAt:
uniquetype = "disk/fcp/scsd"
attribute = "GUID"
deflt = "none"
values = ""
width = ""
type = "R"
generic = ""
rep = "s"
nls_index = 0
Thanks,
Pascal Froling
|
Created attachment 236 [details] sudo configure, make, make install Working Example: Machine X uname: AIX oslevel -s: 5300-08-03-0831 sudo -V: Sudo version 1.6.7p5 rpm -qa|egrep sudo: sudo-1.6.7p5-3 AsRoot: odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" Returns: PdAt: uniquetype = "disk/fcp/scsd" attribute = "GUID" deflt = "none" values = "" width = "" type = "R" generic = "" rep = "s" nls_index = 0 AsRoot: sudo odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" PdAt: uniquetype = "disk/fcp/scsd" attribute = "GUID" deflt = "none" values = "" width = "" type = "R" generic = "" rep = "s" nls_index = 0 Failing Example: Machine X uname: AIX oslevel -s: 5300-08-03-0831 sudo -V: Sudo version 1.6.9p15 rpm -qa|egrep sudo: sudo-1.6.9p15-2noldap AsRoot: odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" PdAt: uniquetype = "disk/fcp/scsd" attribute = "GUID" deflt = "none" values = "" width = "" type = "R" generic = "" rep = "s" nls_index = 0 AsRoot: sudo odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" 0518-506 odmget: Cannot open object class PdAt Check path name and permissions. Failing Example sudo build from scratch (see attachment) Machine X uname: AIX oslevel -s: 5300-08-03-0831 sudo -V: Sudo version 1.6.9p17 rpm -qa|egrep sudo: no rpm AsRoot: odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" PdAt: uniquetype = "disk/fcp/scsd" attribute = "GUID" deflt = "none" values = "" width = "" type = "R" generic = "" rep = "s" nls_index = 0 AsRoot: sudo odmget -q"uniquetype=disk/fcp/scsd" PdAt|egrep -p "GUID" 0518-506 odmget: Cannot open object class PdAt Check path name and permissions. I checked permissions and paths. They are the same on other machines. Issue comes up when on AIX commands are ran with sudo which access the AIX ODM using the above command (odmget). I did various test, which al resulted in above error. Thanks in advance, Pascal Froling