LinuxQuestions.org
Register a domain and help support LQ
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 02-27-2009, 02:02 AM   #1
littleheart
LQ Newbie
 
Registered: Jun 2008
Posts: 4

Rep: Reputation: 0
Removed all the files (System and Config) in fedoracore 7


I have a big problem. Seeking some one to give a solution

We are using squid proxy. We used to clear the cache dumps folder by stop the service and use rm -rf and used squid -z to recreate cache temp folders then start the service

for avoide the stop and start process i have got some script

find . -type f -exec rm -f {} \;

to remove only files in the cache01 , cache_logs folder dump files by moving inside those folder.

yesterday my colligues run this script from / .

So it remove all the files from root and leave all directories empty
including /bin /etc /var all empty.

It remove all system, configuration files. This server is running as a proxy as well as DNS server.

I dont have latest squid.conf backup and named.conf and other zone file's backup.

Now i am not able to login to the server through putty or even direct console.

Due to the running services the proxy and DNS still provide its service from this server.

Is any way to recover all the deleted configuration files and system files.

Its Fedoracore 7.
 
Old 02-27-2009, 03:00 AM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,331
Blog Entries: 55

Rep: Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531Reputation: 3531
Quote:
Originally Posted by littleheart View Post
find . -type f -exec rm -f {} \;
That's a problem waiting to happen. And totally unnecessary. Even with low script-fu anyone can see that it'll run in your current directory instead of 'find /path/to/cache/dir '.

Anyway, this is going to be a bit of a chicken and egg thing. And in more than one way I'm afraid: as long as a process is alive the data it keeps in memory and files it keeps open can be saved. Unfortunately a process being alive and writing logging also means the files logged to will increase in size and gradually occupy storage space that is free or was freed. Unfortunately also: to be able to do something like login, attach storage, copy out data, anything, you need to be able to access the system. And to access the system you need to be able to run system commands. Yes, the ones that got deleted...

So AFAIK the short answer is no. If your backups are good enough I'd start by taking a another machine and build a replacement to switch to.

Last edited by unSpawn; 02-27-2009 at 03:02 AM.
 
  


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
Is base-config package removed from your system with aptitude dist-upgrade? Akhran Debian 6 03-18-2006 08:52 PM
removed files from /etc Spartan552 *BSD 8 11-08-2005 08:16 PM
Files removed from file system during Fedora Core Upgrade gryphonavocatio Linux - General 5 09-21-2005 01:27 PM
system-config-proc removed oscarrines Fedora 0 01-13-2005 04:26 PM
System.map & config files greythorne Slackware 7 05-23-2004 01:34 AM


All times are GMT -5. The time now is 06:32 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