{"id":616,"date":"2012-07-10T12:40:12","date_gmt":"2012-07-10T04:40:12","guid":{"rendered":"http:\/\/rmohan.com\/?p=616"},"modified":"2012-07-10T12:41:49","modified_gmt":"2012-07-10T04:41:49","slug":"recover-bad-superblock-in-linux-filesystem","status":"publish","type":"post","link":"https:\/\/mohan.sg\/?p=616","title":{"rendered":"Recover Bad Superblock in Linux Filesystem"},"content":{"rendered":"<p><strong>Recover Bad Superblock in Linux Filesystem<\/strong><\/p>\n<p>If \u00a0you get a \u00a8Damaged Superblock\u00a8 error message at filesystem (fsck) check in Linux Server,\u00a0Usually fsck will not be able to repair the file system due to bad super block. In these situations,\u00a0we can recover the damaged super block from the backup.<\/p>\n<p><span style=\"text-decoration: underline;\"> Solution:<\/span><br \/>\n<strong><span style=\"text-decoration: underline;\"><br \/>\n<\/span><\/strong> There are backups of the Superblock located on several positions and we can restore them with a simple command in a Linux server<\/p>\n<p>By default in Linux, the file system creates the backup of \u00a0super block in the following locations:<\/p>\n<p><strong>8193, 32768, 98304, 163840, 229376 and 294912. <\/strong><br \/>\n<strong><\/strong><br \/>\n<strong><\/strong><strong><br \/>\n<\/strong><br \/>\n<strong><span style=\"text-decoration: underline;\">Note<\/span>:<\/strong> 8193 is only on older systems\u00a0\u00a0in many cases.\u00a032768 is the most current position for the first backup<\/p>\n<p>When you get this &#8220;damaged superblock or bad superblock error&#8221; and if \u00a0you get a root-prompt in a recovery console, then issue the following command:<\/p>\n<p># <strong>e2fsck -b 32768 \/dev\/hda5<\/strong><br \/>\n<strong><br \/>\n<\/strong><br \/>\nNow the System will check the filesystem with the information stored in that backup superblock and if the check was successful it will restore the backup to position 0.<\/p>\n<p>If this is not successful, then try using the other copy of Superblock backup (Refer the backup location of superblock above)<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Recover Bad Superblock in Linux Filesystem<\/p>\n<p>If you get a \u00a8Damaged Superblock\u00a8 error message at filesystem (fsck) check in Linux Server, Usually fsck will not be able to repair the file system due to bad super block. In these situations, we can recover the damaged super block from the backup.<\/p>\n<p> Solution: There are backups [&#8230;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[23],"tags":[],"_links":{"self":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/616"}],"collection":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=616"}],"version-history":[{"count":3,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/616\/revisions"}],"predecessor-version":[{"id":618,"href":"https:\/\/mohan.sg\/index.php?rest_route=\/wp\/v2\/posts\/616\/revisions\/618"}],"wp:attachment":[{"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=616"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=616"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mohan.sg\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=616"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}