# phpman > info > xfs_mdrestore

[xfs_mdrestore(8)](https://www.chedong.com/phpMan.php/man/xfsmdrestore/8/markdown)            System Manager's Manual           [xfs_mdrestore(8)](https://www.chedong.com/phpMan.php/man/xfsmdrestore/8/markdown)

NAME
       xfs_mdrestore - restores an XFS metadump image to a filesystem image

SYNOPSIS
       xfs_mdrestore [ -gi ] source target
       xfs_mdrestore -i source
       xfs_mdrestore -V

DESCRIPTION
       xfs_mdrestore is a debugging tool that restores a metadata image gener-
       ated by [xfs_metadump(8)](https://www.chedong.com/phpMan.php/man/xfsmetadump/8/markdown) to a filesystem. The source argument  specifies
       the  location  of  the metadump image and the target argument specifies
       the destination for the filesystem image.  If the source is -, then the
       metadata image is read from stdin. This allows the output of be another
       program  such  as  a  compression  application  to  be  redirected   to
       xfs_mdrestore.  The target can be either a file or a device.

       xfs_mdrestore  should  not be used to restore metadata onto an existing
       filesystem unless you are completely certain  the  target  can  be  de-
       stroyed.

OPTIONS
       -g     Shows restore progress on stdout.

       -i     Shows  metadump  information  on stdout.  If no target is speci-
              fied, exits after displaying information.  Older  metadumps  man
              not include any descriptive information.

       -V     Prints the version number and exits.

DIAGNOSTICS
       xfs_mdrestore returns an exit code of 0 if all the metadata is success-
       fully restored or 1 if an error occurs.

SEE ALSO
       [xfs_metadump(8)](https://www.chedong.com/phpMan.php/man/xfsmetadump/8/markdown), [xfs_repair(8)](https://www.chedong.com/phpMan.php/man/xfsrepair/8/markdown), [xfs(5)](https://www.chedong.com/phpMan.php/man/xfs/5/markdown)

BUGS
       Email bug reports to <linux-xfs@vger.kernel.org>.

                                                              [xfs_mdrestore(8)](https://www.chedong.com/phpMan.php/man/xfsmdrestore/8/markdown)
