{"action":"created","issue":{"url":"https://api.github.com/repos/openzfs/openzfs/issues/37","labels_url":"https://api.github.com/repos/openzfs/openzfs/issues/37/labels{/name}","comments_url":"https://api.github.com/repos/openzfs/openzfs/issues/37/comments","events_url":"https://api.github.com/repos/openzfs/openzfs/issues/37/events","html_url":"https://github.com/openzfs/openzfs/pull/37","id":117232071,"number":37,"title":"6370 ZFS send fails to transmit some holes","user":{"login":"ahrens","id":799124,"avatar_url":"https://avatars.githubusercontent.com/u/799124?v=3","gravatar_id":"","url":"https://api.github.com/users/ahrens","html_url":"https://github.com/ahrens","followers_url":"https://api.github.com/users/ahrens/followers","following_url":"https://api.github.com/users/ahrens/following{/other_user}","gists_url":"https://api.github.com/users/ahrens/gists{/gist_id}","starred_url":"https://api.github.com/users/ahrens/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahrens/subscriptions","organizations_url":"https://api.github.com/users/ahrens/orgs","repos_url":"https://api.github.com/users/ahrens/repos","events_url":"https://api.github.com/users/ahrens/events{/privacy}","received_events_url":"https://api.github.com/users/ahrens/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-11-16T22:21:12Z","updated_at":"2015-12-20T22:59:05Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/openzfs/openzfs/pulls/37","html_url":"https://github.com/openzfs/openzfs/pull/37","diff_url":"https://github.com/openzfs/openzfs/pull/37.diff","patch_url":"https://github.com/openzfs/openzfs/pull/37.patch"},"body":"Reviewed by: Matthew Ahrens <mahrens@delphix.com>\r\nReviewed by: Chris Williamson <chris.williamson@delphix.com>\r\n\r\nIn certain circumstances, \"zfs send -i\" (incremental send) can produce a\r\nstream which will result in incorrect sparse file contents on the\r\ntarget.\r\n\r\nThe problem manifests as regions of the received file that should be\r\nsparse (and read a zero-filled) actually contain data from a file that\r\nwas deleted (and which happened to share this file's object ID).\r\n\r\nNote: this can happen only with filesystems (not zvols, because they do\r\nnot free (or reuse) object IDs).\r\n\r\nNote: This can happen only if, since the incremental source (FromSnap),\r\na file was deleted and then another file was created, and the new file\r\nis sparse (i.e. has areas that were never written to and should be\r\nimplicitly zero-filled).\r\n\r\nWe suspect that this was introduced by 4370 (applies only if hole_birth\r\nfeature is enabled), and made worse by 5243 (applies if hole_birth\r\nfeature is disabled, and we never send any holes).\r\n\r\nThe bug is caused by the hole birth feature. When an object is deleted\r\nand replaced, all the holes in the object have birth time zero. However,\r\nzfs send cannot tell that the holes are new since the file was replaced,\r\nso it doesn't send them in an incremental. As a result, you can end up\r\nwith invalid data when you receive incremental send streams. As a\r\nshort-term fix, we can always send holes with birth time 0 (unless it's\r\na zvol or a dataset where we can guarantee that no objects have been\r\nreused)."},"comment":{"url":"https://api.github.com/repos/openzfs/openzfs/issues/comments/166161797","html_url":"https://github.com/openzfs/openzfs/pull/37#issuecomment-166161797","issue_url":"https://api.github.com/repos/openzfs/openzfs/issues/37","id":166161797,"user":{"login":"ahrens","id":799124,"avatar_url":"https://avatars.githubusercontent.com/u/799124?v=3","gravatar_id":"","url":"https://api.github.com/users/ahrens","html_url":"https://github.com/ahrens","followers_url":"https://api.github.com/users/ahrens/followers","following_url":"https://api.github.com/users/ahrens/following{/other_user}","gists_url":"https://api.github.com/users/ahrens/gists{/gist_id}","starred_url":"https://api.github.com/users/ahrens/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahrens/subscriptions","organizations_url":"https://api.github.com/users/ahrens/orgs","repos_url":"https://api.github.com/users/ahrens/repos","events_url":"https://api.github.com/users/ahrens/events{/privacy}","received_events_url":"https://api.github.com/users/ahrens/received_events","type":"User","site_admin":false},"created_at":"2015-12-20T22:59:05Z","updated_at":"2015-12-20T22:59:05Z","body":"@Ringdingcoder Can you provide details on the problem you're seeing?  Can you give us steps to reproduce the problem?  Either commands to run starting from \"zfs create ...\", or a series of send streams or the metadata from the send streams, i.e. the output from \"zfs send ... | zstreamdump -v\"."}}