LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
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!

Notices


Reply
  Search this Thread
Old 10-07-2010, 04:26 AM   #1
mazhar07
LQ Newbie
 
Registered: Jan 2008
Posts: 9

Rep: Reputation: 0
confguring crontab in rhel-5


Hi Frnds,

I want to schedule a crontab for shutting down the oracle application services. I created crontab -e by login as oracleuser and added time and run-part(script path to execute the cron). But i unable to execute on the schedule time.
Please give me the exact procedure for creating and execution of cronjobs in RHEL-5.

-MAZHAR
 
Old 10-07-2010, 04:47 AM   #2
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
Can you show what you did? Show us the crontab entry. Also check for the logs and see if there are any errors. Check for the permissions as well.
Setup cron on Linux howto..
 
Old 10-07-2010, 05:20 AM   #3
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,331
Blog Entries: 55

Rep: Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529Reputation: 3529
...in addition to what's been posted already:

Quote:
Originally Posted by mazhar07 View Post
Please give me the exact procedure for creating and execution of cronjobs
It could increase self-reliance if instead you learn to troubleshoot this issue:
* /usr/bin/run-parts (if that is the "run-part" you are referring to) is used to drive cronjobs in the /etc/directory not cron spools for un/lesser-privileged users in /var/spool/cron,
- read the email in the "oracleuser" account as cron will send to either owner or root,
- if you use an external script then check if it is owned by "oracleuser" account and has the right mode for execution under that account else if you use a command ensure it is correct,
- check if the "oracleuser" account is not in /etc/cron.deny and if /etc/cron.deny does not exist that the account is in /etc/cron.allow if it exists,
- check your /etc/(r)syslog(-ng).conf where cron daemon messages are sent to (defaults to /var/log/cron IIRC) then check that file for any errors related to your "oracleuser" account,
- in /etc/aliases redirect email for the "oracleuser" user to a mail account of an unprivileged user to be read by a human (and not root!) then run 'newaliases', then try to run the cronjob and read the human users email,
* - in /etc/aliases email for system users is redirected to root and root email should be redirected as above to a mail account of an unprivileged user to be read by a human.

** If you encounter warnings, errors or AVC messages (SELinux, Auditd) then please be verbose posting and if necessary post the exact cronjob script or command line you use.
 
Old 10-10-2010, 02:10 AM   #4
mazhar07
LQ Newbie
 
Registered: Jan 2008
Posts: 9

Original Poster
Rep: Reputation: 0
crontab configured as..

Quote:
Originally Posted by linuxlover.chaitanya View Post
Can you show what you did? Show us the crontab entry. Also check for the logs and see if there are any errors. Check for the permissions as well.
Setup cron on Linux howto..
Dear chaitanya,

#this script is to shutdown the oracle application service
3 9 * * * /ora/MAYCLN/inst/apps/MAYCLN_fegtestap/admin/scripts/adstpall.sh apps/apps >> /home/testreport
this was the entry in the #crontab -e (empty file opend and i given above line to get schedule. Plz let me know where i m doing mistake.
how to execute it and check it after running the cron job.

-MAZHAR
 
Old 10-11-2010, 01:34 AM   #5
linuxlover.chaitanya
Senior Member
 
Registered: Apr 2008
Location: Nagpur, India
Distribution: Cent OS 5/6, Ubuntu Server 10.04
Posts: 4,629

Rep: Reputation: Disabled
You are shutting down the application at around 9:03 in the morning. Is the application being used or locked. Can you see the log files.
Also refer to and answer all the points by unSpawn.
 
  


Reply


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
Problem In Scheduling with Crontab on RHEL 4 Raghu140 Linux - Newbie 4 10-23-2009 03:34 AM
Looking for information/help on confguring my Dell M60 Precision Wireless (TM 1300) celticdaddio Linux - Laptop and Netbook 1 10-18-2005 10:56 AM
error when confguring webalizer A Cow Linux - Software 5 12-09-2004 03:14 AM
Confguring DHCP SERVER nitinatdcm Linux - Networking 4 10-06-2004 04:45 AM
confguring pppd with GPRS fransemail Linux - Software 0 05-10-2004 05:05 PM


All times are GMT -5. The time now is 10:24 AM.

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