Okay, here''s another question that no one will be able to answer. I have an OpenBSD HVM domU, and I wanted to mount its filesystem in my Linux dom0. The domU''s disk lives on a logical volume. Kpartx does detect that partition 4 contains the disklabel, but that''s as far as I get. I think my fedora kernel just doesn''t support disklabels... Anyone know how this is supposed to work? Thanks -Dylan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Dylan Martin wrote:> Okay, here''s another question that no one will be able to answer. > > I have an OpenBSD HVM domU, and I wanted to mount its filesystem in > my Linux dom0. The domU''s disk lives on a logical volume. Kpartx > does detect that partition 4 contains the disklabel, but that''s as far > as I get. > > I think my fedora kernel just doesn''t support disklabels... > > Anyone know how this is supposed to work? >So why use them. Disklabels for ext2 and ext3 are useful abut the partitions can still be accessed as /dev/hda1, /dev/VolGroup00/whatever, or if you use "kpartx -a /dev/VolGroup00/whatever" then you can access /dev/mapper/whatever0, /dev/mapper/whatever1, etc. Or did you do something too clever and use LVM instide of the OpenBSD DomU and need to go through extra arcanery? _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
> >Okay, here''s another question that no one will be able to answer. > > > >I have an OpenBSD HVM domU, and I wanted to mount its filesystem in > >my Linux dom0. The domU''s disk lives on a logical volume. Kpartx > >does detect that partition 4 contains the disklabel, but that''s as far > >as I get. > > > >I think my fedora kernel just doesn''t support disklabels... > > > >Anyone know how this is supposed to work? > > > So why use them. Disklabels for ext2 and ext3 are useful abut the > partitions can still be accessed as /dev/hda1, /dev/VolGroup00/whatever, > or if you use "kpartx -a /dev/VolGroup00/whatever" then you can access > /dev/mapper/whatever0, /dev/mapper/whatever1, etc. > > Or did you do something too clever and use LVM instide of the OpenBSD > DomU and need to go through extra arcanery?I think there is some file system label and disklabel confusion here. Disklabel is like fdisk for bsd.. sort of. In PC hardware when running bsd, you first have to partition your disk using fdisk. If you''re only running one OS, you just make one partition with all the space in it. Then you take that partition and break it up into sub-partitions (for lack of a better word) using disklabel. I think the reason for this has to do with PC hardware vs. other kinds that don''t use dos-type partition tables. Anyway, the upshot is that in order for Linux to see my OpenBSD partitions, it would have to read the disklabel to know where my filesystems are. Another way to say it is: [dom0 ...] [lv ] [fdisk part ] [disklabel ] [wd0a][wd0d].. -Dylan _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Whoops! I replied, but it only went to Dylan, not the list. In the interests of completeness, I repeat my response: On Fri, 2007-07-20 at 13:04 -0700, Dylan Martin wrote:> > >Okay, here''s another question that no one will be able to answer. > > > > > >I have an OpenBSD HVM domU, and I wanted to mount its filesystem in > > >my Linux dom0. The domU''s disk lives on a logical volume. Kpartx > > >does detect that partition 4 contains the disklabel, but that''s as far > > >as I get. > > > > > >I think my fedora kernel just doesn''t support disklabels... > > > > > >Anyone know how this is supposed to work? > > > > > So why use them. Disklabels for ext2 and ext3 are useful abut the > > partitions can still be accessed as /dev/hda1, /dev/VolGroup00/whatever, > > or if you use "kpartx -a /dev/VolGroup00/whatever" then you can access > > /dev/mapper/whatever0, /dev/mapper/whatever1, etc. > > > > Or did you do something too clever and use LVM instide of the OpenBSD > > DomU and need to go through extra arcanery? > > I think there is some file system label and disklabel confusion here. > Disklabel is like fdisk for bsd.. sort of. In PC hardware when > running bsd, you first have to partition your disk using fdisk. If > you''re only running one OS, you just make one partition with all the > space in it. Then you take that partition and break it up into > sub-partitions (for lack of a better word) using disklabel. I think > the reason for this has to do with PC hardware vs. other kinds that > don''t use dos-type partition tables.To clarify, Linux fdisk partitions are called "slices" in BSD. Inside each slice, BSD''s disklabel splits the slice into up to 8 "partitions". named "a" through "h". "a" refers to the root. "b" is used as swap. "c" is the "whole" disk. "d" through "h" can be used for filesystems such as /usr, /var, etc.> Anyway, the upshot is that in order for Linux to see my OpenBSD > partitions, it would have to read the disklabel to know where my > filesystems are. > > Another way to say it is: > > [dom0 ...] > [lv ] > [fdisk part ] > [disklabel ] > [wd0a][wd0d]..If you have UFS support in your Linux kernel, you can mount these filesystems. The trick, however, is in knowing how your disk is laid out. You can use Linux'' "fdisk" to see this. Let''s assume that this is the slave drive on your second IDE controller, hence Linux calls it /dev/hdd. Bring up fdisk and have it look at /dev/hdd: # fdisk /dev/hdd Do a "p" command to see your partitions as Linux knows them. Hopefully, you''ll see a partition with an "a5" or "BSD/386" partition ID. If so, then you can get fdisk to read the the BSD disklabel info by typing in a "b" command. You should then get a "BSD disklabel" prompt. Type in "p" again to display the disklabel info. Now, once you sort out what you want to mount, you need to know how Linux will refer to the BSD partitions. This will vary depending on whether there are any Linux partitions on the drive, as the BSD "a" partition will show up as the first non-Linux partition, "b" as the second, "c" as the third, "d" as the fourth and so on. Some examples: 1. Disk has two Linux partitions (hdd1 and hdd2) and one BSD partition or "slice" (hdd3). In this case: /dev/hdd1 will be a Linux partition /dev/hdd2 will be a Linux partition /dev/hdd4 will be the BSD "a" partition /dev/hdd5 will be the BSD "b" partition /dev/hdd6 will be the BSD "c" partition /dev/hdd7 will be the BSD "d" partition and so on. Note that /dev/hdd3 is the BSD partition, but you can''t use it for mounts. 2. Disk has one regular Linux partition (hdd1), one Linux extended partition (hdd2) with two logical partitions (hdd5, hdd6), and one BSD slice (hdd3). In this case: /dev/hdd1 will be a Linux partition /dev/hdd5 will be a Linux partition (first logical in hdd2) /dev/hdd6 will be a Linux partition (second logical in hdd2) /dev/hdd7 will be the BSD "a" partition /dev/hdd8 will be the BSD "b" partition /dev/hdd9 will be the BSD "c" partition /dev/hdd10 will be the BSD "d" partition Again, /dev/hdd3 isn''t available for mounting as it''s the actual BSD partition. /dev/hdd2 also isn''t available as it''s the Linux extended partition. /dev/hdd4 doesn''t appear since there is no fourth partition and Linux always starts logical partitions at "5". 3. Disk is a single BSD drive: /dev/hdd1 is the BSD "a" partition /dev/hdd2 is the BSD "b" partition and so on. Hope that makes sense. To mount, say, the "d" partition from the second example as /media/bsd-d: # mkdir /media/bsd-d # mount -t ufs /dev/hdd10 /media/bsd-d Note that I don''t have a BSD drive handy so I can''t test this, but it''s what I''ve done in the past. The most important thing to remember is that if you have a mixed Linux and BSD drive, make SURE the BSD partition is AFTER any Linux extended partitions or you may get wrong partition assignments and screw up the BSD stuff. If all you''re interested in is getting the data off the BSD partitions and onto Linux partitions, then mount the BSD stuff read-only: # mount -t ufs -o ro /dev/hdd10 /media/bsd-d Good luck! ---------------------------------------------------------------------- - Rick Stevens, Principal Engineer rstevens@internap.com - - VitalStream, Inc. http://www.vitalstream.com - - - - Linux is like a wigwam...no windows, no gates...and apache inside! - ---------------------------------------------------------------------- _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Dylan Martin wrote:>>> Okay, here''s another question that no one will be able to answer. >>> >>> I have an OpenBSD HVM domU, and I wanted to mount its filesystem in >>> my Linux dom0. The domU''s disk lives on a logical volume. Kpartx >>> does detect that partition 4 contains the disklabel, but that''s as far >>> as I get. >>> >>> I think my fedora kernel just doesn''t support disklabels... >>> >>> Anyone know how this is supposed to work? >>> >>> >> So why use them. Disklabels for ext2 and ext3 are useful abut the >> partitions can still be accessed as /dev/hda1, /dev/VolGroup00/whatever, >> or if you use "kpartx -a /dev/VolGroup00/whatever" then you can access >> /dev/mapper/whatever0, /dev/mapper/whatever1, etc. >> >> Or did you do something too clever and use LVM instide of the OpenBSD >> DomU and need to go through extra arcanery? >> > > I think there is some file system label and disklabel confusion here. > Disklabel is like fdisk for bsd.. sort of. In PC hardware when > running bsd, you first have to partition your disk using fdisk. If > you''re only running one OS, you just make one partition with all the > space in it. Then you take that partition and break it up into > sub-partitions (for lack of a better word) using disklabel. I think > the reason for this has to do with PC hardware vs. other kinds that > don''t use dos-type partition tables. >Ahhh. Extended partitions! OK, that becomes more comprehensible. There''s frankly no reason to do it for Xen guest domains: Simply add the new host partitions as new drives, /dev/sda or /dev/xvda dep, and break them down into up to 4 individual sub partitions per the maximum classical "primary" partitions, unless you''re in love with the old multi-multi-partition model of /, /usr, /tmp, /var/tmp, /var, /var/spool, /usr/local, /lenny, /joey, /usr/var/beta/gamma/mygreat/ant/matilda/, etc. There were reasons to do that much partitoning 20 years ago when drives were much smaller and more expensive and gnu-tar didn''t exist yet and we did UNIX backups with "dump".: they''re mostly gone now..> Anyway, the upshot is that in order for Linux to see my OpenBSD > partitions, it would have to read the disklabel to know where my > filesystems are. > > Another way to say it is: > > [dom0 ...] > [lv ] > [fdisk part ] > [disklabel ] > [wd0a][wd0d].. > > -Dylan >It really sounds like an extended partition table residing on LVM partition. I''m sure there are tools to pull that out of a Linux Xen partition, I just don''t know what they are off the top of my head. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
2007/7/20, Dylan Martin <dmartin@sccd.ctc.edu>:> Okay, here''s another question that no one will be able to answer. > > I have an OpenBSD HVM domU, and I wanted to mount its filesystem in > my Linux dom0. The domU''s disk lives on a logical volume. Kpartx > does detect that partition 4 contains the disklabel, but that''s as far > as I get. > > I think my fedora kernel just doesn''t support disklabels... > > Anyone know how this is supposed to work?check /boot/config-<yourfc6kernel> for CONFIG_BSD_DISKLABEL=X as far as I know RHEL5 has it neither as module nor in-kernel and Fedora has it as a module, so it''s simply kldload, reading the mount error messages and off you go. For the other posters... the disk label defines slices, not partitions. those ain''t extended partitions either. this is a different scheme than msdos''s, a bit less stupid in it''s design. Florian -- ''Sie brauchen sich um Ihre Zukunft keine Gedanken zu machen'' _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Florian Heigl wrote:> For the other posters... > the disk label defines slices, not partitions. those ain''t extended > partitions either. > this is a different scheme than msdos''s, a bit less stupid in it''s design.Both, "slices" and "partitions" are used synonymously by the BSDs. Regards, Mark Weinem _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
2007/7/21, Mark Weinem <mark.weinem@alumni.uni-due.de>:> Florian Heigl wrote: > > > For the other posters... > > the disk label defines slices, not partitions. those ain''t extended > > partitions either. > > this is a different scheme than msdos''s, a bit less stupid in it''s design. > > Both, "slices" and "partitions" are used synonymously by the BSDs.I just tried to point out why kpartx can''t help accessing the OpenBSD data in wd0a|b Thanks for taking the chance of making that pointless. -- ''Sie brauchen sich um Ihre Zukunft keine Gedanken zu machen'' _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Florian Heigl wrote:> 2007/7/20, Dylan Martin <dmartin@sccd.ctc.edu>: >> Okay, here''s another question that no one will be able to answer. >> >> I have an OpenBSD HVM domU, and I wanted to mount its filesystem in >> my Linux dom0. The domU''s disk lives on a logical volume. Kpartx >> does detect that partition 4 contains the disklabel, but that''s as far >> as I get. >> >> I think my fedora kernel just doesn''t support disklabels... >> >> Anyone know how this is supposed to work? > > check /boot/config-<yourfc6kernel> for CONFIG_BSD_DISKLABEL=X > as far as I know RHEL5 has it neither as module nor in-kernel and Fedora > has it as a module, so it''s simply kldload, reading the mount error > messages and > off you go. > > For the other posters... > the disk label defines slices, not partitions. those ain''t extended > partitions either. > this is a different scheme than msdos''s, a bit less stupid in it''s > design. >I don''t have access to an SRPM or RPM capable box at this moment, but you might check out the centosplus kernels: they tend to track the RHEL kernels but turn on features like NTFS and possible this disklabel feature. _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Florian Heigl wrote:> 2007/7/21, Mark Weinem <mark.weinem@alumni.uni-due.de>: >> Florian Heigl wrote: >> >> > For the other posters... >> > the disk label defines slices, not partitions. those ain''t extended >> > partitions either. >> > this is a different scheme than msdos''s, a bit less stupid in it''s >> design. >> >> Both, "slices" and "partitions" are used synonymously by the BSDs. > > I just tried to point out why kpartx can''t help accessing the OpenBSD > data in wd0a|b > Thanks for taking the chance of making that pointless. >Was he correct that they''re used synonymously? If so, then the slices are what other operating systems call partitions, and your explanation was merely confusing. If not, what''s the difference? _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Florian Heigl wrote:> for sake of compatibilty or more complicated layouts it commonly looks > like this/ > disk -> dos partition label -> dos partition 1 -> bsd label -> slices 1-12>From the FreeBSD Handbook:"FreeBSD calls the PC BIOS partitions slices so as not to confuse them with traditional BSD partitions." BSD partitions are not called slices! So it''s disk -> dos partition label -> slice 1 (or dos partition 1) -> bsd label -> bsd partitions 1-12 Best regards, Mark Weinem _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
Hello, I''ve been experiencing an odd problem as of late with new domUs that I''ve created. My setup: Intel E6400 Core 2 Duo 4GB RAM 250GB LVM volume Debian 4.0 "Etch" as dom0 Xen 3.0.3 w/PAE / 2.6.18 kernel I''ve had this machine up and running since November/December (2006), and have made a number of paravirt domUs. Initially by hand, and then progressing onto the Debian xen-tools package and using xen-create- image. All domUs are Debian 4.0 "Etch" systems-- filesystems present as logical volumes on the LVM. All has been fine and dandy (and even continues to be fine and dandy-- with those original domUs), until some point when any newly created domUs created appear to have issues with DNS/SSH/NFS. Not sure WHY they have problems-- but it appears I haven''t been able to create a working domU using xen-create- image / manual debootstrap since February/March (I''d also attribute it to the release of Debian Etch.. but they''ve all been apt- get upgraded to the official Etch release over time). No clue why. What happens is often first noticed by SSH attempts. The first attempt to connect to a troubled VM often results in odd delays not present on the other "working" VMs, and then I get the infamous: "Disconnecting: Bad packet length wxxxyyyzzz" message. Subsequent connections tend to work, only to be booted with a similar "Bad packet length" message a few minutes later. NFS shares refuse to mount from the server (another VM on the same machine). "rpcinfo -p nfs_server" works, but after a curiously long delay. NFS mounts themselves claim "failed. NFS server is down." Also strange, one machine seemed to be having issues pinging another VM. There would be delays between icmp_seq lines, then it might go for 5-6 seemingly normal, only to act up again. I would end up getting about 11-25% packet loss just pinging another VM on the same machine. Installing the host utility and running "host problemvm" from the problemvm yields a mix of results-- sometimes it retrieves its DNS info just fine.. other times not... and still others, it''ll seem to "half" find it.. returning some malformed output. VMs get IPs via DHCP. resolv.conf is set up properly. In fact, as far as I can tell.. network and general machine configuration is identical as the working domUs. I''ve even dropped in copies of config files from working VMs, no luck. Now, I was suspecting possible DNS issues. I''ve checked... double checked.. had a couple other people check. Everything seems to be spelled correctly, IPs match, serial numbers appropriately updated... services restarted... no malformed line endings. So I really don''t know what could be the issue. Kernel, modules, initrd are the same as the working VMs. I''ve tried scouring the internet for others who may have experienced the same problems... nothing that seems to come anywhere close. I did find mention on the xen-devel list to some "nloopbacks" parameter that had been scaled down to 4 from 8. But if each VM is running generally only one VIF, is that even an issue? Now, I will say I am running, in addition to the dom0, 8-9 domUs on one system. I don''t know if there''s some internal limit I''ve unknowingly passed. I''ve tried booting up the "problematic" domUs first, then booting the known working ones.. no change-- the working domUs still work, the newer domUs do not. I had it suggested that there might be an issue with the bridge interface... but what? Is there some kernel limit to the number of bridges and vifs I can have? Any strategies to try and figure this out? It is truly perplexing. No strange errors are logged by the dom0... I wouldn''t think it would be hardware (ie memory)... as I can create a new domU and have it experience the same problems. In fact I have two such problematic domUs running right now.. and they''re both not working as I''d expect them to (while the other 7 working domUs are also up and running, seemingly working just fine). Any suggestions would be greatly appreciated. -Matthew -- Matthew Haas Visiting Instructor Corning Community College Computer & Information Science http://lab46.corning-cc.edu/haas/home/ "Writing should be like breathing; It is one of those important things we do." -- me _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users
On Tue Jul 24, 2007 at 14:34:24 -0400, haas@corning-cc.edu wrote:> Now, I will say I am running, in addition to the dom0, 8-9 domUs > on one system. I don''t know if there''s some internal limit I''ve > unknowingly passed.There are some limits, but not at those level of use you''re seeing.> Any suggestions would be greatly appreciated.I''d try running tcp dump to see if things look ''normal''. But my immediate suggestion is to see what happens if you disable TCP checksums. I''m not 100% sure when this was fixed, or if it ever was, but I''ve seen that solve similar problems (especially DNS/UDP related). If you''re using xen-create-image you should find the relevant line commented out in /etc/network/interfaces. Uncomment it and restart the domain. For reference: # post-up ethtool -K eth0 tx off (Don''t forget ''apt-get install ethtool''). Steve -- http://www.steve.org.uk/ _______________________________________________ Xen-users mailing list Xen-users@lists.xensource.com http://lists.xensource.com/xen-users