-
Notifications
You must be signed in to change notification settings - Fork 49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Which are the commands used when creating the wb cache for disk partitions ? #122
Comments
@Augusto7743 This is a very tricky process and one of the main reasons why I was hesitant on implementing a writeback cache in RAM. I assume that you went through the notes by @matteotenca here: #86. Can you please provide more details on the events or actions that led you to this corruption? Maybe also distro/version/kernel. |
Thanks very much for your reply. I had posted I have used your amazing Rapiddisk using wb in /root , /home and /opt since when feature wb was added in RapidDisk. You adding writeback in Rapiddisk is an bless for average and beginner Linux users. I had accessed information in The problem happen when done partial flush to block device. [ BTRFS documentation ] Parent transid verify failed" is the result of a failed internal consistency check of the filesystem's metadataI have started the OS and running for 1 hour and 20 minutes. sudo btrfs check --readonly --force --mode original --progress /dev/sda4 The cache was used 100 % (256 MB) and was done an little partial written in BTRFS partition /home. Not user data being written in /home. sudo /usr/sbin/dmsetup message /dev/mapper/rc-wb_sda4 0 flush sudo btrfs check --readonly --force --mode original --progress /dev/sda5 The cache was used 100 % ( 8 MB) and was done an little partial written in BTRFS partition /opt wb cache for /opt is only 8 MB for test because /opt is few used for written. Only few files of less 1 MB are written in /opt. The 3 fs are being mounted in fstab using If is possible configure when creating the wb caches an option when the cache is full doing partial written to also flush metadata is possible avoid the problem above. If have options to configure updating metadata in partial flush in dm-writeback cache is good to test it and see if the problem happen again. BTRFS does several complex tasks in disk, but unhappily when the fs is damaged not is possible use tools to fix. I only need understand if have any command or configuration to optimize flushing metada. Having need test before to contact btrfs devs. |
OK. Based on what I am reading, I think this is more related to #62 and the ability to configure the dm-writeback parameters. |
@Augusto7743 @pkoutoupis I suggest Augusto to try the approach I tried to detail here (link to the specific message): This is the only way I found to avoid filesystem corruptions while using write back mode on the main root volume upon shutdown. Regards |
@matteotenca @pkoutoupis |
Hello Petros Koutoupis. All right with you ?
Users need know Rapiddisk.
I have been using more than one year and works very good. Amazing tool.
The only problem is when doing writeback in an BTRFS disk not being related with Rapiddisk.
When cache is full is done an flush in the disk, but in sometimes is an partial written.
That action can damage an BTRFS partition with the error "parent transid verify failed"
"Parent transid verify failed" is the result of a failed internal consistency check of the filesystem's metadata"
Unhappily few times is possible fix it. File system was damaged.
"On-disk metadata is committed every time a FLUSH or FUA bio is written. If no such requests are made then commits will occur every second. This means the cache behaves like a physical disk that has a volatile write cache. If power is lost you may lose some recent writes. The metadata should always be consistent in spite of any crash."
When Rapiddisk create the wb caches which are the commands used when creating the dm-writeback for disk partitions ?
If are several commands not need reply with commands about it. The commands are documented ?
Only trying understand if is possible some configuration to avoid the problem above or if is problem when using dm-writecache module in an BTRFS partition and after sharing any information useful.
Have an good day.
The text was updated successfully, but these errors were encountered: