Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Btrfsのころしかた(だったもの)

Sponsored · SiteGround - Reliable hosting with speed, security, and support you can count on.
Avatar for naota naota
December 08, 2013

 Btrfsのころしかた(だったもの)

Avatar for naota

naota

December 08, 2013
Tweet

More Decks by naota

Other Decks in Technology

Transcript

  1. 自己紹介 • 青田直大 ( あおた なおひろ ) – @naota344 •

    大阪大学 学生 – 他の学生は進級やばいとか言ってましたが、わたし は余裕でもう卒業研究だけで順調な感じですね • 来年からは慶応 – Tokyo ではたらいてお金がほしい感じ
  2. Linux 3.9 • btrfs: Drop inode if inode root is

    NULL • http://git.kernel.org/cgit/linux/kernel/git/torv alds/linux.git/commit/fs/btrfs?id=6379ef9fb2482a 92b5fe09f927d6ce1f989c0c6d • inode を作りそこねたら死ぬ • 理論上は inode を作りまくって限界までいくと 死ぬ
  3. Linux 3.11 • Btrfs: fix oops caused by the space

    balance and dead roots • http://git.kernel.org/cgit/linux/kernel/git/tor valds/linux.git/commit/fs/btrfs?id=c00869f1ae6a 8fa49802d5e60d843b7051a112ec • space balance しつつ、 snapshot けすと死ぬ
  4. Linux 3.12 • Btrfs: do a full search everytime in

    btrfs_search_old_slot • http://git.kernel.org/cgit/linux/kernel/git/tor valds/linux.git/commit/fs/btrfs?id=d4b4087c43cc 00a196c5be57fac41f41309f1d56 • snapshot aware defrag したら死ぬ
  5. で、いじめてた • さっきのやつを再現しようと VM の btrfs いじ めてた • なかなかうまく再現できない、つらい

    – このままでは LT のねたにならない • なんかおもいな ? 動かないな ? • 電源おとして reboot
  6. やったね !btrfs 直せるよ !! • mount -o recovery <dev> <mount>

    – ( わかってたけど ) だめ • btrfs-zero-log <dev> – これで直ると思ってた
  7. GRUB2 • /etc/grub.d/40_custom #!/bin/sh exec tail -n +3 $0 menuentry

    "SYSTEMRESCUECD" { load_video loopback loop /boot/systemrescuecd.iso linux (loop)/isolinux/rescue64 nomodeset vga=865 docache setkmap=us isoloop=/boot/systemrescuecd.iso initrd (loop)/isolinux/initram.igz }
  8. • System Rescue 起動 • もうこのまま復旧 LT するかー ? •

    まあとりあえず mount ためしてみるか – なぜか mount できた • じゃあ reboot ・・・ • ちゃんと普通に起動できた ! – 簡単ですね !!
  9. kconfig help text が変わった • btrfs: update kconfig help text

    • http://git.kernel.org/cgit/linux/kernel/git/tor valds/linux.git/commit/fs/btrfs?id=4204617d142c 0887e45fda2562cb5c58097b918e • Btrfs is highly experimental, and THE DISK FORMAT IS NOT YET FINALIZED. You should say N here unless you are interested in testing Btrfs with non-critical data.
  10. after • The filesystem disk format is no longer unstable,

    and it's not expected to change unless there are strong reasons to do so. If there is a format change, file systems with a unchanged format will continue to be mountable and usable by newer kernels.
  11. まとめ • Btrfs はいろいろな死に方を経験して大人になった • SuSE の人が kconfig help から「

    You should say N here 」を削除したのだし大丈夫 • ね、 いまもすぐ直ったでしょ ? もし mount できなくなったらご連絡を ?