Linux - GeneralThis 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.
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
If power off suddenly, which file system will be safer? Ext3 or reiserfs?
Somebody told me that reiserfs will probably lose files, and ext3 is much safer. Is that true? All my patitions are formated as reiserfs, are they in dangerous?
Both ext3 and reiserfs are so-called journalling file systems. That is, if the system crashes/fails/whatever, they are designed to keep the filesystem in a consistent state.
Issues of data loss with a sudden power loss are somewhat different. Anything that has not been written to the disk will be lost, plain and simple. You could use techniques like synchronous mounting, but you would take a huge performance hit.
I guess the question is: what are you trying to protect against?
Short of a hardware failure, I'm not aware of any case where a sudden power off lost data that wasn't being worked on in the few minutes (or even seconds) immediately before the crash.
In other words, if you save a file on Monday and your computer crashes on Tuesday, you should be fine.
As anecdotal evidence, I use ext3 on my desktop and reiserfs on most of my other machines. You might ask yourself why I use ext3 in that one case. Really, there's no reason. Were I doing it now, I would probably use reiserfs. But I've had that one up for about a year, and am not going to reinstall to switch filesystems.
There's also the IBM-developed XFS in the journaling filesystem arena. Some claim it has better performance. It's less supported by livecds and default distro kernels, from what I hear.
Both filesystems are journaling so they offer some protection.
With that said, i must say that no one is better than a backup.
It is said that reiserfs supports only metadata journaling (i don't know about new versions) while ext3 supports data
journaling too (if mounted with data=journal option).
To explain a lit more, reiserfs says "i am going to write to file foo","i wrote to file foo" while ext3 says "i am going to write
'bar' to file foo","i wrote 'bar' to file foo"
So, in a case of failure ext3 offers better protection than reiserfs but this is a very small possibility.
Both filesystems are very good.
ext3 has the advantage that can be mounted as ext2 (without journaling of course) so you can mount it from almost every box.
reiserfs has the advantage that is very quick with small files and also it saves much space for small files.
Choose whatever you like and you will be happy with it.
As i mentioned before no journaling fs can replace a backup.
If you are worried about data loss on power failure, the safest way to go is always a UPS with a serial port output. You can set up your machine to shut down cleanly in response to UPS power failure events, and the battery backup will give you enough time to do that, without you having to sacrifice filesystem efficiency to protect against such things. They'll also protect against minor power changes too, like surges and flickering power.
These ones all have USB/RS-232 interfaces. That Belkin one, the third one down, runs about $100 and looks pretty adequate just reading the specs. There's also some cheaper ones and some more expensive ones.