Sponsored Content
Top Forums UNIX for Beginners Questions & Answers /etc/cron.daily script is not being executed Post 302995076 by anil529 on Friday 31st of March 2017 12:07:00 PM
Old 03-31-2017
/etc/cron.daily script is not being executed

Hi All

I have created a file in /etc/cron.daily on redhat linux 7.3 version host
called applicationscript

Code:
cat applictaionscript
#!/bin/bash
/prod/data/routine.sh

Code:
cat /prod/data/routine.sh
#!/bin/bash
#details
regular=/prod/data/jboss/logs
backup=/prod/data/logs
#echo "Moving logs"
find $regular -name "*.log" -mtime +15 -exec mv -f {} $backup \;
find $backup -name "*.log" -mtime +30 -exec rm -f {} \;


this /prod/data/routine.sh is executing from /prod/data/ but not auto executing from /etc/cron.daily

I checked cat /etc/anacrontab it is all data needed

Please suggest if I am missing something to set up right ?

Last edited by Don Cragun; 04-01-2017 at 02:49 AM.. Reason: Fixed ICODE tags.
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

ant not being executed as cron job

i have a script that uses an ant build.xml and its targets to pull a project from a cvs server, attempt to build the project, and then email me the results. When I run the script (either @ CLI or as a cron job) while I am logged in, everything works fine. However, if the script is set up to run... (5 Replies)
Discussion started by: kingfinny
5 Replies

2. UNIX for Dummies Questions & Answers

cron.daily

At what time does cron.daily implement and how can i change this or set it etc? Thanks in advance. (5 Replies)
Discussion started by: ITFcraig
5 Replies

3. UNIX for Dummies Questions & Answers

Help Creating Daily Cron Job

I need to create a cron job that will run daily to change permissions to a particular folder to 666 every 24hrs. I have no experience with crontab or cron jobs at all so if someone can guide me through this it would be a great help. The folder's example is 'www/test/htdocs' Also if you... (3 Replies)
Discussion started by: Xechno
3 Replies

4. Shell Programming and Scripting

List all daily scheduled cron jobs from my cronfile

I had a cron file named mycron.cron and this file has cron jobs runs through out 365 days (jobs in the file mycron.cron run hourly, daily, weekly, monthly, quarterly and yearly). Is there an easy way to find what are the jobs scheduled today and what time they are scheduled to run? Thanks in... (1 Reply)
Discussion started by: sureng
1 Replies

5. AIX

Script not getting executed via cron but executes when executed manually.

Hi Script not getting executed via cron but executes successfully when executed manually. Please assist cbspsap01(appuser) /app/scripts > cat restart.sh #!/bin/ksh cd /app/bin date >>logfile.out echo "Restart has been started....." >>logfile.out date >>logfile.out initfnsw -y restart... (3 Replies)
Discussion started by: samsungsamsung
3 Replies

6. UNIX for Dummies Questions & Answers

logrotate and cron.daily/weekly

Hi guys, I've got two separate logrotates I'd like to run, one for Tomcat and one for Apache, but I'd like to run the Tomcat one daily and the Apache one weekly. Now, the logrotate itself is working fine, but although I have 'daily' in Tomcat, and 'weekly' in the Apache one, the latter is... (2 Replies)
Discussion started by: jimbob01
2 Replies

7. Shell Programming and Scripting

cron to get executed on 2nd and 4th saturday of every month

Hi , i need to reboot a server during 2nd and 4th saturday every month. i have come up with the below cron 30 17 8-14 * * if ; then /rebootscript; fi # to reboot every second saturday 30 17 22-28 * * if ; then /rebootscript; fi # to reboot every fourth saturday I am wondering why it... (3 Replies)
Discussion started by: chidori
3 Replies

8. UNIX for Dummies Questions & Answers

Cron job executed at wrong time

Dear *nix users. I'm on Mac OS 10.6 / Terminal and try to use crontab to schedule two scripts every 30 minutes and every 41 minutes. I followed the man instructions and created / installed a crontab file for the current user:crontab -e with the following content */30 * * * *... (4 Replies)
Discussion started by: moxnos
4 Replies

9. Shell Programming and Scripting

Script executed by Cron or commandline

Hello all, I have a question regarding the difference betwen cron and command line. What I would like to do is to print a statement into a logfile if a script has been executed from cron or from command line. It should be as: #!/bin/bash if <Check if this script has been... (3 Replies)
Discussion started by: API
3 Replies

10. Shell Programming and Scripting

Run script no more than twice daily WITHOUT cron

Can I run a script no more than twice a day without using cron? Maybe create a file when script is first run and check its date? (7 Replies)
Discussion started by: drew77
7 Replies
FascistCheck(3) 					      Debian GNU/Linux manual						   FascistCheck(3)

NAME
FascistCheck - a pro-active password checker library SYNOPSIS
#include <crack.h> static char const CRACKLIB_DICTPATH[] = ...; extern char const * FascistCheck(char const passwd[], char const dictpath[]); DESCRIPTION
cracklib is a library containing the FascistCheck C function which may be used in a "passwd" like program. The idea is simple: try to pre- vent users from choosing passwords that could be guessed by "crack" by filtering them out, at source. cracklib is an offshoot of the the version 5 of the "crack" software and contains a considerable number of ideas nicked from the new software. The first formal argument password is the potential password. The second formal argument dictpath is the full path name + filename prefix of the cracklib dictionary database. FascistCheck returns the NULL pointer for a good password, or a pointer to a diagnostic string if it is a weak password. The database is in a binary format generated by the utilities crack_mkdict(8) and crack_packer(8). On a Debian system the database is located in the directory defined by the static constant CRACKLIB_DICTPATH and is set to /var/cache/cracklib/cracklib_dict. None of the subroutines in the cracklib libraries have this location hard-coded into their implementations. It is generated daily with the program /etc/cron.daily/cracklib. FILES
/var/cache/cracklib/cracklib_dict.[hwm|pwd|pwi] cracklib dictionary database files used by utilities. /etc/cron.daily/cracklib cracklib daily cron program to rebuild the cracklib dictionary database. /etc/cracklib/cracklib.conf cracklib configuration file used by the cracklib daily cron program to rebuild the cracklib dictionary database. /usr/sbin/crack_mkdict cracklib shell script to create initial list of words for dictionary database. /usr/share/doc/cracklib2-dev/examples Example cc(1) source files that show how FascistCheck is used. SEE ALSO
crack_teststr(8), crack_mkdict(8), update-cracklib(8) /usr/share/doc/cracklib2-dev/examples /usr/share/doc/cracklib2/cracklib2.html /usr/share/doc/cracklib2-dev/cracklib2-dev.html AUTHOR
cracklib2 is written by Alec Muffett <alecm@crypto.dircon.co.uk>. Manual added by Jean Pierre LeJacq <jplejacq@quoininc.com>. 2.7-8.5 Wed, 3 Oct 2001 01:37:09 +0100 FascistCheck(3)
All times are GMT -4. The time now is 06:02 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy