LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices



Reply
 
Search this Thread
Old 12-28-2005, 08:12 AM   #1
merana
Member
 
Registered: May 2002
Location: Philly/So. Jersey
Distribution: ESXi CentOS Red-Hat Ubuntuu Solaris Debian
Posts: 80

Rep: Reputation: 15
run-parts not reading all possible scripts


Hi All,

I've got a couple of weird occurances I'd like some suggestions on.

I'm adding some scripts for daily backups into /etc/cron.daily. On our older testing box, run-parts would follow sym-links so all I had to do was link the file into cron.daily and it ran fine. On the new box (stable with testing pinned) it wouldn't follow the symlink so I decided to just check it out directly from svn into the cron.daily directory.

So now I have the actual script in the cron.daily directory. I do a run-parts --test and the files don't show up...

I checked the versions on the run-parts between the older box and the newer box and they are as follows:

Older:
Debian run-parts program, version 2.13.2
Copyright (C) 1994 Ian Jackson, Copyright (C) 1996 Jeff Noxon.
Copyright (C) 1996,1997,1998,1999 Guy Maor
Copyright (C) 2002, 2003, 2004, 2005 Clint Adams
This is free software; see the GNU General Public License version 2
or later for copying conditions. There is NO warranty.

Newer:
Debian run-parts program, version 2.15.2
Copyright (C) 1994 Ian Jackson, Copyright (C) 1996 Jeff Noxon.
Copyright (C) 1996,1997,1998,1999 Guy Maor
Copyright (C) 2002, 2003, 2004, 2005 Clint Adams
This is free software; see the GNU General Public License version 2
or later for copying conditions. There is NO warranty.

The /etc/cron.daily directory on the new box ls' like this:

Code:
total 64K
-rwxr-xr-x  1 root root 1.9K 2005-12-28 06:57 backupRTDB.sh
-rwxr-xr-x  1 root root 2.0K 2005-12-28 07:00 backupTWDB.sh
-rwxr-xr-x  1 root root 1.8K 2005-12-28 07:02 backupTWsite.sh
-rwxr-xr-x  1 root root  502 2004-11-01 14:29 bsdmainutils
-rwxr-xr-x  1 root root  814 2005-05-27 04:10 exim4-base
-rwxr-xr-x  1 root root  419 2005-03-20 04:48 find
-rwxr-xr-x  1 root root   89 2005-05-25 05:49 logrotate
-rwxr-xr-x  1 root root  946 2005-01-05 11:30 man-db
-rwxr-xr-x  1 root root   86 2004-12-19 05:40 modutils
-rwxr-xr-x  1 root root 1.3K 2005-11-21 19:42 mysql-server
-rwxr-xr-x  1 root root  495 2004-10-24 12:28 netkit-inetd
-rwxr-xr-x  1 root root 1.1K 2005-08-26 06:30 ntp-server
-rw-r--r--  1 root root  102 2004-07-28 16:44 .placeholder
-rwxr-xr-x  1 root root 2.6K 2004-07-28 16:44 standard
drwxr-xr-x  7 root root 4.0K 2005-12-28 07:02 .svn
-rwxr-xr-x  1 root root 1.3K 2005-05-25 14:21 sysklogd
When I do the run-parts --test I get this:

Code:
# run-parts --test /etc/cron.daily
/etc/cron.daily/bsdmainutils
/etc/cron.daily/exim4-base
/etc/cron.daily/find
/etc/cron.daily/logrotate
/etc/cron.daily/man-db
/etc/cron.daily/modutils
/etc/cron.daily/mysql-server
/etc/cron.daily/netkit-inetd
/etc/cron.daily/ntp-server
/etc/cron.daily/standard
/etc/cron.daily/sysklogd
What am I missing here?

Suggestions and pointers greatly appreciated.
 
Old 12-28-2005, 09:06 AM   #2
Artanicus
Member
 
Registered: Jan 2005
Location: Finland
Distribution: Ubuntu, Debian, Gentoo, Slackware
Posts: 827

Rep: Reputation: 31
the only common thing I can see that tyhr misssing ones are postfixed with .sh ... it shouldnt matter, but what if you remove the extension? Might work..
 
Old 12-28-2005, 09:12 AM   #3
merana
Member
 
Registered: May 2002
Location: Philly/So. Jersey
Distribution: ESXi CentOS Red-Hat Ubuntuu Solaris Debian
Posts: 80

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Artanicus
the only common thing I can see that tyhr misssing ones are postfixed with .sh ... it shouldnt matter, but what if you remove the extension? Might work..
Son of a gun! That was it!!! It didn't like the extension!

Damn! Thanks for the other set of eyes on that Artanicus!
 
Old 12-28-2005, 09:19 AM   #4
Artanicus
Member
 
Registered: Jan 2005
Location: Finland
Distribution: Ubuntu, Debian, Gentoo, Slackware
Posts: 827

Rep: Reputation: 31
no problem.. Very odd a problem indeed.. I have no idea why it doesn't like the .sh extension.. Maybe theyre trying to prevent running scripts tho I cant see why they would do that..
 
Old 12-28-2005, 09:21 AM   #5
Artanicus
Member
 
Registered: Jan 2005
Location: Finland
Distribution: Ubuntu, Debian, Gentoo, Slackware
Posts: 827

Rep: Reputation: 31
I think this explains alot:
Quote:
Filenames that end in .dpkg-old or .dpkg-dist, or do not match naming conventions that the LSB specifies for /etc/cron.daily scripts, will be skipped. Subdirectories of directory will be silently ignored.
 
Old 12-28-2005, 10:06 AM   #6
merana
Member
 
Registered: May 2002
Location: Philly/So. Jersey
Distribution: ESXi CentOS Red-Hat Ubuntuu Solaris Debian
Posts: 80

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by Artanicus
I think this explains alot:
Kiitos Artaniucus! I'll have to see what the LSB definition is for the file names in that directory. And "onnellista uutta vuotta" in advance!

{Yes I used to work with a lot of Finns mainly from Helsinki and Turku (Masa Yards) and I even worked with some up in your area when I used to be with the larger Kvaerner Group... Must be damn cold there now...}

wbrgs,

MichaelE
 
Old 12-28-2005, 10:40 AM   #7
Artanicus
Member
 
Registered: Jan 2005
Location: Finland
Distribution: Ubuntu, Debian, Gentoo, Slackware
Posts: 827

Rep: Reputation: 31
Quote:
Originally Posted by merana
Kiitos Artaniucus! I'll have to see what the LSB definition is for the file names in that directory. And "onnellista uutta vuotta" in advance!

{Yes I used to work with a lot of Finns mainly from Helsinki and Turku (Masa Yards) and I even worked with some up in your area when I used to be with the larger Kvaerner Group... Must be damn cold there now...}

wbrgs,

MichaelE

hehe.. Yeah, it is.. Havn't been out in nearly a week cause its so damn cold.. Alot nicer inside with mi laptop.. (:

A happy new year to you too.. (:
 
  


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
run-parts gives error on bash script ChoKamir Programming 7 08-18-2014 07:31 AM
What does the run-parts mean in crontab? mTorbin Linux - Newbie 15 04-27-2012 04:53 PM
crontab and run-parts gavinbeatty Slackware 4 09-13-2005 07:56 PM
new scripts won't run new2me Linux - Newbie 4 06-09-2005 10:14 AM
reading cd's and location of init scripts TheOneAndOnlySM Slackware 1 10-13-2003 08:18 AM


All times are GMT -5. The time now is 02: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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration