Simpler Navigation for Servers and Operating Systems - Please Update Your Bookmarks
Completed: a much simpler Servers and Operating Systems section of the Community. We combined many of the older boards, so you won't have to click through so many levels to get at the information you need. Check the consolidated boards here as many sub-forums are now single boards.
If you have bookmarked forums or discussion boards in Servers and Operating Systems, we suggest you check and update them as needed.
cancel
Showing results for 
Search instead for 
Did you mean: 

SUDO - Parse Error

JRFisher
Occasional Advisor

SUDO - Parse Error

I installed SUDO from the Internet Express Bundle and editted sudoers using VISUDO. Whenever I try to use SUDO with a simple command I get the following errors:

"parse error in /opt/iexpress/sudo/etc/sudoers near line 89"
"no valid sudoers sources found"

I have added a line like the following for my account: "mylogin ALL=(ALL) ALL"

I've also uncommented the following line: "%sudo ALL=(ALL) ALL" created a sudo group and put my account in it.

Any help would be greatly appreciated. Thanks,
John


8 REPLIES
klb
Valued Contributor

Re: SUDO - Parse Error


You probably have a syntax error in your sudoers file. Either a malformed entry in there or some stray special characters could cause this.

Try to cat -v the file and look for trash or unnecessary characters/spaces/tabs, etc.

Maybe just remove the file and start fresh. If you installed the MAN pages, do a man on sudoers and maybe find the sytax or some examples in there.

Hth,

-klb



JRFisher
Occasional Advisor

Re: SUDO - Parse Error

I did a CAT on the sudoers file and it appeared clean.

I then removed the whole Internet Express Bundle, rebooted and reinstalled the Internet Express Bundle.

I haven't modified the SUDOERS file yet and still get the same errors when I use sudo as a non-root user.
Patrick Wallek
Honored Contributor

Re: SUDO - Parse Error

What is around line 89 in the file?

If you go into 'visudo' and then try to exit, does it display any errors? When using 'visudo' if there is a problem in the file it should tell you if there is a problem.
JRFisher
Occasional Advisor

Re: SUDO - Parse Error

I get no errors when closing visodu.

Line 89 and 90 are below [lines I didn't modify]:

## Read drop-in files from /opt/iexpress/sudo/etc/sudoers.d

## (the '#' here does not indicate a comment)

I opened a case with HP and they've forwarded me to the Internet Express group [the bundle that sudo was included in].

I'll post the resolution when/if I get it fixed.
klb
Valued Contributor

Re: SUDO - Parse Error


I suspect either syntax error or content incompatibility in the file.

It's also possible you've got a permissions issue that limits access to something as a normal non-root user or with the setuid bit on various executables related to sudo.
JRFisher
Occasional Advisor

Re: SUDO - Parse Error

I heard back from the Internet Express Bundle team and they had me comment out the last line of the SUDOERS file [which I did not modify].
it now reads as below and works.

[last 2 lines]
## (the '#' here does not indicate a comment)
## #includedir /opt/iexpress/sudo/etc/sudoers.d

klb
Valued Contributor

Re: SUDO - Parse Error


HAHA, Nothing like a couple built in "issues" to keep the support folks busy eh?

How much of that is going on in today's "let's just outsource everything" environment. If all HP does is pay the bills, how could they possibly know exactly what those remote groups of developers and support 'engineers' are doing?
Highlighted
Michael Steele_2
Honored Contributor

Re: SUDO - Parse Error

klb

Ou - Bullseye scary thought.
Support Fatherhood - Stop Family Law