Comments (5)
Further details on this, it would appear that both ZOL and FBSD relies on that uio
is not yet updated by the time we call update_pages()
. But in OS X, the uio
has already been depleted by the call to dmu_write_uio_dbuf()
. Since the num_ivecs is now 0, uio_update() no longer moves offset
along as expected. (And all calls that rely on it, including uiomove()
)
Possibly a more correct solution is to put these lines near the top of zfs_write()
struct uio *uio_copy = NULL;
if ( vn_has_cached_data(vp) )
uio_copy = uio_duplicate(uio);
So that if we know we will call update_pages()
(vn_has_cached_data is a test for z_is_mmapped
) then make a copy of the uio
before we start.
Use uio_copy
in the call to update_pages()
(as well as call uio_free()
). This makes everything work the same as above without manual calls to uio_setoffset()
to fix the offset.
As above, we still die later in the mismatched data check.
from zfs.
So at the moment, we make a uio copy.
another option is to change update_pages()
to be like ZFS wants it, where we pass offset and len.
Either way is fine by me.
from zfs.
Very nice analysis. Although I am not sure I got the whole story, I think the current approach is fine. Adjusting update_pages() is something we can still do if it may reduce the overall set of changes or makes things simpler by some other way.
from zfs.
@lundman I guess we can safely close this issue by now?
from zfs.
fixed by now
from zfs.
Related Issues (20)
- diskutil erase ZFS shows -69832: file system formatter failed HOT 1
- Error "no pools available to import" in Big Sur x86_64
- Unexpectedly low performance of VMs with openzfsonosx backing store HOT 2
- Xcode not happy with ZFS HOT 14
- Photos cannot import photos to library on zfs HOT 5
- _zfs_findernotify_callback panic HOT 1
- Kernel Panic - OpenZFS 2.1.0 on Apple Silicon HOT 11
- Kernel Panic (Time Out) - OpenZFS 2.1.0 on Apple Silicon HOT 20
- Kernal Panic - 2.1.x arm64 HOT 16
- Kernel Panic: Kernel Data Abort (OpenZFS 2.1.0, M1 Ultra) HOT 15
- how can i create block dev as on linux HOT 1
- 2.1.99: `zsysctl` sets tunable incorrectly HOT 2
- Launchd: no pools available to import HOT 3
- Kernel Panic: OpenZFS 2.1.0 Catalina HOT 1
- System freezes with command: zpool offline
- System restarts with command: zpool export
- System freezes or reboots importing a degraded mirror image HOT 52
- System freezes on import HOT 1
- Mac ZFS triggers duplicating finding programs to fail randomly HOT 9
- `cargo build` breaks with "resource temporarily unavailable (error 35)" (I'm assuming EAGAIN) on v2.2.0 and v2.2.2 HOT 3
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 zfs.