Linux - NewbieThis 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
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
What editor did you use?
Many of them make backups
automagically.
Try
ls -A
and see if a file named very similarly to modules.conf exists
Edit:
For the future always make a back up of system
files before you change them. That way if you
completely trash your system you just need to
pop in a recovery disk and copy the backups to
the appropriate place.
Distribution: Red Hat, openBSD,Mandrake,freeBSD,SunOS
Posts: 168
Rep:
When I first started using Linux I did a rm -rf ~ by accident.....how did I do that by accident, I don't know. I was a stupid newbie. I found out that there are two ways to get the information back. 1. Using the tool mc or midnight commander you can try to piece the files together from your hard-drive if the space that they once occupied has not been written over by the creation of new files. This is extremely difficult and will take hours and hours of frustration and you might not get anything out of it. 2. You could send your hard-drive off to a company that specializes in data recovery and spend thousands upon thousands of dollars to retrieve the lost files.
As number 2 is out, unless of course you are some sort of millionaire who likes to waste money. Then you are left with number 1. You could try it, but speaking as someone who tried this once. Just forget about it. It is not worth your time. Sorry, it sucks I know. I am sure there is someone on this forum who can recover lost files, but it is not something that is easily taught in a few lines on a web pagte. They would no doubt have to be sitting right there with you and even then there is no guarantee that they will be able to recover the files.
i used vi. and i solved the problem in other way --- get a same config file from internet and edited to mine. stupid but rapid way for me. thank you for your advice. i really got this lesson.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.