From: Patrick Donnelly Date: Tue, 20 Sep 2022 14:32:26 +0000 (-0400) Subject: doc: update alternate meta pool recovery X-Git-Tag: v16.2.13~53^2~1 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=e5c5476ae097f4fec90490a95b9989fd2c7decb0;p=ceph.git doc: update alternate meta pool recovery Streamline, clarify, and use modern commands (notably: --recover). Signed-off-by: Patrick Donnelly (cherry picked from commit da19a128ee4a68299d4899de91701944720f53ae) --- diff --git a/doc/cephfs/disaster-recovery-experts.rst b/doc/cephfs/disaster-recovery-experts.rst index 11df16e3813c..9688caa037a9 100644 --- a/doc/cephfs/disaster-recovery-experts.rst +++ b/doc/cephfs/disaster-recovery-experts.rst @@ -229,27 +229,21 @@ backed by the original data pool. :: - ceph fs flag set enable_multiple true --yes-i-really-mean-it ceph osd pool create cephfs_recovery_meta - ceph fs new cephfs_recovery recovery --allow-dangerous-metadata-overlay + ceph fs new cephfs_recovery recovery --recover --allow-dangerous-metadata-overlay +.. note:: -The recovery file system starts with an MDS rank that will initialize the new -metadata pool with some metadata. This is necessary to bootstrap recovery. -However, now we will take the MDS down as we do not want it interacting with -the metadata pool further. - -:: - - ceph fs fail cephfs_recovery + The ``--recover`` flag prevents any MDS from joining the new file system. -Next, we will reset the initial metadata the MDS created: +Next, we will create the intial metadata for the fs: :: - cephfs-table-tool cephfs_recovery:all reset session - cephfs-table-tool cephfs_recovery:all reset snap - cephfs-table-tool cephfs_recovery:all reset inode + cephfs-table-tool cephfs_recovery:0 reset session + cephfs-table-tool cephfs_recovery:0 reset snap + cephfs-table-tool cephfs_recovery:0 reset inode + cephfs-journal-tool --rank cephfs_recovery:0 journal reset --force Now perform the recovery of the metadata pool from the data pool: @@ -272,7 +266,6 @@ with: :: cephfs-journal-tool --rank=:0 event recover_dentries list --alternate-pool cephfs_recovery_meta - cephfs-journal-tool --rank cephfs_recovery:0 journal reset --force After recovery, some recovered directories will have incorrect statistics. Ensure the parameters ``mds_verify_scatter`` and ``mds_debug_scatterstat`` are @@ -283,20 +276,22 @@ set to false (the default) to prevent the MDS from checking the statistics: ceph config rm mds mds_verify_scatter ceph config rm mds mds_debug_scatterstat -(Note, the config may also have been set globally or via a ceph.conf file.) +.. note:: + + Also verify the config has not been set globally or with a local ceph.conf file. + Now, allow an MDS to join the recovery file system: :: ceph fs set cephfs_recovery joinable true -Finally, run a forward :doc:`scrub ` to repair the statistics. +Finally, run a forward :doc:`scrub ` to repair recursive statistics. Ensure you have an MDS running and issue: :: - ceph fs status # get active MDS - ceph tell mds. scrub start / recursive repair + ceph tell mds.recovery_fs:0 scrub start / recursive,repair,force .. note::