Skip to contentSkip to conversation

osstest: minor fixlets for standalone mode

PATCH New Ian Campbell 1 participant 4 messages Jan 11, 2013

lore
Share & tools
lore
#0 lore raw

cover osstest: minor fixlets for standalone mode

A couple of pretty minor fixes which improve standalone mode for me (I have a machine next to my desk with VGA but no serial which I wanted to install Wheezy on). Plus set a default password for guests.

ts-host-install/Debian: improvements for standalone mode.
OssTest: Debian: Wheezy compatible preseed.
ts-debian-install: Set a default root password

These are all based on the standalone branch of osstest.git.

In my ~/.xen-osstest/config I have (along with the usual stuff):

DebianSuite wheezy
HostProp_h09_NoSerial 1
HostProp_h09_Suite wheezy
HostProp_h09_DIFrontend newt

Ideally I would like to be able to choose DebianSuite on a per-host basis, either at ./ts-host-install time (best) or by just the HostProp_<host>_<Suite> setting.

I needed to also set DebianSuite because standalone-reset downloads that version of d-i to the PXE space. Also since the path it uses under doesn't include the suite I also needed to blow
away /usr/groups/netboot/ianc/osstest/ before running standalone-reset.

Ian.

#1 lore raw

PATCH 1/3 ts-debian-install: Set a default root password

Without this xen-create-image will generate a random password (and print it in the logs) but for standalone use this is more convenient.

---
 ts-debian-install |    1 +
 1 file changed, 1 insertion(+)
ts-debian-install +1 -0
index 2948ef6..9c5193b 100755
@@ -57,6 +57,7 @@ sub ginstall () {
             --hostname $gho->{Name} \\
             --lvm $gho->{Vg} --force \\
             --kernel $kernpath \\
+            --genpass 0 --password xenroot \\
             $initrd_opt \\
             $archarg
 END
Signature · 1 line
1.7.10.4
#2 lore raw

PATCH 2/3 OssTest: Debian: Wheezy compatible preseed.

In reply to Ian Campbell

Keyboard configuration preseed has changed in wheezy, use keyboard-configuration/xkb-keymap (wheezy) as well as console-keymaps-at/keymap (pre-wheezy).

---
 Osstest/Debian.pm |    1 +
 1 file changed, 1 insertion(+)
Osstest/Debian.pm +1 -0
index 556a20f..157f666 100644
@@ -426,6 +426,7 @@ d-i mirror/suite string $suite
 
 d-i debian-installer/locale string en_GB
 d-i console-keymaps-at/keymap select gb
+d-i keyboard-configuration/xkb-keymap string en_GB
 
 #d-i debconf/frontend string readline
 
Signature · 1 line
1.7.10.4
#3 lore raw

PATCH 3/3 ts-host-install/Debian: improvements for standalone mode.

In reply to Ian Campbell

Add a per-host option to not use serial, in case the test box only has VGA.

Also allow the user to configure which Debian Installer frontend to use, again useful in standalone mode (where you might actually be watching it)

---
 Osstest/Debian.pm |    3 ++-
 README            |   15 ++++++++++++---
 ts-host-install   |    3 ++-
 3 files changed, 16 insertions(+), 5 deletions(-)
Osstest/Debian.pm +2 -1
index 157f666..8df3d3b 100644
@@ -281,9 +281,10 @@ sub di_installcmdline_core ($$;@) {
                auto=true preseed
                hw-detect/load_firmware=false
                DEBCONF_DEBUG=5
-               DEBIAN_FRONTEND=text
                );
+    my $difront = get_host_property($tho,'DIFrontend','text');
     push @cl, (
+               "DEBIAN_FRONTEND=$difront",
                "hostname=$tho->{Name}",
                "url=$ps_url",
                "netcfg/dhcp_timeout=150",
README +12 -3
index 5808266..418aac4 100644
@@ -74,10 +74,19 @@ HostProp_<testbox>_Ether
    MAC address of the box <testbox>.  Only needed if you want
    to use the osstest host and Xen installer.
 
+HostProp_<testbox>_NoSerial
+   Set to 1 if <testbox> has no serial, system will use VGA console
+   instead.
+
+HostProp_<testbox>_DIFrontend
+   Configure the frontend used by Debian installer. Default in osstest
+   is a very basic "text" interface but for standalone configurations,
+   especially on VGA, "newt" might be preferred.
+
 DebianPreseed
-  Text to add to the debian-installer preseed file.  Optional
-  but you will need to set some NTP servers here if your firewall
-  doesn't permit NTP to Debian's pool.ntp.org servers.
+   Text to add to the debian-installer preseed file.  Optional
+   but you will need to set some NTP servers here if your firewall
+   doesn't permit NTP to Debian's pool.ntp.org servers.
 
 ========================================
 
ts-host-install +2 -1
index 6028526..f97b222 100755
@@ -161,7 +161,8 @@ END
         get_host_property($ho, "install-append $ho->{Suite}", '');
 
     push @installcmdline, qw(--);
-    push @installcmdline, "console=ttyS0,$c{Baud}n8";
+    push @installcmdline, "console=ttyS0,$c{Baud}n8"
+	unless get_host_property($ho, "NoSerial", "0");
 
     my $installcmdline= join ' ', @installcmdline;
 
Signature · 1 line
1.7.10.4