1834752 Members
2851 Online
110070 Solutions
New Discussion

problem with sudo

 
SOLVED
Go to solution
Todd McDaniel_1
Honored Contributor

problem with sudo

I have a small problem with sudo syntax.

I am trying to give oracle permission to sudo for the umount and mount commands for temporary filesystems used for backups. I keep getting syntax problems with my /etc/sudoers file when they try to execute it.

Here is the syntax that I have for the command.
oracle ALL=NOPASSWD: /usr/sbin/mount -F vxfs -o delaylog,largefiles,nodatainlog,mincache=direct,convosync=direct /dev/vgora4/oradt_fs12 /oradata/fs12

I am not sure where my problem is. It appears that the syntax is correct, maybe it doesn't like the spaces, but I have other entries with spaces.

Thanks for your help.
Unix, the other white meat.
3 REPLIES 3
Craig Rants
Honored Contributor
Solution

Re: problem with sudo

Just try
/usr/sbin/mount *, see if they can run it then. If they can, you probably have run into a limit on the lenght of the command that sudo can handle.

GL,
C
"In theory, there is no difference between theory and practice. But, in practice, there is. " Jan L.A. van de Snepscheut
Craig Rants
Honored Contributor

Re: problem with sudo

Also, as the oracle user what does sudo -l say they can run?

GL,
C
"In theory, there is no difference between theory and practice. But, in practice, there is. " Jan L.A. van de Snepscheut
Patrick Wallek
Honored Contributor

Re: problem with sudo

Why not create a script that has the mount and umount commands in it and then just allow oracle access to the script instead of to the specific mount command?