cancel
Showing results for 
Search instead for 
Did you mean: 
  • 1,807 Views

what is the impact of deleting /etc/rc.d and /etc/rc0.d folders in RHEL6?

Hi There,

I have accidentally deleted /etc/rc.d and /etc/rc0.d folders which resulted deletion of init.d and other related folders.

1.What is the use of /etc/rc.d, rc, rc.d, rc0.d, rc1.d, rc2.d.......rc6.d and other files inside /etc/rc.d?

2.If we accidentally delete them how to recover?

3.If we have the same files in other server can we copy and get the situation to normal? (I have one)

(but these servers do not have connectivity)

4. can we preserve all the properties of rc.d folders and try placing them (already tried but softlinks were missing)

4.Suggest any possible way to minimize the impact or totally resolve this situation.

Please PLEASE HELPP!! This an emergency!!!

OS DETAILS here

Linux version 2.6.32-642.11.1.el6.x86_64 (mockbuild@x86-027.build.eng.bos.redhat.com) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-17) (GCC) ) SMP Wed Oct 26 10:25:23 EDT 2016

Million Thanks in advance!!

0 Kudos
1 Reply
JS_Learning
Moderator
Moderator
  • 1,745 Views

Hi,

1. /etc/rc.d contains the scripts that control the services, run at boot time (in various boot run levels or stages, 0 to 6).

2. Ouch, I guess the accident could have been prevented by not having root full access (that's why it can be dangerous and/or powerfull to run commands as root). Also a backup would have been important. Now that the harm is done, I wonder if reinstalling the package initscripts would recreate some of these files...

3. I guess if it's an identical server, then copying these files over could help with that ugly situation.

4. I guess if you use "cp -p " to preserve?

5. Minimize the impact will be difficult because it's a quite bad action... Again, we would be talking about a backup restore.

There is this information to help you:

https://access.redhat.com/solutions/3090251

It will take you to install the initscripts package and recreate some files.

Cheers,

 

0 Kudos
Join the discussion
You must log in to join this conversation.