Custom Beaglebone Black Image

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

Home Translators Contribute to Kali Kali Forums F.A.

Have a question? Ask or enter a search term. SEARCH

English Custom Beaglebone Black Image


简体中文 Home / 07. Kali Linux Development
Français
Deutsch
‫اﻟﻌﺮﺑﻴﺔ‬ The following document describes our own method of creating a custom Kali Linux
Português
Beaglebone Black ARM image and is targeted at developers. If you would like to install a pre-
Nederlands
made Kali image, check out our Install Kali on Beaglebone Black article.
Italiano
Русский
Español
01. Create a Kali rootfs
Categories
Build a Kali rootfs as described in our Kali documentation, using an armhf architecture. By the
00. Introduction to Kali Linux end of this process, you should have a populated rootfs directory in ~/arm-stuff/rootfs/kali-
armhf.
01. Downloading Kali Linux

02. Building Custom Kali Images

03. Installing Kali Linux 02. Create the Image File


04. Kali Linux Network Installs
Next, we create the physical image file, which will hold our Beaglebone Black rootfs and boot
05. Kali Linux General Use images.

06. Kali Linux ARM Architecture


06. Kali Linux ARM Architecture
apt-get install kpartx xz-utils sharutils
07. Kali Linux Development cd ~
mkdir -p arm-stuff
08. Troubleshooting Kali Linux
cd arm-stuff/
09. Kali Community Support mkdir -p images
cd images
10. Kali Linux Policies dd if=/dev/zero of=kali-custom-bbb.img bs=1MB count=7000

Latest Articles
03. Partition and Mount the Image File
Custom EfikaMX Image

parted --script kali-custom-bbb.img mklabel msdos


Install Kali ARM on an EfikaMX
fdisk kali-custom-bbb.img << __EOF__
n
Custom Beaglebone Black Image
p
1
Install Kali ARM on a Beaglebone
Black
+64M
Custom CuBox Image t
e
Install Kali ARM on a CuBox p
w
Kali Linux sources.list repositories __EOF__
parted --script kali-custom-bbb.img set 1 boot on
Install NVIDIA Drivers on Kali Linux fdisk kali-custom-bbb.img << __EOF__
n
Kali Linux on Galaxy Note 10.1 p
2
Submitting Bugs for Kali Linux loopdevice=`losetup -f --show kali-custom-bbb.img`
device=`kpartx -va $loopdevice| sed -E 's/.*(loop[0-9])p.*/\1/g' | head -1`
w
device="/dev/mapper/${device}"
__EOF__
bootp=${device}p1
Twitter Stream
rootp=${device}p2

mkfs.vfat -F 16 $bootp -n boot


Follow Us! mkfs.ext4 $rootp -L kaliroot
mkdir -p boot
mkdir -p root
mount $bootp boot
mount $rootp root

04. Copy and Modify the Kali rootfs


rsync -HPavz /root/arm-stuff/rootfs/kali-armhf/ root
echo nameserver 8.8.8.8 > root/etc/resolv.conf

05. Compile the Beaglebone Black Kernel and Modules


If you’re not using ARM hardware as the development environment, you will need to set up an
ARM cross-compilation environment to build an ARM kernel and modules. Once that’s done,
proceed with the following instructions.

cd ~/arm-stuff
wget https://launchpad.net/linaro-toolchain-binaries/trunk/2013.03/+download/gcc-linaro-arm-linux-gnueabihf-4.7
tar xjf gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux.tar.bz2
export CC=`pwd`/gcc-linaro-arm-linux-gnueabihf-4.7-2013.03-20130313_linux/bin/arm-linux-gnueabihf-

git clone git://git.denx.de/u-boot.git


cd u-boot/
git checkout v2013.04 -b beaglebone-black
wget https://raw.github.com/eewiki/u-boot-patches/master/v2013.04/0001-am335x_evm-uEnv.txt-bootz-n-fixes.pa
patch -p1 < 0001-am335x_evm-uEnv.txt-bootz-n-fixes.patch
make ARCH=arm CROSS_COMPILE=${CC} distclean
make ARCH=arm CROSS_COMPILE=${CC} am335x_evm_config
make ARCH=arm CROSS_COMPILE=${CC}
cd ..

mkdir -p kernel
cd kernel
git clone$rootp
umount git://github.com/RobertCNelson/linux-dev.git
cd linux-dev/
kpartx -dv $loopdevice
git checkout
losetup origin/am33x-v3.8 -b tmp
-d $loopdevice
./build_kernel.sh
mkdir
Use the-pdd
../patches
utility to image this file to your SD card. In our example, we assume the storage device
Use the dd utility to image this file to your SD card. In our example, we assume the storage device
is located at /dev/sdb. Change this as needed.

dd if=kali-custom-bbb.img of=/dev/sdb bs=1M

Once the dd operation is complete, unmount and eject the SD card and boot your Beaglebone
Black into Kali Linux. When booting you will need to press and hold the “BOOT” button, it’s the one
closest to the microSD card.

Related Articles

Custom EfikaMX Image

Custom CuBox Image

Custom Raspberry Pi Image

Custom Chromebook Image

© Copyright 2013, Offensive Security

English 简体中文 Français Deutsch ‫اﻟﻌﺮﺑﻴﺔ‬ Português Nederlands Italiano Русский Español

You might also like