LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 05-29-2007, 03:39 PM   #1
Corrado
Member
 
Registered: Aug 2004
Location: Washington
Distribution: RHEL
Posts: 174

Rep: Reputation: 16
rc.local


I had an entry in /etc/rc.local that kicked off a script.

I later found out that when this script failed, at bootup, it hanged the system.

So, I then commented out the entry in rc.local to have it NOT run at startup.

Well, it still appears to be running at startup.

Is there ANY way that rc.local is STILL starting it even with it being commented out?

Chris
 
Old 05-29-2007, 03:52 PM   #2
twantrd
Senior Member
 
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440

Rep: Reputation: 52
No, if you commented out the script in rc.local, it would not start up. Perhaps you have a symlink to that script somewhere else. I would use the comnand 'locate' and do a complete search for that script name.

-twantrd
 
Old 05-29-2007, 04:47 PM   #3
Corrado
Member
 
Registered: Aug 2004
Location: Washington
Distribution: RHEL
Posts: 174

Original Poster
Rep: Reputation: 16
This is a mystery. I do not find any links. The script only stops running when it is removed.
 
Old 05-29-2007, 06:41 PM   #4
twantrd
Senior Member
 
Registered: Nov 2002
Location: CA
Distribution: redhat 7.3
Posts: 1,440

Rep: Reputation: 52
Really? Hmm, that is a mystery then. /etc/rc.local should honor comments (#).

-twantrd
 
Old 05-29-2007, 06:56 PM   #5
slackhack
Senior Member
 
Registered: Jun 2004
Distribution: Arch, Debian, Slack
Posts: 1,016

Rep: Reputation: 47
how did you comment it? can you post the entry?
 
Old 05-30-2007, 03:59 PM   #6
Corrado
Member
 
Registered: Aug 2004
Location: Washington
Distribution: RHEL
Posts: 174

Original Poster
Rep: Reputation: 16
Here is the entry...
Quote:
#/usr/local/update/startupdate.pl 1>/dev/null 2>>/usr/local/update/error.log
It's still starting even with the comment.

Is it possible to be working like...
Quote:
#!/usr/bin/bash
Any suggestions?

Chris
 
Old 05-31-2007, 04:44 PM   #7
Corrado
Member
 
Registered: Aug 2004
Location: Washington
Distribution: RHEL
Posts: 174

Original Poster
Rep: Reputation: 16
Found out what was going on.....

The original entry for the script startup was in

Quote:
/etc/rc.d/rc.local
I made the "#" edit to its symbolic link at

Quote:
/etc/rc.local
After the edit was made the link was broken.

I made the edit with the following..

Quote:
/usr/bin/perl -p -i -e '$var = q(#/usr/local/update/startupdate.pl); s{^/usr/local/update/startupdate.pl} {$var};' /etc/rc.d/rc
.local;
Must have something to do with how Perl substitutes as the reason for the broken link. Any ideas?

Chris
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how can i add a local Folder on local Hard Disk as Yum Repository ?? vahid_p Fedora 4 02-22-2007 10:43 AM
shell script to compare filese b/w local and remote and delete files from local serve dsids Linux - Networking 9 08-23-2006 07:20 AM
Setup local machine to allow lan machines to retrieve its local user mail. Brian1 Linux - Networking 3 03-30-2006 05:04 AM
Local webserver -- How to deny all client install their local web server--Please help b:z Linux - Networking 13 04-16-2005 07:11 PM
Cannot resolve local addresses on local network danielgrenyer Linux - Networking 6 01-14-2004 11:03 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 11:21 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
Open Source Consulting | Domain Registration