From: arisawa <arisawa@ar.aichi-u.ac.jp>
To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: Re: [9fans] Disk backup?
Date: Mon, 25 Mar 2013 16:32:06 +0900 [thread overview]
Message-ID: <B38AA4A3-31EF-4693-B2AE-9AEBA481587E@ar.aichi-u.ac.jp> (raw)
In-Reply-To: <b554ab3d58d82e0786362357907ebace@rei2.9hal>
oh! nice!
that resolves all.
thanks a lot
i will try
On 2013/03/25, at 16:19, cinap_lenrek@gmx.de wrote:
> the block bitmap on a fakeworm is at the end of the sub
> device/partition. see fworm.c:
>
> int
> fwormread(Device *d, Off b, void *c)
> {
> Iobuf *p;
> Device *fdev;
> Devsize l;
>
> if(chatty > 1)
> fprint(2, "fworm read %lld\n", (Wideoff)b);
> fdev = FDEV(d);
> l = devsize(fdev);
> l -= l/(BUFSIZE*8) + 1;
> if(b >= l)
> panic("fworm: rbounds %lld", (Wideoff)b);
> l += b/(BUFSIZE*8);
>
> p = getbuf(fdev, l, Brd|Bres);
> if(!p || checktag(p, Tvirgo, l))
> panic("fworm: checktag %lld", (Wideoff)l);
> l = b % (BUFSIZE*8);
> if(!(p->iobuf[l/8] & (1<<(l%8)))) {
> putbuf(p);
> fprint(2, "fworm: read %lld\n", (Wideoff)b);
> return 1;
> }
> putbuf(p);
> return devread(fdev, b, c);
> }
>
> the block tags do not really matter for the backup. you use the
> fakeworm only as a backend for the cw device so you can just
> copy all the blocks that got ther bit set in the bitmap compared
> to the backup.
>
> --
> cinap
>
next prev parent reply other threads:[~2013-03-25 7:32 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-24 22:10 trebol
2013-03-25 0:33 ` erik quanstrom
2013-03-25 2:04 ` trebol
2013-03-25 3:14 ` arisawa
2013-03-25 4:36 ` cinap_lenrek
2013-03-25 5:46 ` arisawa
2013-03-25 7:19 ` cinap_lenrek
2013-03-25 7:32 ` arisawa [this message]
2013-03-25 13:43 ` erik quanstrom
2013-03-25 15:03 ` erik quanstrom
2013-03-26 7:27 ` arisawa
2013-03-26 13:19 ` erik quanstrom
2013-03-26 18:34 ` cinap_lenrek
2013-03-26 18:56 ` erik quanstrom
2013-03-26 19:07 ` cinap_lenrek
2013-03-26 19:10 ` erik quanstrom
2013-03-26 19:15 ` erik quanstrom
2013-03-26 19:23 ` cinap_lenrek
2013-03-26 7:07 ` arisawa
2013-03-26 12:52 ` erik quanstrom
2013-03-26 23:22 ` trebol
2013-03-28 7:51 ` arisawa
2013-03-28 13:17 ` erik quanstrom
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=B38AA4A3-31EF-4693-B2AE-9AEBA481587E@ar.aichi-u.ac.jp \
--to=arisawa@ar.aichi-u.ac.jp \
--cc=9fans@9fans.net \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).