Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Expand
titleBuild Mion for APS2556X-1T

Mion docs has an excellent getting started page. In this section we will emphasize how easy it is to build Mion. First, make sure you have a machine compliant to the "Build host" requirements. Install a pristine Debian 10 and you should be go to go ...

Code Block
languagebash
themeMidnight
titleInstall Yocto software requirement (5 minutes depending on your Internet connection)
sudo apt-get install gawk wget git-core diffstat unzip texinfo gcc-multilib \
     build-essential chrpath socat cpio python3 python3-pip python3-pexpect \
     xz-utils debianutils iputils-ping python3-git python3-jinja2 libegl1-mesa \
     libsdl1.2-dev pylint3 xterm


Code Block
languagebash
themeMidnight
titleGet Mion softwares (1 minute)
git clone --recursive git@github.com:NetworkGradeLinux/mion.git
cd mion
# To obtain related mion layers:
git clone git@github.com:NetworkGradeLinux/meta-mion.git
# Obtain the mion hardware layer
git clone git@github.com:NetworkGradeLinux/meta-mion-bsp.git


Warning
titleNote

The above steps require you have a GitHub account and uploaded public key to your account. You'll also have to activate ssh-agent as the build script will fetch software from Git using SSH transport.


Code Block
languagebash
themeMidnight
titleSource Yocto Build environment variables (5 seconds)
source openembedded-core/oe-init-build-env


Code Block
languagebash
themeMidnight
titleLaunch APS bf2556x-1t ONIE build (can be very long if you have a small build host ... It is time to do something else ...)
    time ../mc_build.sh -m stordis-bf2556x-1t -h host-onie:mion-onie-image-onlpv1 


Code Block
languagebash
themeMidnight
title[edit] (EDIT) Reward after a long build process ... (~151 minutes on a 4 vCPU VM)
Sstate summary: Wanted 1251 Found 0 Missed 1251 Current 0 (0% match, 0% complete)
NOTE: Executing Tasks
WARNING: mc:host-onie:expat-native-2.2.9-r0 do_fetch: Failed to fetch URL https://downloads.sourceforge.net/expat/expat-2.2.9.tar.bz2, attempting MIRRORS if available
NOTE: Tasks Summary: Attempted 3161 tasks of which 1 didn't need to be rerun and all succeeded.

Summary: There was 1 WARNING message shown.

real    150m43.758s
user    0m16.407s
sys     0m3.836s


Tip
titleTip

Even if the build process can be long depending on your build host, build duration can reach 30 minutes with a 32 cores machines. Subsequent builds will take significantly less time as a cache mechanism will avoid to to redo the whole build process.

Believe me, you are done !

Just wait the end of the build process and grab the freshly baked image.


Code Block
languagebash
themeMidnight
titleLet's relaunch the build again ... (~27 seconds on a 4 vCPU VM) Thanks sstate cache !
Sstate summary: Wanted 0 Found 0 Missed 0 Current 1251 (0% match, 100% complete)
NOTE: Executing Tasks
NOTE: Tasks Summary: Attempted 3161 tasks of which 3161 didn't need to be rerun and all succeeded.

real    0m27.430s
user    0m1.939s
sys     0m0.585s


...