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

sonic image compile error happend at "make all" stage. Need help, thanks. #3673

Closed
adamx-xk opened this issue Oct 26, 2019 · 7 comments
Closed

Comments

@adamx-xk
Copy link

...
Step 6/36 : RUN apt-get update && apt-get install -y apt-utils default-jre-headless openssh-server curl wget unzip git build-essential libtool lintian sudo dh-make dh-exec kmod libtinyxml2-2 libboost-program-options1.55-dev libtinyxml2-dev python python-pip libncurses5-dev texinfo dh-autoreconf python3-pip doxygen devscripts git-buildpackage perl-modules libswitch-perl dh-systemd libreadline-dev texlive-latex-base texlive-generic-recommended texlive-fonts-recommended libpam0g-dev libpam-dev libcap-dev imagemagick ghostscript groff libpcre3-dev gawk chrpath libc-ares-dev hardening-wrapper libsnmp-dev libjson0 libjson0-dev libsystemd-dev python-ipaddr install-info cdbs libxml-simple-perl graphviz aspell bc fakeroot build-essential devscripts quilt stgit module-assistant gem2deb libboost-all-dev libevent-dev libglib2.0-dev libqt4-dev python-all-dev python-twisted php5-dev phpunit libbit-vector-perl openjdk-7-jdk javahelper maven-debian-helper ant libmaven-ant-tasks-java libhttpclient-java libslf4j-java libservlet3.1-java qt5-default pkg-php-tools libpcre3 libpcre3-dev byacc flex libglib2.0-dev bison expat libexpat1-dev dpatch libdb-dev iptables-dev swig ctags libtool-bin libxml2-dev libusb-1.0-0-dev libcurl3-nss-dev libunwind8-dev telnet libc-ares2 libgoogle-perftools4 cpio squashfs-tools zip linux-compiler-gcc-4.8-x86 linux-kbuild-3.16 libdaemon-dev libdbus-1-dev libjansson-dev libpcap-dev dnsutils libusb-dev augeas-tools libyaml-dev libevent-dev libjudy-dev libedit-dev libnanomsg-dev python-stdeb libjemalloc-dev dkms sharutils libncursesw5-dev libbz2-dev liblzma-dev libgdbm-dev tk-dev blt-dev libmpdec-dev libbluetooth-dev locales libsqlite3-dev libgpm2 time net-tools xvfb python-sphinx python3-sphinx cppcheck clang pylint gcovr python-pytest=2.6.3* python3-pytest=2.6.3* python-pytest-cov python3-pytest-cov python-parse libmysqlclient-dev libmysqld-dev libperl-dev libpci-dev libpci3 libsensors4 libsensors4-dev libwrap0-dev docutils-common libjs-sphinxdoc libjs-underscore python-docutils python-markupsafe python-pygments python-roman sphinx-common python-lxml python-netaddr python-ipaddr python-yaml procmail libgtest-dev cmake autoconf-archive swig3.0 cm-super-minimal libatm1-dev libelf-dev libmnl-dev libselinux1-dev linuxdoc-tools lynx texlive-latex-extra texlive-latex-recommended python-sphinx python-docutils python3-all python3-setuptools python3-sphinx python3-docutils python3-requests python3-pytest python3-colorama texi2html bash-completion dosfstools qemu-kvm libvirt-bin
---> Running in 66cc51adff4c
Ign http://debian-archive.trafficmanager.net jessie InRelease
Get:1 http://debian-archive.trafficmanager.net jessie/updates InRelease [44.9 kB]
Get:2 http://security.debian.org jessie/updates InRelease [44.9 kB]
Get:3 http://debian-archive.trafficmanager.net jessie Release.gpg [1652 B]
Get:4 http://debian-archive.trafficmanager.net jessie Release [77.3 kB]
Ign http://deb.debian.org jessie InRelease
Get:5 http://deb.debian.org jessie Release.gpg [1652 B]
Get:6 http://deb.debian.org jessie Release [77.3 kB]
Get:7 http://debian-archive.trafficmanager.net jessie/updates/main Sources [387 kB]
Get:8 http://debian-archive.trafficmanager.net jessie/updates/contrib Sources [1298 B]
Get:9 http://debian-archive.trafficmanager.net jessie/updates/non-free Sources [1487 B]
Get:10 http://debian-archive.trafficmanager.net jessie/updates/main amd64 Packages [893 kB]
Get:11 http://debian-archive.trafficmanager.net jessie/updates/contrib amd64 Packages [2366 B]
Get:12 http://debian-archive.trafficmanager.net jessie/updates/non-free amd64 Packages [4725 B]
Get:13 http://debian-archive.trafficmanager.net jessie/main Sources [9169 kB]
Get:14 http://deb.debian.org jessie/main amd64 Packages [9098 kB]
Get:15 http://security.debian.org jessie/updates/main amd64 Packages [893 kB]
Get:16 http://debian-archive.trafficmanager.net jessie/contrib Sources [58.9 kB]
Get:17 http://debian-archive.trafficmanager.net jessie/non-free Sources [119 kB]
Get:18 http://debian-archive.trafficmanager.net jessie/main amd64 Packages [9098 kB]
Get:19 http://debian-archive.trafficmanager.net jessie/contrib amd64 Packages [59.2 kB]
Get:20 http://debian-archive.trafficmanager.net jessie/non-free amd64 Packages [101 kB]
Fetched 30.1 MB in 24s (1249 kB/s)
Reading package lists...
Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package linux-compiler-gcc-4.8-x86
E: Couldn't find any package by regex 'linux-compiler-gcc-4.8-x86'
The command '/bin/sh -c apt-get update && apt-get install -y apt-utils default-jre-headless openssh-server curl wget unzip git build-essential libtool lintian sudo dh-make dh-exec kmod libtinyxml2-2 libboost-program-options1.55-dev libtinyxml2-dev python python-pip libncurses5-dev texinfo dh-autoreconf python3-pip doxygen devscripts git-buildpackage perl-modules libswitch-perl dh-systemd libreadline-dev texlive-latex-base texlive-generic-recommended texlive-fonts-recommended libpam0g-dev libpam-dev libcap-dev imagemagick ghostscript groff libpcre3-dev gawk chrpath libc-ares-dev hardening-wrapper libsnmp-dev libjson0 libjson0-dev libsystemd-dev python-ipaddr install-info cdbs libxml-simple-perl graphviz aspell bc fakeroot build-essential devscripts quilt stgit module-assistant gem2deb libboost-all-dev libevent-dev libglib2.0-dev libqt4-dev python-all-dev python-twisted php5-dev phpunit libbit-vector-perl openjdk-7-jdk javahelper maven-debian-helper ant libmaven-ant-tasks-java libhttpclient-java libslf4j-java libservlet3.1-java qt5-default pkg-php-tools libpcre3 libpcre3-dev byacc flex libglib2.0-dev bison expat libexpat1-dev dpatch libdb-dev iptables-dev swig ctags libtool-bin libxml2-dev libusb-1.0-0-dev libcurl3-nss-dev libunwind8-dev telnet libc-ares2 libgoogle-perftools4 cpio squashfs-tools zip linux-compiler-gcc-4.8-x86 linux-kbuild-3.16 libdaemon-dev libdbus-1-dev libjansson-dev libpcap-dev dnsutils libusb-dev augeas-tools libyaml-dev libevent-dev libjudy-dev libedit-dev libnanomsg-dev python-stdeb libjemalloc-dev dkms sharutils libncursesw5-dev libbz2-dev liblzma-dev libgdbm-dev tk-dev blt-dev libmpdec-dev libbluetooth-dev locales libsqlite3-dev libgpm2 time net-tools xvfb python-sphinx python3-sphinx cppcheck clang pylint gcovr python-pytest=2.6.3* python3-pytest=2.6.3* python-pytest-cov python3-pytest-cov python-parse libmysqlclient-dev libmysqld-dev libperl-dev libpci-dev libpci3 libsensors4 libsensors4-dev libwrap0-dev docutils-common libjs-sphinxdoc libjs-underscore python-docutils python-markupsafe python-pygments python-roman sphinx-common python-lxml python-netaddr python-ipaddr python-yaml procmail libgtest-dev cmake autoconf-archive swig3.0 cm-super-minimal libatm1-dev libelf-dev libmnl-dev libselinux1-dev linuxdoc-tools lynx texlive-latex-extra texlive-latex-recommended python-sphinx python-docutils python3-all python3-setuptools python3-sphinx python3-docutils python3-requests python3-pytest python3-colorama texi2html bash-completion dosfstools qemu-kvm libvirt-bin' returned a non-zero code: 100
Image sonic-slave-base-xk:8b0c3984348 not found. Building...
Sending build context to Docker daemon 24.58kB
Step 1/18 : ARG slave_base_tag_ref=latest
Step 2/18 : FROM sonic-slave-base:${slave_base_tag_ref}
pull access denied for sonic-slave-base, repository does not exist or may require 'docker login': denied: requested access to the resource is denied
Unable to find image 'sonic-slave-base-xk:8b0c3984348' locally
docker: Error response from daemon: pull access denied for sonic-slave-base-xk, repository does not exist or may require 'docker login': denied: requested access to the resource is denied.
See 'docker run --help'.
Makefile.work:190: recipe for target 'jessie' failed
make[1]: *** [jessie] Error 125
make[1]: Leaving directory '/home/xk/sonic/sonic_src/sonic-buildimage'
Makefile:6: recipe for target 'all' failed
make: *** [all] Error 2

Description

Steps to reproduce the issue:
1.
2.
3.

Describe the results you received:

Describe the results you expected:

Additional information you deem important (e.g. issue happens only occasionally):

**Output of `show version`:**

```
(paste your output here)
```

**Attach debug file `sudo generate_dump`:**

```
(paste your output here)
```
@dflynn2019
Copy link

dflynn2019 commented Oct 29, 2019 via email

@adamx-xk
Copy link
Author

pls replace 'linux-compiler-gcc-4.8-x86' with 'linux-compiler-gcc-4.9-x86' in file sonic-slave/Dockerfile.j2.

@jleveque
Copy link
Contributor

jleveque commented Oct 30, 2019

@dflynn2019: I acutally made this change on Sep. 26 in both the master branch as well as the 201811 branch. You should no longer see any issues on these branches.

@dflynn2019
Copy link

dflynn2019 commented Jan 2, 2020 via email

@jleveque
Copy link
Contributor

jleveque commented Jan 2, 2020

@dflynn2019: Hi Dennis. I believe the logic you're looking for resides in /etc/rc.local. For example, the following line will install all .deb packages under the directory with the ONIE platform string: https://github.com/Azure/sonic-buildimage/blob/master/files/image_config/platform/rc.local#L244

@dflynn2019
Copy link

dflynn2019 commented Jan 3, 2020 via email

@abhiranjeet
Copy link

pls replace 'linux-compiler-gcc-4.8-x86' with 'linux-compiler-gcc-4.9-x86' in file sonic-slave/Dockerfile.j2.

Hi @adamx-xk
I replaced 4.8 with 4.9 in the dockerfile. But later on, it shows me this error :
/usr/bin/gcc-4.8: not found (maybe gcc-4.8 is not installed?)

I even went to 201811 branch (which does not have this problem). But while running make target/sonic-broadcom.bin it builds a sonic Debian 9 image. I even tried to run it as BLDENV=jessie make target/sonic-broadcom.bin but it does not build for it.

Is there a way to build a SONiC image where base OS can be selected, whether its D8, 9, 10 or 11 ?

It seems that despite passing BLDENV of choice, it still takes 10/11 in latest or sometimes 9 if i checkout an older branch.

Thanks in advance !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants