LinuxQuestions.org
Register a domain and help support LQ
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 09-02-2005, 11:09 AM   #1
mtoneil
LQ Newbie
 
Registered: Sep 2005
Posts: 1

Rep: Reputation: 0
Restoring files from the trash (cmd line)


I accidentally deleted etc/init.d without realizing it. So the next time I booted up my server (Fedore Core 3), the GUI won't load and it goes to the command line. Obviosuly there are other problems as well (apache can't boot up now, etc).

I found init.d in the root's trash (/root/.Trash/) but I don't know how to restore it from the command line. I tried moving it and copying it (back to /etc/) but neither will work. Is there a command to undelete a file from trash?

If anyone can help ASAP I would greatly appreciate it. Thanks!

P.S. I am logged in as root obviously.
 
Old 09-02-2005, 09:32 PM   #2
cs-cam
Senior Member
 
Registered: May 2004
Location: Australia
Distribution: Gentoo
Posts: 3,544
Blog Entries: 4

Rep: Reputation: 56
For the record, linux doesn't have a Trash/Recycle Bin in the sense that Windows does. That folder is (for GNOME at least), a psuedo-trash folder, it's a perfectly normal directory and requires no special commands to play with

Now to the problem, copying it back should fix the problem. Is the dir structure /root/.Trash/etc/init.d? If so, this *should* work...
Code:
cp /root/.Trash/etc/* /etc/
 
  


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Cmd line bittorrent quesiton Jukas Linux - Software 2 10-27-2005 03:55 PM
cmd line send attachment? jedimastermopar Linux - General 2 06-16-2005 12:51 PM
How to modify sets of filenames on cmd line? Kropotkin Linux - Newbie 8 11-20-2004 06:35 AM
Best distro for cmd-line webserver Seft Linux - Newbie 4 11-15-2003 03:32 AM
booting then to cmd line..... Why not to GUI?? Ax787 Linux - Newbie 1 10-28-2003 10:45 AM


All times are GMT -5. The time now is 10:29 AM.

Main Menu
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