Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build failed on ubuntu 18.04 #348

Open
howardqiao opened this issue Aug 18, 2018 · 13 comments

Comments

@howardqiao
Copy link

commented Aug 18, 2018

Get:1 http://archive.volumio.org/raspbian jessie InRelease [14.9 kB]
Err:1 http://archive.volumio.org/raspbian jessie InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 9165938D90FDDD2E
Reading package lists... Done
W: GPG error: http://archive.volumio.org/raspbian jessie InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 9165938D90FDDD2E
E: The repository 'http://archive.volumio.org/raspbian jessie InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
......
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/q/aoide-dac-drivers/build/build/arm/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/q/aoide-dac-drivers/build/build/arm/root/etc/apt/sources.list.d/multistrap-utils.list:1
apt update failed. Exit value: 100

@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented Aug 18, 2018

try removing “build/arm/root/etc/initramfs/hooks” and rebuild the image with - d and -v only.
No need for the -b parameter, otherwise it rebuilds the rootfs too and you’re back at the beginning.

@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented Aug 18, 2018

Sorry, first read the README.md, you might have to edit the multistrap script, instructions are there.
Then start from the beginning and when you get an error while building the image, do the above.

@howardqiao

This comment has been minimized.

Copy link
Author

commented Aug 20, 2018

Sorry,but there's no "$forceyes" in /usr/sbin/multistrap
But i can build the image on ubuntu 16.04 with below parameters.
sudo ./build.sh -b arm -d pi -v 2.344

@sstark

This comment has been minimized.

Copy link

commented Sep 10, 2018

same issue here on 18.04

@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented Sep 11, 2018

Then please guys, post a complete log so I can help and do ‘t have to guess. A partial log is, well, dangerous as you might have missed something you thought was unimportant. And “Same here” does not help at all, sorry.
I have a Ubuntu Bionic (18.04?) basic server and seem to have a working setup...

@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented Sep 11, 2018

OK, I have been able to reproduce this on a fresh Ubuntu install.
No idea what is causing this.
I did noticed the version on Ubuntu uses a Parameter APT_CONFIG not seen on Debian jessie, but I'm not sure if there is a relation. Unfortunately I have practically no time to follow it up at the moment.
Guaranteed workaround: using a Debain jessie install, all devs currently use it.

@sstark

This comment has been minimized.

Copy link

commented Sep 12, 2018

The problem seems to be just with multistrap. If I simply call "multistrap -a i386 -f recipes/x86.conf" it failes. Unfortunately build.sh does not check return values, so it will continue going and hiding the original error. This is the output of multistrap for me:

> sudo multistrap -a i386 -f recipes/x86.conf            
multistrap 2.2.9 using recipes/x86.conf
multistrap 2.2.9 using recipes/x86.conf
Using foreign architecture: i386
multistrap building i386 multistrap on 'amd64'
Getting package lists: APT_CONFIG=/tmp/multistrap.E4ciQp apt-get  -o Apt::Architecture=i386 -o Dir::Etc::TrustedParts=/home/seb/work-git/volumio/build/build/x86/root/etc/apt/trusted.gpg.d -o Dir::Etc::Trusted=/home/seb/work-git/volumio/build/build/x86/root/etc/apt/trusted.gpg -o Apt::Get::AllowUnauthenticated=true -o Apt::Get::Download-Only=true -o Apt::Install-Recommends=false -o Dir=/home/seb/work-git/volumio/build/build/x86/root/ -o Dir::Etc=/home/seb/work-git/volumio/build/build/x86/root/etc/apt/ -o Dir::Etc::Parts=/home/seb/work-git/volumio/build/build/x86/root/etc/apt/apt.conf.d/ -o Dir::Etc::PreferencesParts=/home/seb/work-git/volumio/build/build/x86/root/etc/apt/preferences.d/ -o APT::Default-Release='*' -o Dir::State=/home/seb/work-git/volumio/build/build/x86/root/var/lib/apt/ -o Dir::State::Status=/home/seb/work-git/volumio/build/build/x86/root/var/lib/dpkg/status -o Dir::Cache=/home/seb/work-git/volumio/build/build/x86/root/var/cache/apt/ update
Ign:1 http://cdn-fastly.deb.debian.org/debian jessie InRelease
Get:2 http://cdn-fastly.deb.debian.org/debian jessie Release [148 kB]
Get:3 http://cdn-fastly.deb.debian.org/debian jessie Release.gpg [2.420 B]
Ign:3 http://cdn-fastly.deb.debian.org/debian jessie Release.gpg
Reading package lists... Done 
W: Download is performed unsandboxed as root as file '/home/seb/work-git/volumio/build/build/x86/root/var/lib/apt/lists/partial/httpredir.debian.org_debian_dists_jessie_InRelease' couldn't be accessed by user '_apt'. - pkgAcquire::Run (13: Permission denied)
W: GPG error: http://cdn-fastly.deb.debian.org/debian jessie Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 8B48AD6246925553 NO_PUBKEY 7638D0442B90D010 NO_PUBKEY CBF8D6FD518E17E1
E: The repository 'http://httpredir.debian.org/debian jessie Release' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-base.list:2
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-firmware.list:2
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-fs.list:2
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-net.list:2
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-tools.list:2
W: Target Sources (main/source/Sources) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:2 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-utils.list:2
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-base.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-base.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-base.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-base.list:1
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-firmware.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-firmware.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-firmware.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-firmware.list:1
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-fs.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-fs.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-fs.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-fs.list:1
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-net.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-net.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-net.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-net.list:1
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-tools.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-tools.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-tools.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-tools.list:1
W: Target Packages (main/binary-i386/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-utils.list:1
W: Target Packages (main/binary-all/Packages) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-utils.list:1
W: Target Translations (main/i18n/Translation-en_US) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-utils.list:1
W: Target Translations (main/i18n/Translation-en) is configured multiple times in /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-assets.list:1 and /home/seb/work-git/volumio/build/build/x86/root/etc/apt/sources.list.d/multistrap-utils.list:1
apt update failed. Exit value: 100

And this the output with --simulate:

> sudo multistrap -a i386 -f recipes/x86.conf --simulate
multistrap 2.2.9 using recipes/x86.conf
include:		No included configuration files.

Section name:	assets
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	alsa-base alsa-utils exiftool libasound2 libboost-program-options1.55.0 libboost-system1.55.0 libconfig-dev libcurl3 libexpat1 libjsoncpp0 libmicrohttpd10 libmpdclient2 libupnp6 mpc mpd python-requests rlwrap sox sqlite3

Section name:	base
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	acl adduser apt apt-transport-https base-files base-passwd bash bsdutils chromium coreutils dbus debconf debconf-i18n debian-archive-keyring debianutils diffutils dmsetup dpkg e2fslibs e2fsprogs findutils gnupg gpgv grep grub-common gzip hostname init initscripts insserv libacl1 libapt-pkg4.12 libattr1 libaudit-common libaudit1 libblkid1 libbz2-1.0 libc-bin libc6 libcap2 libcap2-bin libcomerr2 libcryptsetup4 libdb5.3 libdebconfclient0 libdevmapper1.02.1 libgcc1 libgcrypt20 libgpg-error0 libkmod2 liblocale-gettext-perl liblzma5 libmount1 libncurses5 libncursesw5 libpam-modules libpam-modules-bin libpam-runtime libpam0g libpcre3 libprocps3 libreadline6 libselinux1 libsemanage-common libsemanage1 libsepol1 libslang2 libsmartcols1 libss2 libstdc++6 libsystemd0 libtext-charwidth-perl libtext-iconv-perl libtext-wrapi18n-perl libtinfo5 libudev1 libusb-0.1-4 libustr-1.0-1 libuuid1 login lsb-base mawk mount multiarch-support ncurses-base ncurses-bin openbox os-prober passwd perl-base procps readline-common sed startpar sudo syslinux syslinux-common systemd tar tzdata udev unclutter util-linux xorg zlib1g

Section name:	firmware
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main non-free
	packages:	firmware-atheros firmware-brcm80211 firmware-iwlwifi firmware-linux firmware-ralink firmware-realtek

Section name:	fs
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	cifs-utils dcfldd dosfstools exfat-fuse exfat-utils libnss-winbind nfs-common ntfs-3g samba smbclient winbind

Section name:	net
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	crda dhcpcd5 dnsmasq ethtool hostapd ifplugd ifupdown iproute iptables iputils-ping isc-dhcp-server iw libavahi-compat-libdnssd-dev libgnutls-openssl27 libnl-3-200 libnl-genl-3-200 libpcsclite1 net-tools netbase openssh-server rfkill telnet wireless-regdb wireless-tools wpasupplicant

Section name:	tools
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	initramfs-tools subversion xz-utils

Section name:	utils
	source:		http://httpredir.debian.org/debian
	suite:		jessie
	components:	main
	packages:	avahi-daemon avahi-discover bc binutils busybox ca-certificates cpufrequtils curl ethtool gdisk git git-core jq less libnss-mdns localepurge locales md5deep minizip nano ntp parted policykit-1 psmisc rpl rsync udisks udisks-glue usbutils wget zsync

Sections to install:	assets base firmware fs net tools utils
Section for updates:	debian
omitdebsrc		Omit deb-src from sources.list for sections: None.
explicitsuite:		Explicit suite selection: No - let apt use latest.
allowrecommends:	Recommended packages are ignored.
Architecture:		Architecture to download: i386
dir:			Output directory: 'build/x86/root'
unpack:			extract all downloaded archives: true
omitrequired:		'Priority: required' packages are included.
addimportant:		'Priority: important' packages are ignored.
cleanup:		remove apt cache data: true
noauth:			allow the use of unauthenticated repositories: true
omitpreinst:		Preinst scripts are executed with the install argument.
ignorenativearch:	Packages will be configured.
aptpreferences:		No apt preferences file. Default release: *


ERR: The 'debian' section is not defined.

I don't know what is the expected output, so I will install a jessie vm and try there. Would a check and warning to the user in build.sh ("you have to use Debian jessie to run this") be an acceptable patch?

@hudecof

This comment has been minimized.

Copy link

commented Jan 31, 2019

@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented Feb 11, 2019

This issue has now been resolved.
You need to patch /usr/sbin/multistrap.
Look for the line
$config_str .= " -o Apt::Get::AllowUnauthenticated=true"
Just above it, add
$config_str .= " -o Acquire::AllowInsecureRepositories=true";

This will allow the use of unsigned repositories. This has been tested on Debian Buster and Ubuntu 18.04, I'm sure it will work the same way on a Debian Stretch install as well.

I will update the README.md to document this.

Note: this does not solve the issue with mkinitramfs on a Ubuntu install, this is still under investigation!!

@hudecof

This comment has been minimized.

Copy link

commented Feb 13, 2019

@gkkpch should not be this issue reported to the multistrap, just to add option form Insecure repositories ?

What's the different between Ubuntu and Debian ?

@jekhor

This comment has been minimized.

Copy link

commented May 1, 2019

Instead of mutistrap patching, you need to import the raspbian key into apt keyring inside of the build directory, add this to the build.sh before mutistrap call:

mkdir -p "build/$BUILD/root/etc/apt/trusted.gpg.d"
apt-key --keyring "build/$BUILD/root/etc/apt/trusted.gpg.d/raspbian.gpg"  adv --batch --keyserver ha.pool.sks-keyservers.net --recv-key   0x9165938D90FDDD2E
@gkkpch

This comment has been minimized.

Copy link
Collaborator

commented May 2, 2019

I disagree, that does not help us with X86 and any of the armv7 platforms.
Patch multistrap and it works for all.

@kdubious

This comment has been minimized.

Copy link

commented Aug 8, 2019

This worked for me:

mkdir -p "build/$BUILD/root/etc/apt/trusted.gpg.d"
apt-key --keyring "build/$BUILD/root/etc/apt/trusted.gpg.d/debian.gpg"  adv --batch --keyserver hkp://keyserver.ubuntu.com:80 --recv-key 7638D0442B90D010
apt-key --keyring "build/$BUILD/root/etc/apt/trusted.gpg.d/debian.gpg"  adv --batch --keyserver hkp://keyserver.ubuntu.com:80 --recv-key CBF8D6FD518E17E1

above the call to : multistrap -a "$ARCH" -f "$CONF"

I think it's safer to edit the build.sh file than the code for multistrap.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.