Sudo version 1.8.3p1 problem? (351 Views)
Reply
Regular Advisor
Posts: 255
Registered: ‎03-11-2005
Message 1 of 3 (351 Views)
Accepted Solution

Sudo version 1.8.3p1 problem?

Hello all.

We're running Sudo version 1.8.3p1 on an HP-UX 11.31 ia64 server.

We have an account called user1 configured in /etc/sudoers to run many commands including the following

/usr/bin/ksh
/opt/bin/submit
/usr/bin/at

 

Despite this, we're getting the following error.

 

$ sudo -i -u user1 "echo /opt/bin/submit DATA | at now"
ksh: echo /opt/bin/submit DATA | at now: not found

 

The account running this sudo command is also configured in /etc/sudoers.

Any ideas why the "ksh:....not found" error is being generated.

Is this a sudo or perhaps a ksh $PATH issue?

Any help would be appreciated.

Thanks everyone.

Acclaimed Contributor
Posts: 25,716
Registered: ‎03-06-2006
Message 2 of 3 (331 Views)

Re: sudo version 1.8.3p1 problem?

>ksh: echo /opt/bin/submit DATA | at now: not found

 

Are you sure you're suppose to quote the whole command?  The ksh error indicates the shell got:

"echo /opt/bin/submit DATA | at now"  # as one token

 

I suppose you could do:

sudo -i -u user1 ksh -c  "echo /opt/bin/submit DATA | at now"

Or better:

echo /opt/bin/submit DATA | sudo -i -u user1 at now

Regular Advisor
Posts: 255
Registered: ‎03-11-2005
Message 3 of 3 (314 Views)

Re: sudo version 1.8.3p1 problem?

Hello Dennis.

Thanks for the feedback.

In the past we always enclosed the entire command in quotes - at least we did with previous versions of sudo (sudo-1.7.1).

With this version of sudo, that doesn't seem to work, however the command you provided...

 

sudo -i -u user1 ksh -c  "echo /opt/bin/submit DATA | at now"

 

...does work.

 

Thanks again for the help.

The opinions expressed above are the personal opinions of the authors, not of HP. By using this site, you accept the Terms of Use and Rules of Participation.