Skip to content

Commit

Permalink
Added new barefoot based Netberg model Aurora 610
Browse files Browse the repository at this point in the history
Signed-off-by: adoyle <[email protected]>
  • Loading branch information
andrewsapronov authored and alexdoyle committed Feb 20, 2020
1 parent 2b4bf5d commit 66b6c93
Show file tree
Hide file tree
Showing 9 changed files with 2,320 additions and 0 deletions.
106 changes: 106 additions & 0 deletions machine/netberg/netberg_aurora_610/INSTALL
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
======================================
Installing ONIE on Netberg Aurora 610
======================================

Cross-Compiling ONIE
====================

Change directories to ``build-config`` to compile ONIE.

To compile ONIE first change directories to ``build-config`` and then
type ``"make MACHINEROOT=../machine/netberg MACHINE=netberg_aurora_610 all"``. For example::

$ cd build-config
$ make MACHINEROOT=../machine/netberg MACHINE=netberg_aurora_610 all

When complete, the ONIE binaries are located in
``build/images``::

-rw-rw-r-- 1 asapronov asapronov 9275148 jan 27 19:08 netberg_aurora_610-r0.initrd
-rw-rw-r-- 1 asapronov asapronov 3928144 jan 27 19:05 netberg_aurora_610-r0.vmlinuz
-rw-rw-r-- 1 asapronov asapronov 30146560 jan 27 19:09 onie-recovery-x86_64-netberg_aurora_610-r0.iso
-rw-rw-r-- 1 asapronov asapronov 13150071 jan 27 19:08 onie-updater-x86_64-netberg_aurora_610-r0


netberg_aurora_610-r0.vmlinuz -- This is the ONIE kernel image

netberg_aurora_610-r0.initrd -- This is the ONIE initramfs (filesystem)

onie-updater-x86_64-netberg_aurora_610-r0 -- This is the ONIE self-update
image. This image is a self-extracting archive used for installing
ONIE.

onie-recovery-x86_64-netberg_aurora_610-r0.iso -- This is a recovery ISO image
that can be install as a CDROM image.

Installing ONIE on a Blank Machine
==================================

To install ONIE on a new machine use one of the onie-recovery images.

Overview
--------

An "ONIE recovery image" is used for:

1. installing ONIE on a blank machine, i.e. what manufacturing would
use.

2. recovering a destroyed ONIE system.

The recovery image is:

. <machine>.iso -- a hybrid ISO image.

ISO Recovery Image
------------------

The .iso image is used to create the usb recovery disk.

You can use the .iso image to create a bootable USB memory stick.
Use ``dd`` to copy the .iso image to a USB stick and boot from that::

dd if=<machine>.iso of=/dev/sdX bs=10M

For can find the correct ``/dev/sdX`` by inspecing the ``dmesg``
output after inserting the USB stick into your work station.

To enable booting from USB in BIOS:

1. Insert the USB stick

2. Power on the Netberg Aurora 610 Switch

3. Press ECS to get into the BIOS and set USB as boot device

4. Wait for scanning USB disk grub.cfg

GNU GRUB version 2.02

+----------------------------------------------------------------------------+
|*ONIE: Rescue |
| ONIE: Embed ONIE |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
+----------------------------------------------------------------------------+

Use the ^ and v keys to select which entry is highlighted.
Press enter to boot the selected OS, `e' to edit the commands
before booting or `c' for a command-line.

5. Choose ``ONIE: Embed ONIE``, then ONIE will be ready after reboot.

6. ``ONIE: Rescue`` for ONIE rescue mode on USB disk shall also provide
an debugging environment.




Binary file not shown.
Empty file.
73 changes: 73 additions & 0 deletions machine/netberg/netberg_aurora_610/installer.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
# Netberg Aurora 610
# CPU Module: Intel Broadwell-DE

description="Netberg Aurora 610"

# Default ONIE block device
install_device_platform()
{
# find ata device on the systme, return the 1st one.

##
# find the usb dom first
##
for _device in /sys/block/*/device; do
_device=$(echo $_device | sed -e 's/\/device//')

# work for kernel 3.2.35 (usb dom, which is connected to usb port 0, i.e, 1-1.1)
if echo $(readlink -f $_device)|egrep -q "pci0000:00\/0000:00:16.0\/usb1\/1-1\/1-1.1\/"; then
_disk=`echo $_device | cut -f4 -d/`
echo /dev/$_disk
return 0
fi
done

##
# no usb dom found, try to find sata dom
##
for _device in /sys/block/*/device; do
_device=$(echo $_device | sed -e 's/\/device//')

# work for kernel 3.2.35
if echo $(readlink -f $_device)|egrep -q "pci0000:00\/0000:00:18.0"; then
_disk=`echo $_device | cut -f4 -d/`
echo /dev/$_disk
return 0
fi
# work for kernel 3.14.16
if echo $(readlink -f $_device)|egrep -q "ata"; then
_disk=`echo $_device | cut -f4 -d/`
echo /dev/$_disk
return 0
fi
done

# nothing found, just return /dev/sda
echo /dev/sda
return 1
}

post_install()
{
echo "Post installation hook"

#
# Add platform specific hooks here.
#
# For example, set BIOS to directly
# boot from hard drive as onie is
# already installed.
#

$onie_root_dir/tools/bin/onie-boot-mode -q -o rescue

return 0
}

# Set install callback hooks
post_install_hook=post_install

# Local Variables:
# mode: shell-script
# eval: (sh-set-shell "/bin/sh" t nil)
# End:
Loading

0 comments on commit 66b6c93

Please sign in to comment.