<div dir="ltr"><div>So, sadly I went for the big hammer option, I thought that there were no other options ;). </div><div><br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">I'm guessing it can't find or validate the primary superblock, so</span><br style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">
<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">it's looking for a secondary superblock. Please post the output of</span><br style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">
<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">the running repair so we can see exactly what it is doing.</span></blockquote><div><br></div><div>That is exactly what it seems that it is happening.</div>
<div> </div><b>dmesg erros:</b><div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"> 81.927888] Pid: 878, comm: mount Not tainted 3.5.0-44-generic #67~precise1-Ubuntu<br>
[   81.927891] Call Trace:<br>[   81.927941]  [<ffffffffa01d460f>] xfs_error_report+0x3f/0x50 [xfs]<br>[   81.927972]  [<ffffffffa01ecd66>] ? xfs_free_extent+0xe6/0x130 [xfs]<br>[   81.927990]  [<ffffffffa01ea318>] xfs_free_ag_extent+0x528/0x730 [xfs]<br>
[   81.928007]  [<ffffffffa01e8e07>] ? kmem_zone_alloc+0x67/0xe0 [xfs]<br>[   81.928033]  [<ffffffffa01ecd66>] xfs_free_extent+0xe6/0x130 [xfs]<br>[   81.928055]  [<ffffffffa021bb10>] xlog_recover_process_efi+0x170/0x1b0 [xfs]<br>
[   81.928075]  [<ffffffffa021cd56>] xlog_recover_process_efis.isra.8+0x76/0xd0 [xfs]<br>[   81.928097]  [<ffffffffa0220a17>] xlog_recover_finish+0x27/0xd0 [xfs]<br>[   81.928119]  [<ffffffffa022812c>] xfs_log_mount_finish+0x2c/0x30 [xfs]<br>
[   81.928140]  [<ffffffffa0223620>] xfs_mountfs+0x420/0x6b0 [xfs]<br>[   81.928156]  [<ffffffffa01e2ffd>] xfs_fs_fill_super+0x21d/0x2b0 [xfs]<br>[   81.928163]  [<ffffffff8118b716>] mount_bdev+0x1c6/0x210<br>
[   81.928179]  [<ffffffffa01e2de0>] ? xfs_parseargs+0xb80/0xb80 [xfs]<br>[   81.928194]  [<ffffffffa01e10a5>] xfs_fs_mount+0x15/0x20 [xfs]<br>[   81.928198]  [<ffffffff8118c563>] mount_fs+0x43/0x1b0<br>
[   81.928202]  [<ffffffff811a5ee3>] ? find_filesystem+0x63/0x80<br>[   81.928206]  [<ffffffff811a7246>] vfs_kern_mount+0x76/0x120<br>[   81.928209]  [<ffffffff811a7c34>] do_kern_mount+0x54/0x110<br>[   81.928212]  [<ffffffff811a9934>] do_mount+0x1a4/0x260<br>
[   81.928215]  [<ffffffff811a9e10>] sys_mount+0x90/0xe0<br>[   81.928220]  [<ffffffff816a7729>] system_call_fastpath+0x16/0x1b<br>[   81.928229] XFS (dm-0): Failed to recover EFIs<br>[   81.928232] XFS (dm-0): log mount finish failed<br>
[   81.972741] XFS (dm-1): Mounting Filesystem<br>[   82.195661] XFS (dm-1): Ending clean mount<br>[   82.203627] XFS (dm-2): Mounting Filesystem<br>[   82.479044] XFS (dm-2): Ending clean mount</blockquote></div><div><br>
</div><div><br></div><div><span style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:14px;line-height:20.15625px">Actually, the problem was a little bit more complicated. This LVM2 partition, was using a physical device (PV) that is exported by a RAID NAS controller. This volume exported by the controller was created using a RAID 5, there was a hardware failure in one of the HDs of the array and the volume got unavailable, till</span><span style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:14px;line-height:20.15625px"> we replaced the bad driver with a new one and the array rebuild finished.</span><br>
</div><div><span style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:14px;line-height:20.15625px"><br></span></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">That's an old version of xfsprogs - you might want to start by</span><br style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">
<span style="color:rgb(0,0,0);font-family:arial,sans-serif;font-size:13px">upgrading it to 3.11...</span><span style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:14px;line-height:20.15625px"><br>
</span></blockquote><div><span style="color:rgb(0,0,0);font-family:Verdana,Arial,Helvetica,sans-serif;font-size:14px;line-height:20.15625px">So, a good try should be upgrading to xfsprogs 3.11 and running xfs_repair again.</span></div>
</div><div class="gmail_extra"><br><br><div class="gmail_quote">2013/12/15 Dave Chinner <span dir="ltr"><<a href="mailto:david@fromorbit.com" target="_blank">david@fromorbit.com</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Sun, Dec 15, 2013 at 08:47:30PM -0200, Rafael Weingartner wrote:<br>
> Hi folks,<br>
> I am having some troubles with a XFS over one LVM partition. After an<br>
> unexpected reboot, I am getting the following message when I try to mount<br>
> it:<br>
</div>> *mount: Structure needs cleaning*<br>
<br>
And the error in dmesg is?<br>
<div class="im"><br>
> I tried "sudo xfs_check /dev/mapper/volume". Sadly, I got the message:<br>
> xfs_check: cannot init perag data (117)<br>
<br>
</div>xfs_check is deprecated, please use "xfs_repair -n" instead.<br>
<br>
> *ERROR: The filesystem has valuable metadata changes in a log which needs<br>
> to*<br>
> *be replayed.  Mount the filesystem to replay the log, and unmount it<br>
> before*<br>
> *re-running xfs_check.  If you are unable to mount the filesystem, then use*<br>
> *the xfs_repair -L option to destroy the log and attempt a repair.*<br>
> *Note that destroying the log may cause corruption -- please attempt a<br>
> mount*<br>
> *of the filesystem before doing this*<br>
<div class="im">><br>
> So, I tried:<br>
> xfs_repair -L<br>
<br>
</div>Ok, so you went immediately for the big hammer. There's the<br>
possibility that might not be able to recover your filesystem from<br>
whatever went wrong now that the log has been zeroed.<br>
<div class="im"><br>
> The command is running for over 3 hours and still just dots on my screen, I<br>
> have no idea of what is happening. Any ideas how I can get it to work<br>
> again? Or at least some work around that would enable me to extract the<br>
> data that it contains.<br>
<br>
</div>I'm guessing it can't find or validate the primary superblock, so<br>
it's looking for a secondary superblock. Please post the output of<br>
the running repair so we can see exactly what it is doing.<br>
<br>
Also we need more information about your problem - why did the<br>
machine reboot? what's your storage configuration? You hardware,<br>
etc.<br>
<br>
<a href="http://xfs.org/index.php/XFS_FAQ#Q:_What_information_should_I_include_when_reporting_a_problem.3F" target="_blank">http://xfs.org/index.php/XFS_FAQ#Q:_What_information_should_I_include_when_reporting_a_problem.3F</a><br>

<div class="im"><br>
> The server is a Ubuntu server 12.04.<br>
> The XFS version is: xfs_info version 3.1.7<br>
> If you need I can provide you with more info.<br>
<br>
</div>That's an old version of xfsprogs - you might want to start by<br>
upgrading it to 3.11...<br>
<br>
Cheers,<br>
<br>
Dave.<br>
<span class="HOEnZb"><font color="#888888">--<br>
Dave Chinner<br>
<a href="mailto:david@fromorbit.com">david@fromorbit.com</a><br>
</font></span></blockquote></div><br><br clear="all"><div><br></div>-- <br><div dir="ltr">Rafael Weingärtner</div>
</div>