Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 11-08-2012, 10:59 AM   #1
LQ Newbie
Registered: Nov 2012
Posts: 3

Rep: Reputation: Disabled
How to run shell script with sudo user from external scheduler


We have using version linux 5 operating system.

my oracle installed under "admin" user.

we have to monitor my oracle database is available or not from my application server.

for this we prepared the shell script and put oracle sql command inside the shell script.
this shell script we have to run from external scheduler.

i am runing shell script from external scheduler with my login but i am not able to use oracle(is installed under admin)

Please any one tell me how to run to shell script sql command with sudo user from external scheduler.

Old 11-08-2012, 11:08 AM   #2
Senior Member
Registered: Oct 2004
Distribution: FreeBSD Arch
Posts: 1,869

Rep: Reputation: 250Reputation: 250Reputation: 250
with sudo user
User has to have permissions in the sudoers file to be able to run as root.

## User privilege specification
root ALL=(ALL) ALL

## Uncomment to allow members of group wheel to execute any command
# %wheel ALL=(ALL) ALL

## Same thing without a password

## Uncomment to allow members of group sudo to execute any command
# %sudo	ALL=(ALL) ALL


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to run shell script and ignore user abort ? deriklogov1983 Linux - Server 2 08-07-2012 08:31 PM
[SOLVED] sudo for www user to run root shell script via browser kzcom Linux - General 11 09-15-2010 01:48 AM
how to run a shell script with super user privs when my network get disconnected!!! sd|| Linux - Newbie 1 12-02-2009 05:14 AM
Shell Script - Change user & run multiple commands ijf99 Linux - Newbie 1 01-26-2009 06:15 AM
allow sudo for www user to run root shell script cccc *BSD 12 07-23-2005 03:48 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 08:15 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration