In some situations, when growvols run on disk which was already used or
growvols runs on the same driver, pvcreate finds old VG signature and
refuse to re-create PV on a block device.
[ERROR] Running command failed: cmd "pvcreate /dev/sda6", stdout "",
stderr " Can't initialize physical volume "/dev/sda6" of volume group
"vg" without "-ff" /dev/sda6: physical volume not initialized.
Closes-Bug: 2069487
Change-Id: Ie8e0641d5637e8c0c2edb23e820bc7961b7d319b
The square brackets cause the check to fail because of the piped
grep.
Removing them works just fine.
Change-Id: I85dfaa436d09edf958315579c7050165b80bf721
With noble the structure of the apt sources file has changed.
(see https://repolib.readthedocs.io/en/latest/deb822-format.html)
This brakes the current implementation for setting mirrors when building images.
Change-Id: I2ba0344b49c78e499ead681338e1a2c275e8e6f1
Continue is not valid, and in the current syntax usage for 80-simple-init,
the error is logged. Swapped to true to act as a no-op.
/tmp/in_target.d/post-install.d/80-simple-init: line 30: continue: \
only meaningful in a `for', `while', or `until' loop
Change-Id: I9ddb9aadc1114c0f4dea14d31b9751d83a887a6b
If your using configuration drive, cloud init tries to DHCP by
default anyway, which delays the boot sequence as it seeks out a
network attached metadata source.
So instead, disable the automatic activation so the configuration
drive data source is acutally leverage. Additionally add further
notes to provide guidance to users of DIB.
Change-Id: Ie7c522f23deb3f08ee4ec002e0e2020f382359aa
Currently a partition image with existing EFI assets may produce an
invalid image because the EFI grub.cfg may reference a partition UUIDs
that don't exist in the partition image case.
This change replaces the EFI grub.cfg if the EFI directory exists at
all, ensuring the EFI grub.cfg is valid in more cases.
Also, add missing EFI_BOOT_DIR for fedora-container element.
Change-Id: Id4f8cd2cb16bbb1a392f531cf5b8455f81162c42
This is included in the container itself, and should not be removed.
Ref. change: 899372
Change-Id: Ib00e11c7af8202935e808a297c34a1a6982bd2c7
Signed-off-by: Birger J. Nordølum <contact@mindtooth.no>
Since 2.4.0 disk-image-create does not export DIB_IMAGE_ROOT_FS_UUID
anymore. This patch fix documentation and the iso element.
Closes-Bug: 1699273
Change-Id: I5e926c36256e580579bfd2c5aeff4ba6193c367a
The dnf-plugins-core repo updates its download command to use a
dnf.utils method that is not present in the dnf version installed by
Debian packages. Update the fetch of dnf-plugins-core to use the last
version of the download plugin that is compatible with the dnf package
in Debian.
Note that we don't use the bookworm dnf-plugins-core package to address
this because dnf-plugins-core specifies that it breaks and replaces
zypper. This occurs due to the collision of a single manpage filename.
OpenSUSE addresses this by moving one of the manpages to a different
location allowing zypper and dnf to be installed together on SUSE
distros. Hopefully Debian will manage to do similar eventually.
Change-Id: I3a029340f9635f54570e48a68a9e2c1b1e30a76f
This will allow us to debug potentially bad fedora download backend
locations that don't provide valid subreleases in file paths. To do this
we ask curl to write headers (-i) and then dump the headers (-D) to
stderr. This should keep the debug info out of the parsing path for
subrelease info.
Change-Id: I07dd6ec4087191e1c688968be2fe1a1423a26b9e
This patch contains the known set of changes needed to make a gentoo
image build successfully.
- Standardize use of GENTOO_EMERGE_DEFAULT_OPTS, reduce duplication of
options set there.
- Correct the cleanup commands to reflect standard Gentoo good
practices by omitting --complete-graph, which is unneeded with --deep,
and using --changed-use instead of --newuse to reduce unneeded package
churn.
- Stop using deprecated layman command to manage reposiotry overlays,
instead use new supported eselect-repository
- Set new USE flags required for LVM and installkernel. This was
communicated via a Gentoo news item and is a required cleanup.
- Remove now-invalid skip of gpg if using musl
This is the set of changes needed to get the CI job passing and make DIB
build images at all, and we'd like to land them, but there are still
items we'd like to complete to enhance Gentoo support in DIB:
- Optional, built-in support for Gentoo binhosts -- where you can set a
DIB_GENTOO_BINHOST=true (or similar) and have the binhost enabled by
default.
- Make the default configuration of EMERGE_DEFAULT_OPTS more easily
managed in a DIB-style manner, e.g. setting --quiet vs --verbose based
on the value of DIB_DEBUG_TRACE.
Signed-Off-By: Jay Faulkner <jay@jvf.cc>
Signed-Off-By: Sam James <sam@gentoo.org>
Co-Authored-By: Sam James <sam@gentoo.org>
Change-Id: Idab82a9fa986fcc56fe4e1e1bf0445c7306b2858
OpenSUSE Leap 15.3 is out of support since 2022. This patch remove the
support of OpenSUSE Leap 15.3 and replace it with the OpenSUSE Leap
15.5.
Add the grub2-x86_64-efi package in the pkg-map of the bootloader
element to allow EFI support.
Replace version 15.3 to 15.5 in every required location.
Add dracut-mkinitrd-deprecated package in package-installs.yaml of
the opensuse element to support the usage of the deprecated mkinitrd
command from the zypper element.
Change-Id: Ie903ffcf229d8e32374c4a1346b5295990c83ff4
Turns out, some kernels on some versions of hardware, can
fail to boot when the hardware clock timer is not explicitly
checked. Normally, with virtual machines, you want to disable
the timer check, becuase the virutal machine inherently gets time
slices, and checking the timer can create issues booting.
Co-Authored-By: Ella Shulman <eshulman@redhat.com>
Change-Id: I8b9697ba60748bfe1e1e1914f24f207439cda2f1
I380b9638cd28f5771530089c558ef5ab638c0173 introduced a bug where it
would ask for cloud-init to be uninstalled even if the package was
already not installed. We handle that here by filtering the uninstall
list down to only packages that are already installed.
One drawback to this filtering is that if it's not presented with a list
of category/packagename formated packages it can result in false
positives (failing to remove). This type of behavior was always an
issue for install as well, for instance acct-user/puppet and
app-admin/puppet both have the puppet package name but different
categories.
also fixes root.d to download the images again
also also uses the merged-usr profile for systemd
https://www.gentoo.org/support/news-items/2022-12-01-systemd-usrmerge.html
Change-Id: Ib67aa91c64be2fcc7d9df324918edfc080237528
Signed-off-by: Matthew Thode <mthode@mthode.org>
In the san case the "disk" device will be of type "mpath", this change
adds "mpath" to the allowed partition types to treat as the primary
device.
Full unit test coverage has been added using an actual mpath lsblk
output to validate behaviour.
Change-Id: Id593d32e64abdb2ce4b3fd2e43f89fe262d374d1
These are written to import the python utility into the unittest as a
module, which is then tested. Python 3.12 removed "imp" which broke
this.
The documentation discusses using spec_from_file_location [2] for this
task, but one complication is that it only allows files with an
extension of .py to load like that ... so add an additional hack so
that the importlib loader will read the file.
[2] https://docs.python.org/3/library/importlib.html
Change-Id: I3c842b3a712ead6d2151b90171f9228caecedd11
Currently the images lack some packages like linux-firmware and
microcode_ctl, installing 'Minimal Install' group adds those and
some others that are expected to be on a VM or bare metal.
--allowerasing is used to remove coreutils-single and curl-minimal
which conflict with their fully fledged equivalents.
Change-Id: I08a6f8cb7b0440652c3496056ca9aee8213edc4d
It prevents NetworkManager from automatically running DHCP on
unconfigured ethernet devices and allows connections with static IP
addresses to be brought up even on ethernet devices with no carrier.
This is default in Server or Server with GUI RHEL installations.
Change-Id: I15f4a28a257dc1b30f8957fd9ad41aef3c9de385
This patch proposes a new element which installs fail2ban on the final
image. More crucially, a custom jail.local is injected during built
time which is a useful feature for cloud admins.
Change-Id: I47b90bbf3809cd6f90148b848b2afe4233be79d7
Signed-off-by: Charalampos Kominos <hkominos@gmail.com>
When using simple-init, we are making an explicit choice
along the lines of "I want the simple tool to do the simple needful"
which works well, except when cloud-init tries to run because it
is already baked into the source image diskimage-builder started
with.
So what would happen is Glean would execute from simple-init,
and then cloud-init would get launched by default, and cloud-init
in some cases everything is DHCP, so suddenly any static
configuration, such as what might be in an attached configuration
drive, is stomped upon resulting in an unreachable instance if
DHCP is just not available.
If DHCP is available, generally this is not an issue and goes
un-noticed, yet can add a substantial amount of time to the
boot sequence "waiting" for meta-data endpoints which may
not exist.
Change-Id: I380b9638cd28f5771530089c558ef5ab638c0173
All relatively modern cloud-inits are capable of creating default user
as well as granting root privileges for them. Currently
cloud-init creates pretty much the same sudoers file.
So running steps under the new DIB_DEBIAN_CLOUD_INIT_HELPER
does not make sense for last couple of Debian releases.
Change-Id: I3cebd318f1f0313bba00ecf639328978d3ad0f32