Page MenuHomeVyOS Platform

Unable to build the ISO for VyOS 1.2.0
Closed, ResolvedPublicBUG

Description

Built process fails at:

Unpacking vyatta-quagga (0.99.20.1-14+vyos2+current1) ...
dpkg: error processing archive /var/cache/apt/archives/vyatta-quagga_0.99.20.1-14+vyos2+current1_amd64.deb (--unpack):
 trying to overwrite '/usr/share/man/man1/vtysh.1.gz', which is also in package frr 6.1-dev-vyos-1~debian8+1

and

Errors were encountered while processing:
 /var/cache/apt/archives/vyatta-quagga_0.99.20.1-14+vyos2+current1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

I've tried now on a native Debian 8 install as well as Docker. Steps are a bone-stock, no submodules pulled:

git clone https://github.com/vyos/vyos-build.git
cd vyos-build
docker build -t vyos-builder .
docker run -it --privileged -v /HOST_PATH_OF_VYOS_BUILD_REPO:/vyos -w="/vyos" vyos-builder bash
./configure
make iso

Details

Difficulty level
Unknown (require assessment)
Version
1.2.0-rc9
Why the issue appeared?
Will be filled on close

Event Timeline

In the latest rolling update build for AWS AMI there is no quagga package, because it was replaced by FRR. Should be the same for regular build.

@begetan Yeah, very strange. I need to check why this issue re-appeared, hope I'll get it fixed by tomorrow.

http://dev.packages.vyos.net/repositories/current/vyos/dists/unstable/main/binary-amd64/Packages contains the wrong package.
faulty one: http://dev.packages.vyos.net/repositories/current/vyos/pool/main/v/vyatta-cfg-quagga/vyatta-cfg-quagga_0.18.172_amd64.deb

Package: vyatta-cfg-quagga
Version: 0.18.172
Depends: sed (>= 4.1.5), perl (>= 5.8.8), procps (>= 1:3.2.7-3), coreutils (>= 5.97-5.3), vyatta-cfg (>= 0.18.56), vyatta-cfg-system (>= 0.19.125), libc6 (>= 2.7-6), vyatta-bash | bash (>= 3.1), vyatta-quagga (>= 0.99.15-26) <------

Correct one but unknown (missing in Packages):
http://dev.packages.vyos.net/repositories/current/vyos/pool/main/v/vyatta-cfg-quagga/vyatta-cfg-quagga_0.19.1+vyos2+current5_all.deb

Package: vyatta-cfg-quagga
Version: 0.19.1+vyos2+current5

Depends: sed (>= 4.1.5), perl (>= 5.8.8), procps (>= 1:3.2.7-3), coreutils (>= 5.97-5.3), vyatta-cfg (>= 0.18.56), vyatta-cfg-system (>= 0.19.125), libc6 (>= 2.7-6), vyatta-bash | bash (>= 3.1), frr (>= 6.1) <------
, ipaddrcheck (>= 1.1)

I rebuilt the package (vyatta-cfg-quagga) which removed the old one from the repo and re-published the correct version. I tested with apt that the correct packages is being queried/installed. Looks all good now from my point of view.

apt-cache show vyatta-cfg-quagga
Package: vyatta-cfg-quagga
Version: 0.19.1+vyos2+current5
Architecture: all
Maintainer: VyOS Package Maintainers <[email protected]>
Installed-Size: 8276
Depends: sed (>= 4.1.5), perl (>= 5.8.8), procps (>= 1:3.2.7-3), coreutils (>= 5.97-5.3), vyatta-cfg (>= 0.18.56), vyatta-cfg-system (>= 0.19.125), libc6 (>= 2.7-6), vyatta-bash | bash (>= 3.1), frr (>= 6.1), ipaddrcheck (>= 1.1)
Suggests: util-linux (>= 2.13-5), net-tools, ethtool, ncurses-bin (>= 5.5-5), ntpdate
Priority: extra
Section: contrib/net
Filename: pool/main/v/vyatta-cfg-quagga/vyatta-cfg-quagga_0.19.1+vyos2+current5_all.deb
Size: 133054
SHA256: b3cbc355dbf90c72bad81980b7fdf56660f703e660954f5fbe0dfa1c91904618
SHA1: fa156ca02615d19ba9e1426b960dd1953e4f3da4
MD5sum: 51409655d6ad2b52611a35afb8f799da
Description: VyOS configuration templates/scripts for Quagga
VyOS configuration templates and scripts for Quagga
Description-md5: 35638667a28de2b287a4df2e05552b31

root@T1065:/home/vyos# apt-cache madison vyatta-cfg-quagga
vyatta-cfg-quagga | 0.19.1+vyos2+current5 | http://dev.packages.vyos.net/repositories/current/vyos/ current/main amd64 Packages
root@T1065:/home/vyos# apt-cache policy vyatta-cfg-quagga
vyatta-cfg-quagga:

Installed: 0.19.1+vyos2+current5
Candidate: 0.19.1+vyos2+current5
Version table:

http://dev.packages.vyos.net/repositories/current/vyos/dists/current/main/binary-amd64/Packages looks now good as well.

hagbard changed the task status from Open to In progress.Dec 4 2018, 11:54 PM
hagbard triaged this task as Low priority.

https://downloads.vyos.io/rolling/current/amd64/vyos-1.2.0-rolling%2B201812050041-amd64.iso

@kroy or @runar
Can please one of you test if the build outside ci is working again too? Shouldn't make any difference, but before I close this bug I'd like to have confirmation (and happy faces) from one of you as well.

@hagbard

It's actually failing somewhere else now:

dpkg: error processing archive /var/cache/apt/archives/vyatta-util_0.13+vyos2+current1_amd64.deb (--unpack):
 trying to overwrite '/opt/vyatta/sbin/ipset-check-member', which is also in package vyatta-cfg 0.102.0+vyos2+current4

When then of course leads to:

Errors were encountered while processing:
 /var/cache/apt/archives/vyatta-util_0.13+vyos2+current1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

@kroy please make sure that you do it from a clean build tree. I run it now locally from home and everything is working well. You can also do a ./configure --debug && make iso, which is more verbose.

@hagbard Thanks! I guess I was just running make clean. Removing the build directory and rerunning configure seems to have corrected it.

Actually I spoke too soon. The next run resulted in this, on a 100% fresh build tree.

The following packages have unmet dependencies:
 vyatta-cfg-system : Depends: ddclient (>= 3.8.2+vyos2+lithium6) but it is not going to be installed
                 Depends: vyatta-dhcp3-client (>= 4.1.8+vyos2+lithium3) but it is not going to be installed

I am still having issues building the ISO. I have deleted the vyos-build directory and trying again from scratch.

I am still getting an error building the ISO.

[2018-12-05 06:12:11] lb binary_linux-image
P: Begin install linux-image...
cp: cannot stat ‘chroot/boot/initrd.img-*’: No such file or directory
P: Begin unmounting filesystems...
P: Saving caches...
Reading package lists...
Building dependency tree...
Reading state information...

When I look at the files in the build directory. I see vyos-1.2.0-rolling+201812050555-amd64.iso. And this file is a reference to live-image-amd64.hybrid.iso, but the live-image ISO does not exist.

Am I doing something incorrectly?

Max.

@hagbard

Okay, I think I've nailed down what's going on. A fresh build with no modules (git clone, configure, make iso), works fine.

But pulling a submodule, even without any changes, makes the ISO unbuildable:

git submodule update --init packages/vyatta-cfg-system
cd packages/vyatta-cfg-system
debuild -us -uc
cd /vyos
./configure
make iso

Fails with:

The following packages have unmet dependencies:
 vyatta-cfg-system : Depends: ddclient (>= 3.8.2+vyos2+lithium6) but it is not going to be installed
                     Depends: vyatta-dhcp3-client (>= 4.1.8+vyos2+lithium3) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

That looks liek a similar f'up. The correct ddclient version is 3.8.2+vyos2+current1, no idea where lithium6 comes from. The correct pkg is within the repo: http://dev.packages.vyos.net/repositories/current/vyos/pool/main/d/ddclient/ddclient_3.8.2+vyos2+current1_all.deb and the current vyatta-cfg-system has no dependency to vyatta-dhcp3-client (https://github.com/vyos/vyatta-cfg-system/blob/current/debian/control).

Still not sure what's going on, but it feels very strange.

There are definitely strange happenings.

Started fresh again.

  • Pulled vyatta-cfg-system
  • Built
  • ISO builds successfully

So then I pulled down vyatta-cfg-firewall and debuild it, make iso. ISO fails to build with this message:

The following packages have unmet dependencies:
 vyatta-cfg-system : Depends: ddclient (>= 3.8.2+vyos2+lithium6) but it is not going to be installed
                     Depends: vyatta-dhcp3-client (>= 4.1.8+vyos2+lithium3) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

If I delete all the stuff in packages/vyatta-cfg-firewall* (the deb file mainly, but leave the directory with the source intact), ISO builds successfully.

So it's some kind of weird interaction between those two modules I think.

Either that or someone is playing a trick with me and the upstream packages are changing between runs :)

So, I can reproduce the missing initrd issue now as well, but I have no idea why it happens. It doesn't happen in ci, so I assume some local pacakge or command is missing. I did chroot into the chroot before squashfs is being packed and did a live-update-initramfs, which worked with no issues. So a missing driver can be ruled out here.
but I get then an issued that the arch isn't supported :D.

W: Bootloader on your architecture not yet supported by live-build.
W: This will produce a most likely not bootable image (Continuing in 5 seconds).
xorriso 1.3.2 : RockRidge filesystem manipulator, libburnia project.

I have been using Debian 8.11 as my build machine...Could that be an issue?

@max1e6 I don't think so. I was building on a Jessie VM for a while as well as Docker, and both fail

@hagbard

So I've been digging into this more. The problem starts when you pull the submodule for vyatta-cfg-firewall. That module builds, but the ISO fails to build due to a problem with vyatta-util.

So I pull that submodule/build/make ISO. The problem moves to vyatta-cfg. That submodule fails to build.

The first error that pops up is:

root@6a3fb52c4967:/vyos/packages/vyatta-cfg# debuild -i -b -uc -us
 dpkg-buildpackage -rfakeroot -D -us -uc -i -b
dpkg-buildpackage: warning: using a gain-root-command while being root
dpkg-buildpackage: source package vyatta-cfg
dpkg-buildpackage: source version 0.102.0+vyos2+lithium18
dpkg-buildpackage: source distribution unstable
dpkg-buildpackage: source changed by Alex Harpin <[email protected]>
 dpkg-source -i --before-build vyatta-cfg
dpkg-buildpackage: host architecture amd64
dpkg-checkbuilddeps: Unmet build dependencies: libboost-filesystem1.42-dev
dpkg-buildpackage: warning: build dependencies/conflicts unsatisfied; aborting
dpkg-buildpackage: warning: (Use -d flag to override.)
debuild: fatal error at line 1376:
dpkg-buildpackage -rfakeroot -D -us -uc -i -b failed

At least in the Docker version that builds, the version of that is libboost-filesystem1.55-dev. Changing the debian/control file version to match that, results in this error:

/usr/include/glib-2.0/glib/gtypes.h:32:24: fatal error: glibconfig.h: No such file or directory
 #include <glibconfig.h>
                        ^

At this point I'm at a loss with that module. The file comes from libglib2.0-dev which is definitely installed.

And I think the issue I am encountering is different. I am trying to build without pulling any additional modules...it builds "fine" but fails to build the ISO. I have been researching the issue and found a couple of articles that indicate that the build of the img is "delayed"...not built which is why the copy fails.

@max1e6 Is your build directory on NFS? I had that problem when my build directory was being stored on NFS

Nope. Debian 8.11 virtual machine.

I just tested it on my 8.11 VM and it fails to build there as well for the reason you mentioned (the lack of initrd)

That feels more like a missing dependency on the host VM though. You can always build the docker version, which minus the problems with the firewall module I mentioned above, seems to be building fine.

git clone https://github.com/vyos/vyos-build.git
cd vyos-build
docker build -t vyos-builder .
docker run -it --privileged -v /HOST_PATH_OF_VYOS_BUILD_REPO:/vyos -w="/vyos" vyos-builder bash
./configure
make iso

@hagbard

Now a simple build is failing with:

dpkg: error processing archive /var/cache/apt/archives/vyos-1x_1.2.0-7_all.deb (--unpack):
 trying to overwrite '/opt/vyatta/etc/config-migrate/migrate/webproxy/0-to-1', which is also in package vyatta-config-migrate 0.13.65+vyos2+current1

According to CI service build works as expected. Can you please retry?

I did a build yesterday that went trough without issues..
I was using custom kernel, wireguard module and strongswan module. So from my point of view everything is fine now.

I was able to build yesterday using Docker, but not a traditional VM.

@runar

I was building yesterday fine except for the above-mentioned vyatta-cfg-firewall problem.

@c-po

Trying again. will report back.

@c-po

This seems to be working now. It's working both on my normal build tree and a brand new one, so it looks like I was just attempting when some cache somewhere hadn't updated

git clone https://github.com/vyos/vyos-build.git
docker run -it --privileged -v /root/test/vyos-build/:/vyos -w="/vyos" vyos-builder bash
./configure
make iso

This one is still failing per above

git clone https://github.com/vyos/vyos-build.git
git submodule update --init packages/vyatta-cfg-firewall
docker run -it --privileged -v /root/test/vyos-build2/:/vyos -w="/vyos" vyos-builder bash
cd packages/vyatta-cfg-firewall/
debuild -i -b -uc -us
cd ../../
./configure
make iso
dpkg: error processing archive /var/cache/apt/archives/vyatta-util_0.13+vyos2+current1_amd64.deb (--unpack):
 trying to overwrite '/opt/vyatta/sbin/ipset-check-member', which is also in package vyatta-cfg 0.102.0+vyos2+current4

In vyatta-cfg-firewall please do git checkout current prior to building it, as the submodule pointer is definately not up2date.

@c-po Thanks. Between the legit problem this task revealed early-on, some bad timing with the vyatta-config-migrate from earlier today, and a PEBKAC error, it looks like this might be resolved now.