333 Commits

Author SHA1 Message Date
John Chittum
c0af2ca443
fix: riscv64 efi conditional
missing a && between icicle and visionfive, led to /boot/efi still being
in place, and grub-install running instead of exiting the func.
fixes LP:2015750
2023-04-10 07:33:08 -05:00
Łukasz 'sil2100' Zemczak
4e49b4df60 Merge branch 'ubuntu/master' of git+ssh://git.launchpad.net/livecd-rootfs into canary-build 2023-04-05 20:50:27 +02:00
Łukasz 'sil2100' Zemczak
11a583d619 Initial implementation of canary image builds. 2023-04-05 20:49:16 +02:00
Heinrich Schuchardt
d42c7c5989 Add image for StarFive VisionFive 2
SUBARCH=visionfive2 is used to build images for the StarFive VisionFive 2
boards. For the device-tree we assume board revision 1.3B.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-04-05 15:08:04 +02:00
Michael Hudson-Doyle
1ecd1320d6 Merge remote-tracking branch 'xypron/required_partition' into ubuntu/master 2023-02-27 21:47:54 +13:00
Dimitri John Ledkov
ef072ea77a
Merge branch 'tune2fs' of git+ssh://git.launchpad.net/livecd-rootfs into ubuntu/master 2023-02-24 12:01:43 +00:00
Heinrich Schuchardt
eea1308301 RISC-V: avoid soft lockup Radeon GPUs with u-boot-menu
For the SiFive HiFive Unmatched board we create a pre-installed image using
u-boot-menu. Increase the watchdog threshold in this case too.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-02-13 22:05:22 +00:00
Heinrich Schuchardt
0924d50aee RISC-V: avoid soft lockup Radeon GPUs with GRUB
With Radeon GPUs and kernel 5.19 a soft lockup was observed.
Increase the watchdog threshold.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-02-10 20:55:11 +00:00
Heinrich Schuchardt
ee843c14de RISC-V: rename cmdline.cfg to 10_cmdline.cfg
Using numbered configuration fragments makes the order of application
easier to track

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-02-10 20:55:11 +00:00
Dimitri John Ledkov
dc3f8a6ea0
ubuntu-cpc: set default ext4 mount option commit=30
This allows to consolidate linux-kvm and linux-generic kernel
flavours. This brings the perfomance benefit of linux-kvm flavour to
all cloud and pre-installed images. It does trade data-safety.

LP: #2006511

Signed-off-by: Dimitri John Ledkov <dimitri.ledkov@canonical.com>
2023-02-07 20:58:53 +00:00
Heinrich Schuchardt
536cd09b73 riscv64: set attribute required partition for firmware
According to the EBBR specification the GPT partitions for firmware should
have attribute bit 0 (Required Partition) set.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-01-16 21:52:36 +01:00
Heinrich Schuchardt
71308d500b riscv64: adjust U-Boot installation for Nezha D1 and LicheeRV
Since version 2022.10 U-Boot SPL and U-Boot are installed onto the same partition.
Package nezha-boot0 is not needed anymore.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2023-01-09 11:52:44 +01:00
Heinrich Schuchardt
c6ad92c0f4 riscv64: use efi=debug earlycon
RISC-V boards tend to boot slowly.
We should provide progress information when booting.

Use 'efi=debug earlycon' on the Linux command line via new file
/etc/default/grub.d/cmdline.cfg.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-11-14 14:04:42 +01:00
Brian Murray
151f73e8b0 Finish the rename of FK_FORCE_CONTAINER into FK_FORCE. (LP: #1989194) 2022-10-17 13:01:45 -07:00
Łukasz 'sil2100' Zemczak
e8938fc610 Add an additional subdir. 2022-10-14 10:49:25 +02:00
Heinrich Schuchardt
b39824539c riscv: reduce initrd size for Nezha and LicheeRV boards
The Nezha and the LicheeRV boards do not have enough memory for an initrd
with most modules. Therefore the number of included modules has to be
reduced.

Create file /etc/initramfs-tools/conf.d/modules_list.conf
to set MODULES=list.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-10-13 08:05:47 +02:00
Heinrich Schuchardt
1555f5f46b riscv: remove invalid redirections
Remove redirections of type

    command &1>2

Executing the command in the background and creating and empty file '2'
was never intended.

As the messages are information only redirecting to stderr would not make
sense either.

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-10-13 08:05:47 +02:00
Alexandre Ghiti
a752a99ad8 riscv: LicheeRV must use u-boot-nezha package
Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-09-20 13:49:40 +02:00
Alexandre Ghiti
f68433098d riscv: Add support to build Microchip Icicle Kit image
Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-09-20 13:49:40 +02:00
Alexandre Ghiti
e8ea6335d5 riscv: Add support to build LicheeRV Dock images
The LicheeRV Dock board comes with only 512MB of DRAM so the only difference
with a Nezha image is the fact that we have to remove
cryptsetup-initramfs package which makes the initrd too big for the
board to boot.

Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-09-20 13:49:39 +02:00
Ivan Kapelyukhin
76d794664a
Bump UEFI disk image size for amd64 to 3.5 GB
Current Kinetic GCE image builds are failing with the following error:

update-initramfs: Generating /boot/initrd.img-5.19.0-1004-gcp
zstd: error 25 : Write error : No space left on device (cannot write compressed block)
E: mkinitramfs failure zstd -q -1 -T0 25

Seems like after `linux-gcp` update from 5.15 to 5.19 `linux-modules` package
has gotten ~40MB larger and with that GCE image builds are over the edge wrt
available disk space in chroot.

Bumped up disk image size for amd64 to 3.5GB to match the sizes used by armhf
and generic images.
2022-09-14 22:30:54 +02:00
William Wilson
ee40e951f2 releasing package livecd-rootfs version 2.778 2022-09-14 10:16:52 -05:00
Thomas Bechtold
480d5b26ea fix: don't modify ssh_config for ubuntu-cpc projects (LP:1968873)
The cloud-init bug (see LP:1968873) got fixed now so using a sshd
config snippet should work now.

This partly reverts commit aa1be5eaaa1fdbb4c31104cc49e54b15f66c3343
but uses now 60-cloudimg-settings.conf instead of
10-cloudimg-settings.conf .
2022-09-09 12:08:45 +02:00
Steve Langasek
239453d644 Remove modemmanager and udisks2 from cloud images in addition to fwupd. The use of tasks at install means all packages are marked manually installed in the apt database, so removing fwupd does not remove its dependencies. LP: #1981109. 2022-08-04 11:24:53 -07:00
Łukasz 'sil2100' Zemczak
e760da3284 When adding the new RISC-V platforms, some of the generic non-SUBARCH code went missing and some invalid assumptions have been made, causing cloud images to fail building. 2022-07-29 17:44:33 +02:00
Steve Langasek
941cd3c64a Remove fwupd from the cloud images. LP: #1981109. 2022-07-25 13:02:06 -07:00
Alexandre Ghiti
17e659ddf8 riscv: Fix SiFive Unmatched build
While merging the VisionFive support, we removed the installation of
u-boot-menu for the Unmatched by mistake: fix this by reinstating it.

Fixes: ce9f5caccadf ("riscv: Add support for StarFive VisionFive")
Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-25 09:36:43 +02:00
Łukasz 'sil2100' Zemczak
c5571b17a2 Merge branch 'int/alex/riscv_no_beaglev_container' of https://git.launchpad.net/~alexghiti/livecd-rootfs into ubuntu/master 2022-07-14 14:33:25 +02:00
Thomas Bechtold
aa1be5eaaa Revert "fix: don't modify ssh_config for ubuntu-cpc projects (LP:1968873)"
This change triggered a bug in cloud-init (see LP:1968873). cloud-init
does not recongnize sshd options set in /etc/ssh/sshd_config.d/ and
cloud-init modifies directly /etc/ssh/sshd_config which gets then
overwritten by settings from /etc/ssh/sshd_config.d/ .

This reverts commit b54d24ff3310f7ace00ab08e0dacfdc89e026f1c.
2022-07-11 14:08:48 +02:00
Alexandre Ghiti
00f35ae9bf riscv: Use FK_FORCE_CONTAINER to force flash-kernel to run in a container
As explained in LP: #1980929, we need this in order to build RISC-V
images.

Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-11 12:47:16 +02:00
Alexandre Ghiti
7a1b5f67dd disk-image-uefi.binary: Fix wrong parenthesis
Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-08 15:00:05 +02:00
Alexandre Ghiti
42b68d5d0f riscv: Bump image size to 4.5G
3.5G is not enough for riscv64 preinstalled as the creation of the initrd fails
with the following error:

Creating config file /etc/default/grub with new version
Processing triggers for initramfs-tools (0.140ubuntu13) ...
update-initramfs: Generating /boot/initrd.img-5.15.0-1011-generic
zstd: error 25 : Write error : No space left on device (cannot write compressed block)
E: mkinitramfs failure zstd -q -1 -T0 25
update-initramfs: failed for /boot/initrd.img-5.15.0-1011-generic with 1.
dpkg: error processing package initramfs-tools (--configure):
 installed initramfs-tools package post-installation script subprocess returned error exit status 1

Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-05 11:40:24 +02:00
Alexandre Ghiti
74e9088bbc riscv: Use UEFI bootflow for the Nezha Board
Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-05 11:40:24 +02:00
Alexandre Ghiti
6224b11fc0 riscv: Add support for StarFive VisionFive
The image created uses a UEFI bootflow, so we install grub for this board
only. We also need flash-kernel to install the dtb where grub can find
it.

This image is specifically architectured so that it can be installed on
a "factory" board, meaning using the u-boot firmware which was
originally implemented for Fedora, so we need the p3 partition that
embeds a uEnv.txt file to tell u-boot what/where to load next stage.

Signed-off-by: Alexandre Ghiti <alexandre.ghiti@canonical.com>
2022-07-05 11:40:24 +02:00
Alexandre Ghiti
f751ff7218 RISC-V: enable building for Nezha board
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-07-05 11:40:24 +02:00
Heinrich Schuchardt
46711a9af6 riscv: define partitioning scheme for Nezha board
Define the image layout for the Nezha board.

The U-Boot SPL based boot0 may be installed starting in sector 16 or 256.
As sector 16 is incompatible with GPT partitioning use sector 256.

The primary U-Boot image is expected to start at sector 32800 and its
backup in sector 24576.

Cf. https://linux-sunxi.org/index.php?title=Allwinner_Nezha&oldid=24469

Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2022-07-05 11:40:24 +02:00
Utkarsh Gupta
cb099966b2 Merge remote-tracking branch 'simpoir/lp1970795-jammy-ova-cdrom' into ubuntu/master
* simpoir/lp1970795-jammy-ova-cdrom:
  fix: VMware cdrom OVF import requires to be on IDE
2022-06-29 13:30:26 +05:30
Thomas Bechtold
b54d24ff33 fix: don't modify ssh_config for ubuntu-cpc projects (LP:1968873)
Modifying directly /etc/ssh/sshd_config creates "problems" when
upgrading eg. from Focal to Jammy because the upgrade will ask the
user what to do with the modified config. To avoid that, put the
custom configuration into /etc/ssh/sshd_config.d/ so the upgrade of
openssh-server can just replace /etc/ssh/sshd_config without asking
the user.
2022-06-28 14:21:56 +02:00
Simon Poirier
3da8e81bf2 fix: VMware cdrom OVF import requires to be on IDE
This reverts part of a change causing regression with vmware import due to the
cdrom getting moved to SCSI while shifting controller IDs. (LP: #1970795)
2022-06-11 13:17:48 -04:00
John Chittum
5c8aa8447e
fix: move Vagrant 22.04+ to ephemeral ed25519 key
LP: 1969664 tracks an issue related to the deprecation of rsa+ssh on
Jammy+ openssh server, coupled with upstream vagrant bugs, that cause
Jammy vagrant images fail to bootstrap due to ssh negotiation issues.
Moving to a different key algo from the upstream insecure key matches
Jammy's expectations, and works with older vagrant versions.

vagrant >= 2.2.16 hosts are unaffected by the issue, as an upstream
change was made. This change keep compatibility with newer vagrant
versions as well.
2022-04-21 09:13:37 -05:00
Jean-Baptiste Lallement
c4cb3570a5 Readd ubuntu-cpc/wsl.binary hook
Readding this file per reviewer's request until CPC splits the
pipelines. Removing this file would make CPC image builds fail.

Co-authored-by: Didier Roche <didrocks@ubuntu.com>
2022-03-21 12:19:30 +01:00
Jean-Baptiste Lallement
80ccea8d63 Separate WSL from CPC
Create a separate WSL image than CPC so it can be managed independently.

Co-authored-by: Didier Roche <didrocks@ubuntu.com>
2022-03-17 10:11:39 +01:00
Ivan Kapelyukhin
b40ce74fd6
perf(cpc): split disk-image-uefi out of disk-image series file
Due to how `disk-image` file is structured, it builds BIOS and UEFI
images at the same time. However, certain images (e.g., GCE images)
require only UEFI image to be built, BIOS image is being simply
discarded. This results in longer build times.

Splitting out `disk-image-uefi` would allow images to use it instead of
`disk-image` and thus avoid building unused BIOS images.

`disk-image` now depends on `disk-image-uefi` for backward
compatibility.
2022-03-03 15:44:01 +01:00
Łukasz 'sil2100' Zemczak
32b54e6242 Merge branch 'partalign' of https://git.launchpad.net/~xypron/livecd-rootfs into ubuntu/master 2021-12-16 12:25:05 +01:00
Brian Murray
fe662c5c8a Merge remote-tracking branch 'jessica-youjeong/111721-ubuntu-master-ova' into ubuntu/master 2021-12-15 10:06:54 -08:00
Heinrich Schuchardt
b6701e556f riscv64: ensure reasonable partition alignment
Currently the RISC-V preinstalled server images come with partitions that
are only 1 KiB aligned. Ext4 may use 4 KiB block size. The existing
misalignment leads to decreased performance.

Decrease the size of the loader2 partition by 34 512-byte blocks. This
results in 1 MiB alignment of the EFI and root partitions.

The remaining loader2 partition size of close to 4 MiB is still large
enough for U-Boot or a future EDK II.

Fixes: a808b28d47ec ("riscv64: build preinstalled riscv64 image with uboot SPL and CIDATA.")
Signed-off-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
2021-12-01 18:22:02 +01:00
Thomas Bechtold
1a7e9ca8c9 Bump UEFI disk image size for armhf to 3.5 GB
Current jammy builds fail with:
dpkg: error processing archive /var/cache/\
  apt/archives/grub-common_2.04-1ubuntu48_armhf.deb (--unpack):
cannot copy extracted data for './usr/share/grub/unicode.pf2' \
  to '/usr/share/grub/unicode.pf2.dpkg-new': \
  failed to write (No space left on device)
2021-11-23 11:30:47 +01:00
Jess Jang
a97e98c968 Change serial0 allocation as false (LP:#1895104)
It hangs during booting when upgrading hardware
version ESXi after deploying image in groovy.
(Current default version is 10)
It could be resolved by adding serial port in VM
when vm version is larger than 10.

Seriaol port1 has been configured as default so
we need to change setting serial0 as false.
2021-11-17 07:50:19 -06:00
Didier Roche
6a05e7fa22 Install desired already seeded snap in wsl.
As wsl is an image target of ubuntu-cpc, the base seed is hardcoded to
ubuntu-server instead of wsl one. For now, add it, as for the other
cpc images, in hooks.
2021-11-05 17:51:52 +01:00
Chloé Smith
ffab8ceac4
Add a serial port to OVF template (LP: #1895104)
groovy hangs during boot on ESXi when the version is greater than
10. Adding a serial port by default fixes this specific bug - increasing
the HW version will be for another branch.

This is because more investigation is needed into whether it is possible to
increment ddb.virtualHWVersion without disrupting Oracle VirtualBox images.
2021-06-21 21:29:47 +01:00