All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Stodden <daniel.stodden@citrix.com>
To: "Sébastien Riccio" <sr@swisscenter.com>
Cc: "dmeyer@cs.ubc.ca" <dmeyer@cs.ubc.ca>,
	"xen-devel@lists.xensource.com" <xen-devel@lists.xensource.com>
Subject: Re: xm/xl block-detach issue
Date: Sun, 10 Jul 2011 11:19:34 -0700	[thread overview]
Message-ID: <1310321977.2685.370.camel@ramone> (raw)
In-Reply-To: <4E19961F.9070109@swisscenter.com>

On Sun, 2011-07-10 at 08:07 -0400, Sébastien Riccio wrote:
> On 10.07.2011 11:05, Daniel Stodden wrote:
> > To just-get-me-that partition: Plug into dom0, so you'll get xvda1-n.
> > Oh wait, that was what didn't work either in the original mail.. :-)
> >
> > Daniel
> >
> >
> > _______________________________________________
> > Xen-devel mailing list
> > Xen-devel@lists.xensource.com
> > http://lists.xensource.com/xen-devel
> >
> 
> Hi Daniel,
> 
> Thanks a lot for your answers :) Well yes my original problem is to be 
> able to
> attach and detach a vhd file as a block device in the dom0, so I can 
> provision it.
> 
> Attaching it to dom0 with block-attach works well, can access, partition 
> it, format
> partitions, mount partitions, copy files... but then I can't detach it 
> and I'm stuck :)

Okay, that needs to get fixed, but I don't know where. In XCP that's how
it's exclusively done, because it's the most general approach.

> That's why I tried other ways to do it and got then stuck again on the 
> "can't access
> a partition" problem with the tap-ctl method.
>
> So talking about tap-ctl, yes IMHO it would be interesting to be able to 
> access them
> for such operations.

Partitions normally work by adding some stride between the 'part0' (the
entire disk) nodes allocated. E.g. scsi disks would allocate every 16th
minor for a new disk, and the space in between is partitions.

brw-rw---- 1 root disk 8, 0 Jul  7 09:47 /dev/sda
brw-rw---- 1 root disk 8, 1 Jul  7 09:47 /dev/sda1
brw-rw---- 1 root disk 8, 2 Jul  7 09:47 /dev/sda2

We don't have that, so partitions are off.

# l /dev/td*
brw-rw---- 1 root disk 254, 0 Jul 10 10:58 /dev/tda
brw-rw---- 1 root disk 254, 1 Jul 10 11:18 /dev/tdb

Problem is I'm not sure if just doing so wouldn't break sth, because we
work so much with minor numbers in the toolstack.

kpartx should work, I don't think that is tapdisk-related. After all it
doesn't really do any magic. It reads the partition table from the start
of the device and maybe lands a couple standard ioctls to query disk
size etc. The rest is DM.

Can you check if it works with some normal disk? Check out modules,
install lvm2, make sure you have dm-linear loaded, etc... You were
running a custom kernel, right? You're probably just missing sth.

Daniel

  reply	other threads:[~2011-07-10 18:19 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-09 14:34 xm/xl block-detach issue Sébastien Riccio
2011-07-09 17:28 ` Sébastien Riccio
2011-07-10  9:05   ` Daniel Stodden
2011-07-10 12:07     ` Sébastien Riccio
2011-07-10 18:19       ` Daniel Stodden [this message]
2011-07-11 17:09         ` Sébastien Riccio
2011-07-11 18:22           ` Daniel Stodden
2011-07-11 21:37             ` Sébastien Riccio
2011-07-11 21:48               ` Daniel Stodden
2011-07-12  5:21                 ` Sébastien Riccio
2011-07-12  5:47                 ` Sébastien Riccio
2011-07-12  5:30             ` Sébastien Riccio
2011-07-12  5:44               ` Sébastien Riccio
2011-07-13  8:32                 ` Sébastien Riccio
2011-07-13  8:44                 ` Sébastien Riccio
2011-07-29 14:25                   ` Konrad Rzeszutek Wilk

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=1310321977.2685.370.camel@ramone \
    --to=daniel.stodden@citrix.com \
    --cc=dmeyer@cs.ubc.ca \
    --cc=sr@swisscenter.com \
    --cc=xen-devel@lists.xensource.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.