{"id":106149,"date":"2022-12-18T21:36:39","date_gmt":"2022-12-18T19:36:39","guid":{"rendered":"https:\/\/prohoster.info\/blog\/novosti-interneta\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs"},"modified":"2022-12-18T21:36:39","modified_gmt":"2022-12-18T19:36:39","slug":"v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs","status":"publish","type":"post","link":"https:\/\/prohoster.info\/da\/blog\/news\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs","title":{"rendered":"Forbedringer af RAID5\/6 i Btrfs vil blive inkluderet i Linux-kernen 6.2","gt_translate_keys":[{"key":"rendered","format":"text"}]},"content":{"rendered":"<p>For the Linux kernel 6.2, improvements to Btrfs have been proposed regarding fixing the 'write hole' issue in RAID 5\/6 implementations. The essence of the problem is that if a crash occurs during a write operation, it is initially impossible to determine which block on which of the RAID devices was written correctly and which one was not finished. In the event of a RAID recovery attempt in such a situation, corruption of the blocks corresponding to the unwritten blocks may occur, as the state of the RAID blocks becomes desynchronized. This problem arises in any RAID1\/5\/6 arrays where no special measures are taken to combat such effects.    <\/p>\n<p>In implementations of RAID-like RAID1 in btrfs, this problem is resolved by using checksums in both copies; in case of a mismatch, data is simply restored from the second copy. This approach also works if any device starts returning incorrect data instead of a complete failure.    <\/p>\n<p>However, in the case of RAID5\/6, the filesystem does not store checksums for parity blocks: under normal circumstances, the correctness of blocks is verified by the fact that they all have checksums, and the parity block can be recreated from the data. However, in the case of a partial write, this approach may not work in certain situations. In this case, during the restoration of the array, it is possible that blocks involved in the incomplete write may be restored incorrectly.    <\/p>\n<p>I tilf\u00e6lde af btrfs er dette problem mest relevant, hvis den producerede skrivning er mindre end striben. I dette tilf\u00e6lde skal filsystemet udf\u00f8re en l\u00e6se-modificer-skriv (read-modify-write, RMW) operation. Hvis der st\u00f8der p\u00e5 blokke med en ufuldst\u00e6ndig skrivning, kan en s\u00e5dan RMW-operation for\u00e5rsage \u00f8del\u00e6ggelser, der ikke vil blive opdaget, uanset checksummere. Udviklerne har indf\u00f8rt \u00e6ndringer, hvor RMW-operationen kontrollerer checksummen af blokke, f\u00f8r der udf\u00f8res denne operation, og efter behov udf\u00f8rer de ogs\u00e5 checksum-kontroller efter skrivning i tilf\u00e6lde af datagendannelse. Desv\u00e6rre medf\u00f8rer det i situationen med en ufuldst\u00e6ndig stribe (RMW) ekstra overhead til beregning af checksummere, men det \u00f8ger betydeligt p\u00e5lideligheden. For RAID6 er denne logik endnu ikke klar, men en s\u00e5dan fejl i RAID6 kr\u00e6ver, at skrivningen mislykkes p\u00e5 to enheder samtidig, hvilket er mindre sandsynligt.    <\/p>\n<p>Additionally, it is worth noting the recommendations from the developers regarding the use of RAID5\/6, which state that in Btrfs, the storage profiles for metadata and data can differ. It is possible to use a RAID1 (mirror) or even RAID1C3 (3 copies) profile for metadata, while using RAID5 or RAID6 for data. This ensures reliable protection of metadata and the absence of the 'write hole' on one hand, while on the other, enables more efficient space utilization typical for RAID5\/6. This allows for the avoidance of corruption in metadata, and any data corruption can be corrected.    <\/p>\n<p>It should also be noted that for SSDs in Btrfs, in kernel 6.2, the asynchronous execution of the 'discard' operation (marking freed blocks that can no longer be physically stored) will be enabled by default. The advantage of this mode is high performance due to efficient grouping of 'discard' operations in a queue and subsequent processing of the queue by a background handler, which does not slow down normal filesystem operations as is the case with synchronous 'discard' during block freeing, allowing SSDs to make better decisions. Moreover, there will no longer be a need to use utilities like fstrim, as all available blocks will be cleared in the filesystem without the necessity for additional scanning and without slowing down operations.<br \/>\n<br \/>Kilde: <a content=\"nofollow\" rel=\"nofollow\" href=\"https:\/\/www.opennet.ru\/opennews\/art.shtml?num=58352\">opennet.ru<\/a> <\/p>","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"excerpt":{"rendered":"<p>\u0414\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u044f\u0434\u0440\u043e Linux 6.2 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u044b \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f Btrfs, \u043a\u0430\u0441\u0430\u044e\u0449\u0438\u0435\u0441\u044f \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b &#171;write hole&#187; \u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 RAID 5\/6. \u0421\u0443\u0442\u044c \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b \u0441\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u043a \u0442\u043e\u043c\u0443, \u0447\u0442\u043e \u0435\u0441\u043b\u0438 \u043a\u0440\u0430\u0445 \u0441\u043b\u0443\u0447\u0438\u043b\u0441\u044f \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u0437\u0430\u043f\u0438\u0441\u0438, \u0438\u0437\u043d\u0430\u0447\u0430\u043b\u044c\u043d\u043e \u043d\u0435\u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e \u043f\u043e\u043d\u044f\u0442\u044c \u043a\u0430\u043a\u043e\u0439 \u0431\u043b\u043e\u043a \u043d\u0430 \u043a\u0430\u043a\u043e\u043c \u0438\u0437 \u0443\u0441\u0442\u0440\u043e\u0439\u0441\u0442\u0432 RAID \u0437\u0430\u043f\u0438\u0441\u0430\u043b\u0441\u044f \u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e, \u0430 \u0432 \u043a\u0430\u043a\u043e\u043c \u0437\u0430\u043f\u0438\u0441\u044c \u043d\u0435 \u0431\u044b\u043b\u0430 \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0430. \u0412 \u0441\u043b\u0443\u0447\u0430\u0435 \u043f\u043e\u043f\u044b\u0442\u043a\u0438 \u0432\u043e\u0441\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u044f RAID \u0432 \u043f\u043e\u0434\u043e\u0431\u043d\u043e\u0439 [&hellip;]<\/p>\n","protected":false,"gt_translate_keys":[{"key":"rendered","format":"html"}]},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[702],"tags":[],"class_list":["post-106149","post","type-post","status-publish","format-standard","hentry","category-news"],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.3 - aioseo.com -->\n\t<meta name=\"description\" content=\"\u0414\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u044f\u0434\u0440\u043e Linux 6.2 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u044b \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f Btrfs, \u043a\u0430\u0441\u0430\u044e\u0449\u0438\u0435\u0441\u044f \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b &quot;write hole&quot; \u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 RAID 5\/6.\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"Yuri Gagarin\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/prohoster.info\/da\/blog\/news\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs\" \/>\n\t\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.3\" \/>\n\t\t<meta property=\"og:locale\" content=\"da_DK\" \/>\n\t\t<meta property=\"og:site_name\" content=\"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"\ud83e\udd47\u0412 \u044f\u0434\u0440\u043e Linux 6.2 \u0432\u043e\u0439\u0434\u0443\u0442 \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f RAID5\/6 \u0432 Btrfs | ProHoster\" \/>\n\t\t<meta property=\"og:description\" content=\"\u0414\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u044f\u0434\u0440\u043e Linux 6.2 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u044b \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f Btrfs, \u043a\u0430\u0441\u0430\u044e\u0449\u0438\u0435\u0441\u044f \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b &quot;write hole&quot; \u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 RAID 5\/6.\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/prohoster.info\/da\/blog\/news\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs\" \/>\n\t\t<meta property=\"og:image\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:secure_url\" content=\"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg\" \/>\n\t\t<meta property=\"og:image:width\" content=\"350\" \/>\n\t\t<meta property=\"og:image:height\" content=\"350\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2022-12-18T19:36:39+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2022-12-18T19:36:39+00:00\" \/>\n\t\t<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/prohoster\" \/>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"\ud83e\udd47Improvements to RAID5\/6 in Btrfs will be included in Linux kernel 6.2 | ProHoster","description":"For Linux kernel 6.2, improvements to Btrfs have been proposed to address the \"write hole\" issue in RAID 5\/6 implementation.","canonical_url":"https:\/\/prohoster.info\/da\/blog\/news\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":null,"og:locale":"da_DK","og:site_name":"ProHoster | \u041a\u0443\u043f\u0438\u0442\u044c \u043d\u0430\u0434\u0435\u0436\u043d\u044b\u0439 \u0445\u043e\u0441\u0442\u0438\u043d\u0433 \u0434\u043b\u044f \u0441\u0430\u0439\u0442\u043e\u0432 \u0441 \u0437\u0430\u0449\u0438\u0442\u043e\u0439 \u043e\u0442 DDoS, VPS VDS \u0441\u0435\u0440\u0432\u0435\u0440\u044b","og:type":"article","og:title":"\ud83e\udd47\u0412 \u044f\u0434\u0440\u043e Linux 6.2 \u0432\u043e\u0439\u0434\u0443\u0442 \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f RAID5\/6 \u0432 Btrfs | ProHoster","og:description":"\u0414\u043b\u044f \u0432\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u044f \u044f\u0434\u0440\u043e Linux 6.2 \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u044b \u0443\u043b\u0443\u0447\u0448\u0435\u043d\u0438\u044f Btrfs, \u043a\u0430\u0441\u0430\u044e\u0449\u0438\u0435\u0441\u044f \u0438\u0441\u043f\u0440\u0430\u0432\u043b\u0435\u043d\u0438\u044f \u043f\u0440\u043e\u0431\u043b\u0435\u043c\u044b &quot;write hole&quot; \u0432 \u0440\u0435\u0430\u043b\u0438\u0437\u0430\u0446\u0438\u0438 RAID 5\/6.","og:url":"https:\/\/prohoster.info\/da\/blog\/news\/v-yadro-linux-6-2-vojdut-uluchsheniya-raid5-6-v-btrfs","og:image":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:secure_url":"https:\/\/prohoster.info\/wp-content\/uploads\/2021\/11\/logo-350.jpg","og:image:width":350,"og:image:height":350,"article:published_time":"2022-12-18T19:36:39+00:00","article:modified_time":"2022-12-18T19:36:39+00:00","article:publisher":"https:\/\/www.facebook.com\/prohoster","article:author":"https:\/\/www.facebook.com\/prohoster"},"aioseo_meta_data":[],"gt_translate_keys":[{"key":"link","format":"url"}],"_links":{"self":[{"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/posts\/106149","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/comments?post=106149"}],"version-history":[{"count":0,"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/posts\/106149\/revisions"}],"wp:attachment":[{"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/media?parent=106149"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/categories?post=106149"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/prohoster.info\/da\/wp-json\/wp\/v2\/tags?post=106149"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}