Solved

File systems: Journaling  and Error Correction (general)

Posted on 2016-08-08
3
78 Views
Last Modified: 2016-08-09
I am making my first array into the world of Linux and I have two questions which I believe is also inherent to a number of other operating systems. In my Linux book there is a short passage about fault-resilience and error correction and as the passage was very short, I looked did some online research which confused me even more.

My fist question is about the journaling

I understand that there are two methods of journaling: logical and physical and only the latter provides for full system recovery.

How can a logical/meta-data only journaling support system recovery? Is it like the system logs in Windows which informs the user which device or software has caused an error? Then it's up to the user to decide how to proceed?

On Wikipedia I read that "After a crash, recovery involves reading the journal from the file system and replaying changes from this journal until the file system is consistent again. " I assume this applies to the physical logging only?

My last question is about error checking:

Every time a user saves a file, a check value is stored alongside (or inside?) the file. Is this called the check value also known as the check sum? The same process is done when the file is opened. If the values don't match, then there was an error.  Is this done with a function known as Cyclic Redundancy Check? Or am I mixing things up?

Thank you for your help.
0
Comment
Question by:mscola
3 Comments
 
LVL 34

Accepted Solution

by:
Gary Patterson earned 350 total points
ID: 41747817
Journaling file systems write a log of uncommitted file system changes to a persistent store, and buffer them there until all of the file system updates complete. If the system crashes, the uncommitted journaled changes can be replayed into the file system, and lost file system changes recovered.

Writing to a journal is a fast, sequential write to disk, and can be done very quickly and efficiently.

Here's an article that explains journaling file systems in Linux in detail:

http://www.ibm.com/developerworks/library/l-journaling-filesystems/

And here is one that explains physical vs logical journaling:

http://www.ibm.com/developerworks/library/l-fs7/

CRC / checksum

A CRC is a checksum - it is just one particular checksum algorithm.  There are many others.  

CRC checking is done at the physical layer (disk sector), and may also be implemented at the file system level, and again at the application layer.  In most file systems, I'd imagine file checksums are  stored in the directory of the file system, or a similar internal file system table.

Application level checksums can be stored in the file itself, or in another file or a database.
0
 
LVL 88

Assisted Solution

by:rindi
rindi earned 150 total points
ID: 41747889
No, it isn't like the Windows system logs. It is more like what NTFS does, which is also a journaling file-system. If there is file-system corruption in NTFS you can run chkdsk with repair options which will repair those corruptions. On Linux it would be fsck which you would run to repair a corrupt file-system.

With BTRFS you get a file-system which is similar to Solaris' ZFS. It does snapshots, which means you can for example you can go back to a previous version if some installation botched something up. But it needs more management, for example your disk can fill up without you noticing. You need to prune old snapshots, and currently there are no reliable GUI tools for that.
0
 

Author Closing Comment

by:mscola
ID: 41749373
Brilliant! Thanks for your help!
0

Featured Post

Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PHP Apache application gives "Forbidden" message 5 45
Debug VNC connection on CentOS7 server 22 70
High Available Storage based on linux 6 70
wipe a usb using python 5 30
Linux users are sometimes dumbfounded by the severe lack of documentation on a topic. Sometimes, the documentation is copious, but other times, you end up with some obscure "it varies depending on your distribution" over and over when searching for …
It’s 2016. Password authentication should be dead — or at least close to dying. But, unfortunately, it has not traversed Quagga stage yet. Using password authentication is like laundering hotel guest linens with a washboard — it’s Passé.
This is used to tweak the memory usage for your computer, it is used for servers more so than workstations but just be careful editing registry settings as it may cause irreversible results. I hold no responsibility for anything you do to the regist…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

861 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

26 Experts available now in Live!

Get 1:1 Help Now