<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>
Stan, do you check dates on links before you paste them here? I don't care if its the 1st results of the google search 'meaning of life', its irrelevant and oudated.<br><br>&gt; From: xfs-request@oss.sgi.com<br>&gt; Subject: xfs Digest, Vol 29, Issue 102<br>&gt; To: xfs@oss.sgi.com<br>&gt; Date: Sun, 30 Jan 2011 21:49:14 -0600<br>&gt; <br>&gt; Send xfs mailing list submissions to<br>&gt;         xfs@oss.sgi.com<br>&gt; <br>&gt; To subscribe or unsubscribe via the World Wide Web, visit<br>&gt;         http://oss.sgi.com/mailman/listinfo/xfs<br>&gt; or, via email, send a message with subject or body 'help' to<br>&gt;         xfs-request@oss.sgi.com<br>&gt; <br>&gt; You can reach the person managing the list at<br>&gt;         xfs-owner@oss.sgi.com<br>&gt; <br>&gt; When replying, please edit your Subject line so it is more specific<br>&gt; than "Re: Contents of xfs digest..."<br>&gt; <br>&gt; <br>&gt; Today's Topics:<br>&gt; <br>&gt;    1. RE: xfs Digest, Vol 29, Issue 101 (lord worm)<br>&gt;    2. Re: xfs Digest, Vol 29, Issue 101 (Stan Hoeppner)<br>&gt;    3. Re: [patch] xfsprogs: repair pagefault due to missed out<br>&gt;       sanity NULL        check (Ajeet Yadav)<br>&gt;    4. Re: [patch] xfsprogs: repair never return if device removed<br>&gt;       (Ajeet Yadav)<br>&gt;    5. Re: how to decode metadump info produced by xfs_db, and<br>&gt;       superblock        error (Dave Chinner)<br>&gt; <br>&gt; <br>&gt; ----------------------------------------------------------------------<br>&gt; <br>&gt; Message: 1<br>&gt; Date: Sun, 30 Jan 2011 13:27:51 -0500<br>&gt; From: lord worm &lt;cryptopsy@live.com&gt;<br>&gt; Subject: RE: xfs Digest, Vol 29, Issue 101<br>&gt; To: &lt;xfs@oss.sgi.com&gt;<br>&gt; Message-ID: &lt;SNT130-w7320373265265D515EDD5DAE30@phx.gbl&gt;<br>&gt; Content-Type: text/plain; charset="iso-8859-1"<br>&gt; <br>&gt; <br>&gt; Stan I have no idea, could you tell me in detail why dd failed, and what exactly those restore commands provide specifically?<br>&gt; <br>&gt;                                                <br>&gt; -------------- next part --------------<br>&gt; An HTML attachment was scrubbed...<br>&gt; URL: &lt;http://oss.sgi.com/pipermail/xfs/attachments/20110130/dee98fcc/attachment-0001.htm&gt;<br>&gt; <br>&gt; ------------------------------<br>&gt; <br>&gt; Message: 2<br>&gt; Date: Sun, 30 Jan 2011 15:03:42 -0600<br>&gt; From: Stan Hoeppner &lt;stan@hardwarefreak.com&gt;<br>&gt; Subject: Re: xfs Digest, Vol 29, Issue 101<br>&gt; To: xfs@oss.sgi.com<br>&gt; Message-ID: &lt;4D45D22E.2060603@hardwarefreak.com&gt;<br>&gt; Content-Type: text/plain; charset=ISO-8859-1<br>&gt; <br>&gt; lord worm put forth on 1/30/2011 12:27 PM:<br>&gt; &gt; <br>&gt; &gt; Stan I have no idea, could you tell me in detail why dd failed, and what exactly those restore commands provide specifically?<br>&gt; <br>&gt; This might have some relevance.  2nd hit Googling for "dd with xfs":<br>&gt; <br>&gt; http://oss.sgi.com/archives/xfs/2003-04/msg00802.html<br>&gt; <br>&gt; -- <br>&gt; Stan<br>&gt; <br>&gt; <br>&gt; <br>&gt; ------------------------------<br>&gt; <br>&gt; Message: 3<br>&gt; Date: Mon, 31 Jan 2011 11:39:15 +0900<br>&gt; From: Ajeet Yadav &lt;ajeet.yadav.77@gmail.com&gt;<br>&gt; Subject: Re: [patch] xfsprogs: repair pagefault due to missed out<br>&gt;         sanity NULL        check<br>&gt; To: xfs@oss.sgi.com<br>&gt; Message-ID:<br>&gt;         &lt;AANLkTinK25hL3Ljy42S6KrqEJ7nW_L+c77GPJhBVo=58@mail.gmail.com&gt;<br>&gt; Content-Type: text/plain; charset="iso-8859-1"<br>&gt; <br>&gt; I did not receive any response / review comment on solution patch I sent.<br>&gt; <br>&gt; diff -Nurp xfsprogs/repair/dir2.c xfsprogs-dirty/repair/dir2.c<br>&gt; <br>&gt; --- xfsprogs/repair/dir2.c 2010-07-16 13:07:09.000000000 +0900<br>&gt; <br>&gt; +++ xfsprogs-dirty/repair/dir2.c 2011-01-28 18:49:21.000000000 +0900<br>&gt; <br>&gt; @@ -110,9 +110,10 @@ da_read_buf(<br>&gt; <br>&gt; bplist[i] = libxfs_readbuf(mp-&gt;m_dev,<br>&gt; <br>&gt; XFS_FSB_TO_DADDR(mp, bmp[i].startblock),<br>&gt; <br>&gt; XFS_FSB_TO_BB(mp, bmp[i].blockcount), 0);<br>&gt; <br>&gt; - if (!bplist[i])<br>&gt; <br>&gt; + if (!bplist[i]){<br>&gt; <br>&gt; + nex = i;<br>&gt; <br>&gt; goto failed;<br>&gt; <br>&gt; -<br>&gt; <br>&gt; + }<br>&gt; <br>&gt; pftrace("readbuf %p (%llu, %d)", bplist[i],<br>&gt; <br>&gt; (long long)XFS_BUF_ADDR(bplist[i]),<br>&gt; <br>&gt; XFS_BUF_COUNT(bplist[i]));<br>&gt; On Fri, Jan 28, 2011 at 8:13 PM, Ajeet Yadav &lt;ajeet.yadav.77@gmail.com&gt;wrote:<br>&gt; <br>&gt; &gt; libxfs_putbuf() is called with bp = NULL, resulting in pagefault in<br>&gt; &gt; libpthread.<br>&gt; &gt;<br>&gt; &gt; Function da_read_buf() allocate array of xfs_buf_t *<br>&gt; &gt;<br>&gt; &gt;    * xfs_buf_t       **bplist;*<br>&gt; &gt;<br>&gt; &gt; *    bplist = calloc(nex, sizeof(*bplist));*<br>&gt; &gt;<br>&gt; &gt; Read and fill it using<br>&gt; &gt;<br>&gt; &gt; *for (i = 0; i &lt; nex; i++) {<br>&gt; &gt;     bplist[i] = libxfs_readbuf()*<br>&gt; &gt;<br>&gt; &gt; *    if (!bplist[i]){<br>&gt; &gt;         goto failed;<br>&gt; &gt;     }  *<br>&gt; &gt;<br>&gt; &gt; *}*<br>&gt; &gt;<br>&gt; &gt; *failed:<br>&gt; &gt;         for (i = 0; i &lt; nex; i++)<br>&gt; &gt;                 libxfs_putbuf(bplist[i]);*<br>&gt; &gt;<br>&gt; &gt; Now assume nex = 10,<br>&gt; &gt;<br>&gt; &gt; 1. Will create bplist for 10 array elements.<br>&gt; &gt;<br>&gt; &gt; 3. Reading from disk 0,1, 2, 3<br>&gt; &gt;<br>&gt; &gt; 4. When reading from disk 4, USB is removed<br>&gt; &gt;<br>&gt; &gt; 5. libxfs_readbuf() will at fail, pblist[4] = NULL, goto failed.<br>&gt; &gt;<br>&gt; &gt; 6. Since only 4 buffers were read successfully, so only 4 are in lock<br>&gt; &gt; state.<br>&gt; &gt;<br>&gt; &gt; 7.  Error handling will unlock buffer from 1-10<br>&gt; &gt;<br>&gt; &gt; 8. Buffer 0-3 were read successfully, hence will have valid pdlist[i]<br>&gt; &gt;<br>&gt; &gt; 9. Access pblist[4] == NULL, therefore unlocking will set bp == NULL in<br>&gt; &gt; libxfs_putbuf(bp);<br>&gt; &gt; 10. Page fault in libpthread<br>&gt; &gt;<br>&gt; &gt;<br>&gt; &gt; Solution patch attached with mail<br>&gt; &gt;<br>&gt; &gt;<br>&gt; &gt;<br>&gt; -------------- next part --------------<br>&gt; An HTML attachment was scrubbed...<br>&gt; URL: &lt;http://oss.sgi.com/pipermail/xfs/attachments/20110131/4e2718ae/attachment-0001.htm&gt;<br>&gt; <br>&gt; ------------------------------<br>&gt; <br>&gt; Message: 4<br>&gt; Date: Mon, 31 Jan 2011 11:41:16 +0900<br>&gt; From: Ajeet Yadav &lt;ajeet.yadav.77@gmail.com&gt;<br>&gt; Subject: Re: [patch] xfsprogs: repair never return if device removed<br>&gt; To: xfs@oss.sgi.com<br>&gt; Message-ID:<br>&gt;         &lt;AANLkTikyOfkbtxN3Et5YZRJ2rPpdsVouJkyRW4fDbUG7@mail.gmail.com&gt;<br>&gt; Content-Type: text/plain; charset="iso-8859-1"<br>&gt; <br>&gt; I did not receive and response / reviews on patch.<br>&gt; <br>&gt; diff -Nurp xfsprogs/repair/sb.c xfsprogs-dirty/repair/sb.c<br>&gt; <br>&gt; --- xfsprogs/repair/sb.c 2011-01-28 20:23:02.000000000 +0900<br>&gt; <br>&gt; +++ xfsprogs-dirty/repair/sb.c 2011-01-28 20:21:06.000000000 +0900<br>&gt; <br>&gt; @@ -122,8 +122,9 @@ find_secondary_sb(xfs_sb_t *rsb)<br>&gt; <br>&gt; done = 1;<br>&gt; <br>&gt; }<br>&gt; <br>&gt; - if (!done &amp;&amp; (bsize = read(x.dfd, sb, BSIZE)) == 0) {<br>&gt; <br>&gt; + if (!done &amp;&amp; (bsize = read(x.dfd, sb, BSIZE)) &lt;= 0) {<br>&gt; <br>&gt; done = 1;<br>&gt; <br>&gt; + do_warn(_("Couldn't find candidate secondary superblock, exiting...\n"));<br>&gt; <br>&gt; }<br>&gt; <br>&gt; do_warn(".");<br>&gt; <br>&gt; On Fri, Jan 28, 2011 at 8:31 PM, Ajeet Yadav &lt;ajeet.yadav.77@gmail.com&gt;wrote:<br>&gt; <br>&gt; &gt; xfsprogs all version, delete primary superblock of xfs partition<br>&gt; &gt;<br>&gt; &gt; dd if=/dev/zero of=/dev/sda1 bs=512 count=1<br>&gt; &gt; sync<br>&gt; &gt;<br>&gt; &gt; Run xfs_repair in partition, while its searching for secondary superblock,<br>&gt; &gt; remove the disk (USB) xfs_repair will never exit and will loop in never<br>&gt; &gt; ending ............<br>&gt; &gt;<br>&gt; &gt; Please find patch attached with mail<br>&gt; &gt;<br>&gt; -------------- next part --------------<br>&gt; An HTML attachment was scrubbed...<br>&gt; URL: &lt;http://oss.sgi.com/pipermail/xfs/attachments/20110131/77ad227f/attachment-0001.htm&gt;<br>&gt; <br>&gt; ------------------------------<br>&gt; <br>&gt; Message: 5<br>&gt; Date: Mon, 31 Jan 2011 14:51:31 +1100<br>&gt; From: Dave Chinner &lt;david@fromorbit.com&gt;<br>&gt; Subject: Re: how to decode metadump info produced by xfs_db, and<br>&gt;         superblock        error<br>&gt; To: lord worm &lt;cryptopsy@live.com&gt;<br>&gt; Cc: xfs@oss.sgi.com<br>&gt; Message-ID: &lt;20110131035131.GI21311@dastard&gt;<br>&gt; Content-Type: text/plain; charset=us-ascii<br>&gt; <br>&gt; On Sun, Jan 30, 2011 at 08:21:19PM -0500, lord worm wrote:<br>&gt; &gt; &gt; Date: Mon, 31 Jan 2011 08:40:26 +1100<br>&gt; &gt; &gt; From: david@fromorbit.com<br>&gt; &gt; &gt; To: cryptopsy@live.com<br>&gt; &gt; &gt; Subject: Re: how to decode metadump info produced by xfs_db, and superblock error<br>&gt; &gt; &gt; <br>&gt; &gt; &gt; On Sun, Jan 30, 2011 at 11:33:53AM -0500, lord worm wrote:<br>&gt; &gt; &gt; &gt; &gt; Date: Sun, 30 Jan 2011 18:16:30 +1100<br>&gt; &gt; &gt; &gt; &gt; From: david@fromorbit.com<br>&gt; &gt; &gt; &gt; &gt; To: cryptopsy@live.com<br>&gt; &gt; &gt; &gt; &gt; CC: xfs@oss.sgi.com<br>&gt; &gt; &gt; &gt; &gt; Subject: Re: how to decode metadump info produced by xfs_db, and superblock error<br>&gt; &gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; &gt; On Sat, Jan 29, 2011 at 07:25:10PM -0500, lord worm wrote:<br>&gt; &gt; &gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; &gt; &gt; What kind of information is in this file produced by metadump, is it worth reading it somehow?<br>&gt; &gt; &gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; &gt; &gt; I'm trying to first understand what's causing a 'superblock cannot<br>&gt; &gt; &gt; &gt; &gt; &gt; be read' error in my XFS after a succesfully dd of the partition<br>&gt; &gt; &gt; &gt; &gt; &gt; (dd succeeds in copying to a file, and also restoring, but after<br>&gt; &gt; &gt; &gt; &gt; &gt; restoring it cannot mount).<br>&gt; &gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; &gt; dmesg output when the mount fails?<br>&gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; Could you email the mailing list next time as well, so that my<br>&gt; &gt; &gt; &gt; forwards are directed towards everyone, please?<br>&gt; &gt; &gt; <br>&gt; &gt; &gt; I did:<br>&gt; &gt; &gt; <br>&gt; &gt; &gt; http://oss.sgi.com/archives/xfs/2011-01/msg00486.html<br>&gt; &gt; &gt; <br>&gt; &gt; &gt; As for list ettiquette - please don't top post and wrap all you text<br>&gt; &gt; &gt; except for code and pasted log messages at 72 columns.....<br>&gt; <br>&gt; Fixed that for you again.<br>&gt; <br>&gt; &gt; &gt; &gt; Here's dmesg from the backup file, but I don't have it from the original disk after restoring it:<br>&gt; &gt; &gt; &gt; <br>&gt; &gt; &gt; &gt; [  362.685464] attempt to access beyond end of device<br>&gt; &gt; &gt; &gt; [  362.685468] loop5: rw=0, want=15662872, limit=15661056<br>&gt; &gt; &gt; &gt; [  362.685473] I/O error in filesystem ("loop5") meta-data dev loop5 block 0xeeff17       ("xfs_read_buf") error 5 buf count 512<br>&gt; &gt; &gt; &gt; [  362.685478] XFS: size check 2 failed<br>&gt; &gt; &gt; <br>&gt; &gt; &gt; Simple problem - you copied the filesystem back onto a device that<br>&gt; &gt; &gt; is too small for the filesystem.<br>&gt; &gt; <br>&gt; &gt; When I reply to this email, it defaults to david@fromorbit.com, so<br>&gt; &gt; how will the others see it?<br>&gt; <br>&gt; Reply to all. It's common courtesy to reply to everyone on the<br>&gt; cc-list for mailing list traffic as it often contains people not<br>&gt; subscribed to the mailing list (e.g. a person reporting a bug).<br>&gt; <br>&gt; I've added the xfs list back onto the cc-list.<br>&gt; <br>&gt; &gt; I can't mount the direct dd image of the drive as a loop device<br>&gt; &gt; either by the same error.<br>&gt; <br>&gt; Which means you probably didn't copy the entire drive in the first<br>&gt; place.<br>&gt; <br>&gt; &gt; The error persists even when its not<br>&gt; &gt; the filesystem that was copied back onto the device. Additionally,<br>&gt; &gt; its the exact same device with the exact same partition type<br>&gt; &gt; created by the exact same version of disk.<br>&gt; <br>&gt; partition type doesn't matter - the size does. The above error<br>&gt; indicates that the loop device is 1816 sectors (908kiB) shorter than<br>&gt; it needs to be, so maybe you aren't recreating the partition as<br>&gt; large as it needs to be, too....<br>&gt; <br>&gt; As it is, the question I have at this point is why are you trying to<br>&gt; copy the filesystem via dd? if all you want is an image, xfs_copy is<br>&gt; probably what you want....<br>&gt; <br>&gt; Cheers,<br>&gt; <br>&gt; Dave.<br>&gt; -- <br>&gt; Dave Chinner<br>&gt; david@fromorbit.com<br>&gt; <br>&gt; <br>&gt; <br>&gt; ------------------------------<br>&gt; <br>&gt; _______________________________________________<br>&gt; xfs mailing list<br>&gt; xfs@oss.sgi.com<br>&gt; http://oss.sgi.com/mailman/listinfo/xfs<br>&gt; <br>&gt; <br>&gt; End of xfs Digest, Vol 29, Issue 102<br>&gt; ************************************<br>                                               </body>
</html>