Comments (4)
Hi @schellingb,
fsremap has no support to specify bad sectors, sorry.
Adding support for such a feature would be relatively straightforward,
but it would require fsremap to know the bad blocks list at start or soon after starting;
changing a (ipotetical) bad block list while running would break support for resuming an unfinished job.
Alternatively, you could hack io/io_posix.cc flush_copy_bytes() to ignore any read request (and maybe also any write request) in a certain range of the device - but this may cause a lot of missing data if part of that range happens to be used as "primary storage" (a kind of persistent buffer) by fsremap.
from fstransform.
I used dd to read around that area into /dev/null and figured a range of about 100mb that have bad blocks in it. Before and after that range dd was able to read quite large amounts of data with no issues.
I'll try to add some kind of --skip-range=a-b option in flush_copy_bytes and see how that treats me. Should be fun :-)
Thanks for the really quick response!
from fstransform.
If the disk is not too badly damaged, I found by experience that writing zeroes with dd
into the bad blocks often makes them readable and writeable again (after destroying whatever data was there), so that the disk can be used for a while more. It could be worth a try.
from fstransform.
I tried writing zeroes over the bad areas but it did not seem to resolve the read errors for me.
Here's the hack I am running for now:
err = ff_log(FC_ERROR, err, "I/O error while copying " CURRENT_OP_FMT, CURRENT_OP_ARGS);
if (read_dev && dev_offset >= 1166647304ULL*512ULL - length*5 && dev_offset <= 1166710592ULL*512ULL + length*5)
{
ff_log(FC_ERROR, 0, " Ignoring this read error due to being known bad sector");
err = 0;
}
else break;
And so far only one error happened:
progress: 19.6% done, 1.4 terabytes still to remap
ERROR: I/O error while copying from device to RAM, read({fd = 5, offset = 597347381248}, address + 363536384, length = 552960): Input/output error
ERROR: Ignoring this error due to being known bad sector
I'll close this issue for now. Now that I'm not afraid of code modifications I should find my way out of this one way or another :-)
Thanks again for the hints and infos!
from fstransform.
Related Issues (20)
- Adding ftype=1 to an xfs partition HOT 8
- Is zfs supported in any way? HOT 2
- F2FS support? HOT 2
- integrate fstransform into busybox? HOT 2
- src/arch/mem_linux.cc:70: off by one error ? HOT 1
- NTFS3 support (Now that kernel version 5.15 contain new NTFS driver?) HOT 3
- Can't grok which on EL9 HOT 2
- Conversion failed with fsmove error HOT 47
- GPL2-only → GPL2 or later HOT 2
- 'dd' failure at launch of fstransform HOT 2
- Error unmounting before disk check - how to proceed? HOT 1
- NTFS > XFS/F2FS No Such Device error HOT 2
- Converting XFS RAID5 to EXT4 HOT 3
- Can I convert 33T logical partitions? HOT 2
- Unknown code er3k 127 - After transforming reiserfs to ext3 - Fix included
- Unmount failed... but had no reason to do so
- Transforming reiserfs can lead to "kernel BUG at fs/reiserfs/journal.c:3039!" or "unable to handle page fault for address" HOT 1
- xfs -> ext4 conversion does not transfer SELinux contexts HOT 3
- Suggest warning added to --resume-job not to use loop file as argument
- Convert from btrfs to xfs: lseek error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fstransform.