Centos 7, Freezing a (root) file system before (xfs) dumping it












1















I have just installed Centos 7 on my comp. My setup has three partitions root (/), /data and /home. All partitions are of the xfs type.
Now I tried to do the backup of the root partition. In order to do that I executed:



xfsdump -l 0 -f /data/root_fs.xfs /


Everything went well.



Actually I was a bit confused that everything went well because I was dumping live mounted file system. In order to be sure that backup will be good, I decided to freeze the root file system, and then to dump it. To do so I have executed:



Xfs_freeze –f /;xfsdump -l 0 -f /dev/root_fs.xfs /;xfs_freeze –u /


…but now my system hangs. I can ping it, but I don't have access from the keyboard nor from ssh, so I have to do the hard reset.



The same procedure (prior freezing) I can use on let’s say /data or /home partitions with no problem at all.



My questions are:




  1. Will xfsdump with no prior freezing of root file system, ended in partition backup that I will be able to use for bare bone recovery (let’s say on a new disk)?


  2. Why I can freeze /data or /home file systems but not root file system?



Regards.










share|improve this question

























  • The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

    – ridgy
    Feb 24 '17 at 10:09
















1















I have just installed Centos 7 on my comp. My setup has three partitions root (/), /data and /home. All partitions are of the xfs type.
Now I tried to do the backup of the root partition. In order to do that I executed:



xfsdump -l 0 -f /data/root_fs.xfs /


Everything went well.



Actually I was a bit confused that everything went well because I was dumping live mounted file system. In order to be sure that backup will be good, I decided to freeze the root file system, and then to dump it. To do so I have executed:



Xfs_freeze –f /;xfsdump -l 0 -f /dev/root_fs.xfs /;xfs_freeze –u /


…but now my system hangs. I can ping it, but I don't have access from the keyboard nor from ssh, so I have to do the hard reset.



The same procedure (prior freezing) I can use on let’s say /data or /home partitions with no problem at all.



My questions are:




  1. Will xfsdump with no prior freezing of root file system, ended in partition backup that I will be able to use for bare bone recovery (let’s say on a new disk)?


  2. Why I can freeze /data or /home file systems but not root file system?



Regards.










share|improve this question

























  • The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

    – ridgy
    Feb 24 '17 at 10:09














1












1








1








I have just installed Centos 7 on my comp. My setup has three partitions root (/), /data and /home. All partitions are of the xfs type.
Now I tried to do the backup of the root partition. In order to do that I executed:



xfsdump -l 0 -f /data/root_fs.xfs /


Everything went well.



Actually I was a bit confused that everything went well because I was dumping live mounted file system. In order to be sure that backup will be good, I decided to freeze the root file system, and then to dump it. To do so I have executed:



Xfs_freeze –f /;xfsdump -l 0 -f /dev/root_fs.xfs /;xfs_freeze –u /


…but now my system hangs. I can ping it, but I don't have access from the keyboard nor from ssh, so I have to do the hard reset.



The same procedure (prior freezing) I can use on let’s say /data or /home partitions with no problem at all.



My questions are:




  1. Will xfsdump with no prior freezing of root file system, ended in partition backup that I will be able to use for bare bone recovery (let’s say on a new disk)?


  2. Why I can freeze /data or /home file systems but not root file system?



Regards.










share|improve this question
















I have just installed Centos 7 on my comp. My setup has three partitions root (/), /data and /home. All partitions are of the xfs type.
Now I tried to do the backup of the root partition. In order to do that I executed:



xfsdump -l 0 -f /data/root_fs.xfs /


Everything went well.



Actually I was a bit confused that everything went well because I was dumping live mounted file system. In order to be sure that backup will be good, I decided to freeze the root file system, and then to dump it. To do so I have executed:



Xfs_freeze –f /;xfsdump -l 0 -f /dev/root_fs.xfs /;xfs_freeze –u /


…but now my system hangs. I can ping it, but I don't have access from the keyboard nor from ssh, so I have to do the hard reset.



The same procedure (prior freezing) I can use on let’s say /data or /home partitions with no problem at all.



My questions are:




  1. Will xfsdump with no prior freezing of root file system, ended in partition backup that I will be able to use for bare bone recovery (let’s say on a new disk)?


  2. Why I can freeze /data or /home file systems but not root file system?



Regards.







linux centos






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited Feb 23 '17 at 18:57









GAD3R

27.1k1757113




27.1k1757113










asked Feb 23 '17 at 18:37









GlupeGlupe

61




61













  • The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

    – ridgy
    Feb 24 '17 at 10:09



















  • The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

    – ridgy
    Feb 24 '17 at 10:09

















The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

– ridgy
Feb 24 '17 at 10:09





The manpage says: "Any process attempting to write to the frozen filesystem will block waiting for the filesystem to be unfrozen". As system processes use to write e.g. log files etc., they are blocked until your dump is done. You should not use xfs_freeze for long lasting operations; from the manpage: "xfs_freeze is intended to be used with volume managers and hardware RAID devices that support the creation of snapshots" - as snapshots only need parts of seconds to be created. And if your dump is usable depends on what files are modified during the dump.

– ridgy
Feb 24 '17 at 10:09










1 Answer
1






active

oldest

votes


















0














Old question, but in case someone happens to have the same questions:




  1. xfsdump is indeed designed to be run on live filesystems. Assuming you don't update binaries through the dump process, or move files around, the dump will be consistent and good for recovery. Try to have as quiet filesystem as possible.


  2. As the comment to your question says, freezing for long time can create problems. The root filesystem is problematic since (depending on layout) it might include /var as well, which means logging hangs, updating utmp hangs, etc. so I'm not surprised you can't login anymore.







share|improve this answer








New contributor




iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.




















    Your Answer








    StackExchange.ready(function() {
    var channelOptions = {
    tags: "".split(" "),
    id: "106"
    };
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function() {
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled) {
    StackExchange.using("snippets", function() {
    createEditor();
    });
    }
    else {
    createEditor();
    }
    });

    function createEditor() {
    StackExchange.prepareEditor({
    heartbeatType: 'answer',
    autoActivateHeartbeat: false,
    convertImagesToLinks: false,
    noModals: true,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    imageUploader: {
    brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
    contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
    allowUrls: true
    },
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    });


    }
    });














    draft saved

    draft discarded


















    StackExchange.ready(
    function () {
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f347150%2fcentos-7-freezing-a-root-file-system-before-xfs-dumping-it%23new-answer', 'question_page');
    }
    );

    Post as a guest















    Required, but never shown

























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes









    0














    Old question, but in case someone happens to have the same questions:




    1. xfsdump is indeed designed to be run on live filesystems. Assuming you don't update binaries through the dump process, or move files around, the dump will be consistent and good for recovery. Try to have as quiet filesystem as possible.


    2. As the comment to your question says, freezing for long time can create problems. The root filesystem is problematic since (depending on layout) it might include /var as well, which means logging hangs, updating utmp hangs, etc. so I'm not surprised you can't login anymore.







    share|improve this answer








    New contributor




    iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
    Check out our Code of Conduct.

























      0














      Old question, but in case someone happens to have the same questions:




      1. xfsdump is indeed designed to be run on live filesystems. Assuming you don't update binaries through the dump process, or move files around, the dump will be consistent and good for recovery. Try to have as quiet filesystem as possible.


      2. As the comment to your question says, freezing for long time can create problems. The root filesystem is problematic since (depending on layout) it might include /var as well, which means logging hangs, updating utmp hangs, etc. so I'm not surprised you can't login anymore.







      share|improve this answer








      New contributor




      iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
      Check out our Code of Conduct.























        0












        0








        0







        Old question, but in case someone happens to have the same questions:




        1. xfsdump is indeed designed to be run on live filesystems. Assuming you don't update binaries through the dump process, or move files around, the dump will be consistent and good for recovery. Try to have as quiet filesystem as possible.


        2. As the comment to your question says, freezing for long time can create problems. The root filesystem is problematic since (depending on layout) it might include /var as well, which means logging hangs, updating utmp hangs, etc. so I'm not surprised you can't login anymore.







        share|improve this answer








        New contributor




        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.










        Old question, but in case someone happens to have the same questions:




        1. xfsdump is indeed designed to be run on live filesystems. Assuming you don't update binaries through the dump process, or move files around, the dump will be consistent and good for recovery. Try to have as quiet filesystem as possible.


        2. As the comment to your question says, freezing for long time can create problems. The root filesystem is problematic since (depending on layout) it might include /var as well, which means logging hangs, updating utmp hangs, etc. so I'm not surprised you can't login anymore.








        share|improve this answer








        New contributor




        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        share|improve this answer



        share|improve this answer






        New contributor




        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.









        answered 12 mins ago









        iustiniustin

        1




        1




        New contributor




        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.





        New contributor





        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






        iustin is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
        Check out our Code of Conduct.






























            draft saved

            draft discarded




















































            Thanks for contributing an answer to Unix & Linux Stack Exchange!


            • Please be sure to answer the question. Provide details and share your research!

            But avoid



            • Asking for help, clarification, or responding to other answers.

            • Making statements based on opinion; back them up with references or personal experience.


            To learn more, see our tips on writing great answers.




            draft saved


            draft discarded














            StackExchange.ready(
            function () {
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f347150%2fcentos-7-freezing-a-root-file-system-before-xfs-dumping-it%23new-answer', 'question_page');
            }
            );

            Post as a guest















            Required, but never shown





















































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown

































            Required, but never shown














            Required, but never shown












            Required, but never shown







            Required, but never shown







            Popular posts from this blog

            宮崎県

            濃尾地震

            シテ島