mbox

[Xen-devel,OSSTEST,v2,00/15] add distro domU testing flight

Message ID 1398681672.29700.55.camel@kazak.uk.xensource.com
State New
Headers show

Pull-request

git://xenbits.xen.org/people/ianc/osstest.git distro-flight-v2

Message

Ian Campbell April 28, 2014, 10:41 a.m. UTC
The following series adds a new flight type intended to test distro domU
support, i.e. running distro installers and kernels on top of current
Xen to ensure things work. I intend for the flight to be run on a weekly
basis, and I've scheduled it here to run at the weekend when in theory
things might be quieter.

I've initially just done Debian PV domU support since Debian is what I
know, but I hope others will add other distros as time goes on.

The series introduces support for running the Debian Installer in a PV
domU booting from netboot (PXE-ish) and netinst (ISO media) and adding
jobs to test all of those for Squeeze onwards up to Sid and the
daily/weekly builds.

The flight is a bit unusual since distro installer builds are not really
versioned in a way which is useful to osstest, so instead each flight
will be compared against the previous run only (this stuff needs testing
in production).

The new Debian install functionality here also gives us the opportunity
to test pygrub and pvgrub, so a couple of jobs are added to the regular
tests using installer images versioned via TftpDiVersion in the usual
way. This requires an early patch "mg-debian-installer-update: grab Xen
PV domU capable images too" to go in and a patch to update TftpDiVersion
to a refreshed version to be inserted before "Test pygrub and pvgrub on
the regular flights" is committed.

I've also pushed a branch, pull details at the end.

v1 of this[0] wasn't really a proper posting, but calling this v2 to
avoid any potential confusion.

Ian.

[0] http://article.gmane.org/gmane.comp.emulators.xen.devel/180019


The following changes since commit 0b5094e69de4c1a6cfb866d0cfe4d10ba655285c:

  crontab: Add a daily run of the libvirt branch. (2014-04-25 10:07:56 +0100)

are available in the git repository at:

  git://xenbits.xen.org/people/ianc/osstest.git distro-flight-v2

for you to fetch changes up to 95006fcc3c921467d85794d7f27f67232ad6597a:

  distros: Run a flight over the weekend. (2014-04-26 09:47:36 +0100)

----------------------------------------------------------------
Ian Campbell (15):
      cr-external-linux: remove
      Build against liblzma to support .xz compressed kernels
      mg-debian-installer-update: grab Xen PV domU capable images too
      TestSupport: Add helper to fetch a URL on a host
      TestSupport: Add helper to wait for a guest to shutdown
      TestSupport: allow overring of on_* in prepareguest_part_xencfg
      TestSupport: allow caller of prepareguest_part_xencfg to specify viftype
      Debian: add preseed_create_guest helper
      distros: add support for installing Debian PV guests via d-i, flight and jobs
      distros: support booting Debian PV (d-i installed) guests with pvgrub.
      distros: attempt pvgrub support for PV Wheezy too.
      distros: support PV guest install from Debian netinst media.
      Test pygrub and pvgrub on the regular flights
      distros: add branch infrastructure
      distros: Run a flight over the weekend.

 Osstest/Debian.pm          |  83 +++++++++++++++-
 Osstest/TestSupport.pm     |  32 ++++++-
 ap-fetch-version           |   4 +
 ap-fetch-version-old       |   3 +
 ap-print-url               |   3 +
 cr-daily-branch            |  11 ++-
 cr-external-linux          |  50 ----------
 cri-common                 |   1 +
 crontab                    |   1 +
 make-distros-flight        | 140 +++++++++++++++++++++++++++
 make-flight                |  39 ++++++++
 mg-debian-installer-update |  11 ++-
 sg-run-job                 |  11 +++
 ts-debian-di-install       | 233 +++++++++++++++++++++++++++++++++++++++++++++
 ts-xen-build-prep          |   2 +-
 ts-xen-install             |   2 +-
 16 files changed, 562 insertions(+), 64 deletions(-)
 delete mode 100755 cr-external-linux
 create mode 100755 make-distros-flight
 create mode 100755 ts-debian-di-install

Comments

Fabio Fantoni April 28, 2014, 11:30 a.m. UTC | #1
Il 28/04/2014 12:41, Ian Campbell ha scritto:
> The following series adds a new flight type intended to test distro domU
> support, i.e. running distro installers and kernels on top of current
> Xen to ensure things work. I intend for the flight to be run on a weekly
> basis, and I've scheduled it here to run at the weekend when in theory
> things might be quieter.
>
> I've initially just done Debian PV domU support since Debian is what I
> know, but I hope others will add other distros as time goes on.
>
> The series introduces support for running the Debian Installer in a PV
> domU booting from netboot (PXE-ish) and netinst (ISO media) and adding
> jobs to test all of those for Squeeze onwards up to Sid and the
> daily/weekly builds.
>
> The flight is a bit unusual since distro installer builds are not really
> versioned in a way which is useful to osstest, so instead each flight
> will be compared against the previous run only (this stuff needs testing
> in production).
>
> The new Debian install functionality here also gives us the opportunity
> to test pygrub and pvgrub, so a couple of jobs are added to the regular
> tests using installer images versioned via TftpDiVersion in the usual
> way. This requires an early patch "mg-debian-installer-update: grab Xen
> PV domU capable images too" to go in and a patch to update TftpDiVersion
> to a refreshed version to be inserted before "Test pygrub and pvgrub on
> the regular flights" is committed.
>
> I've also pushed a branch, pull details at the end.
>
> v1 of this[0] wasn't really a proper posting, but calling this v2 to
> avoid any potential confusion.
>
> Ian.

Thanks for adding also these very useful tests, currently I use nearly 
always debian on pv domUs.
Briefly looking at your patches it seems that you use pygrub also for 
domUs installation, I use the installer kernel and initrd directly 
instead, for example:
kernel = "/boot/domu/wheezy/vmlinuz" (from .../images/netboot/xen/)
ramdisk = "/boot/domu/wheezy/initrd.gz" (from .../images/netboot/xen/)
extra = ...

Is there some "special" reason to install domUs starting with pygrub 
instead of directly?
Since last year with recents grub2 of Sid the domUs don't boot anymore 
with pygrub and I use pvgrub2 instead, I haven't tried installation from 
pygrub instead of directly but perharps it has the same problem.
Is pvgrub2 test now missing on osstest?

Thanks for any reply.

>
> [0] http://article.gmane.org/gmane.comp.emulators.xen.devel/180019
>
>
> The following changes since commit 0b5094e69de4c1a6cfb866d0cfe4d10ba655285c:
>
>    crontab: Add a daily run of the libvirt branch. (2014-04-25 10:07:56 +0100)
>
> are available in the git repository at:
>
>    git://xenbits.xen.org/people/ianc/osstest.git distro-flight-v2
>
> for you to fetch changes up to 95006fcc3c921467d85794d7f27f67232ad6597a:
>
>    distros: Run a flight over the weekend. (2014-04-26 09:47:36 +0100)
>
> ----------------------------------------------------------------
> Ian Campbell (15):
>        cr-external-linux: remove
>        Build against liblzma to support .xz compressed kernels
>        mg-debian-installer-update: grab Xen PV domU capable images too
>        TestSupport: Add helper to fetch a URL on a host
>        TestSupport: Add helper to wait for a guest to shutdown
>        TestSupport: allow overring of on_* in prepareguest_part_xencfg
>        TestSupport: allow caller of prepareguest_part_xencfg to specify viftype
>        Debian: add preseed_create_guest helper
>        distros: add support for installing Debian PV guests via d-i, flight and jobs
>        distros: support booting Debian PV (d-i installed) guests with pvgrub.
>        distros: attempt pvgrub support for PV Wheezy too.
>        distros: support PV guest install from Debian netinst media.
>        Test pygrub and pvgrub on the regular flights
>        distros: add branch infrastructure
>        distros: Run a flight over the weekend.
>
>   Osstest/Debian.pm          |  83 +++++++++++++++-
>   Osstest/TestSupport.pm     |  32 ++++++-
>   ap-fetch-version           |   4 +
>   ap-fetch-version-old       |   3 +
>   ap-print-url               |   3 +
>   cr-daily-branch            |  11 ++-
>   cr-external-linux          |  50 ----------
>   cri-common                 |   1 +
>   crontab                    |   1 +
>   make-distros-flight        | 140 +++++++++++++++++++++++++++
>   make-flight                |  39 ++++++++
>   mg-debian-installer-update |  11 ++-
>   sg-run-job                 |  11 +++
>   ts-debian-di-install       | 233 +++++++++++++++++++++++++++++++++++++++++++++
>   ts-xen-build-prep          |   2 +-
>   ts-xen-install             |   2 +-
>   16 files changed, 562 insertions(+), 64 deletions(-)
>   delete mode 100755 cr-external-linux
>   create mode 100755 make-distros-flight
>   create mode 100755 ts-debian-di-install
>
>
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> http://lists.xen.org/xen-devel
Ian Campbell April 28, 2014, 11:32 a.m. UTC | #2
On Mon, 2014-04-28 at 13:30 +0200, Fabio Fantoni wrote:
> Is there some "special" reason to install domUs starting with pygrub 
> instead of directly?

I'm only doing this for netinst tests which use pygrub to extract the
kernel from the ISO image in a convenient way.

For netboot tests it does indeed download the kernel and boot it
directly.

> Since last year with recents grub2 of Sid the domUs don't boot anymore 
> with pygrub and I use pvgrub2 instead, I haven't tried installation from 
> pygrub instead of directly but perharps it has the same problem.
> Is pvgrub2 test now missing on osstest?

Nobody has contributed one yet.

Ian.
Fabio Fantoni April 28, 2014, 12:59 p.m. UTC | #3
Il 28/04/2014 13:32, Ian Campbell ha scritto:
> On Mon, 2014-04-28 at 13:30 +0200, Fabio Fantoni wrote:
>> Is there some "special" reason to install domUs starting with pygrub
>> instead of directly?
> I'm only doing this for netinst tests which use pygrub to extract the
> kernel from the ISO image in a convenient way.
>
> For netboot tests it does indeed download the kernel and boot it
> directly.

Thanks for your reply.

>
>> Since last year with recents grub2 of Sid the domUs don't boot anymore
>> with pygrub and I use pvgrub2 instead, I haven't tried installation from
>> pygrub instead of directly but perharps it has the same problem.
>> Is pvgrub2 test now missing on osstest?
> Nobody has contributed one yet.
>
> Ian.
>

These are my notes about the preparation and tests done of pvgrub2 
(which I'm also using on the new systems in productionwith Wheezy as 
dom0), maybe it can be useful for those who want to use it:

> -------------------------
> PVGRUB2 upstream
> ---
> aptitude install autogen libdevmapper-dev libfuse-dev unifont # some 
> are optionals but useful (other requirements if I am not mistaken are 
> included in the preparation of xen and qemu from source)
> git clone git://git.sv.gnu.org/grub.git
> ./autogen.sh
> ./configure --target=x86_64 --with-platform=xen
> make
> mkdir -p boot/grub/
> cat > boot/grub/grub.cfg <<'EOF'
> insmod lvm
> insmod ext2
> insmod part_msdos
> insmod part_gpt
> insmod btrfs
> insmod xzio
>
> insmod regexp
> for dev in (*); do
>     # $device: parenthesis removed from $dev
>     regexp -s device '\((.*)\)' $dev
>     set root=$device
>     for file in /boot/vmlinuz-* /boot/linux-*; do
>         if test -f $file; then
>             set saved_root=$root
>         fi
>     done
> done
> set root=$saved_root
>
> if test -f /boot/grub2/grub.cfg ; then
>     configfile /boot/grub2/grub.cfg
> elif test -f /boot/grub/grub.cfg ; then
>     configfile /boot/grub/grub.cfg
> fi
> EOF
> pkgdatadir=. ./grub-mkstandalone --grub-mkimage=./grub-mkimage -o 
> pvgrub2.xen -O x86_64-xen -d grub-core/ boot/grub/grub.cfg
> mv pvgrub2.xen /boot
> ---
> Note: it works only with domUs that have grub2, old domUs with grub1 
> must use pygrub instead
> -------------------------