I used flex-builder to build lsdk2004_ubuntu_main_LS_arm64.itb
I am able to tftp the file in uboot but I an error when the kernel boots.
This is how I am attempting to boot:
setenv bootargs 'console=ttyS0,115200 root=/dev/ram0 earlycon=uart8250,mmio,0x21c0500 earlyprintk'
bootp 0xA0000000 169.254.0.100:lsdk2004_ubuntu_main_LS_arm64.itb
bootm 0xA0000000#ls1046afrwy
This the output
## Loading kernel from FIT Image at a0000000 ...
Using 'ls1046afrwy' configuration
Trying 'kernel' kernel subimage
Description: ARM64 Kernel
Created: 2021-03-23 22:10:05 UTC
Type: Kernel Image
Compression: gzip compressed
Data Start: 0xa00000d0
Data Size: 14083450 Bytes = 13.4 MiB
Architecture: AArch64
OS: Linux
Load Address: 0x84080000
Entry Point: 0x84080000
Hash algo: crc32
Hash value: 5531a6c9
Verifying Hash Integrity ... crc32+ OK
## Loading ramdisk from FIT Image at a0000000 ...
Using 'ls1046afrwy' configuration
Trying 'initrd' ramdisk subimage
Description: initrd for arm64
Created: 2021-03-23 22:10:05 UTC
Type: RAMDisk Image
Compression: uncompressed
Data Start: 0xa0d6e72c
Data Size: 138956800 Bytes = 132.5 MiB
Architecture: AArch64
OS: Linux
Load Address: 0x00000000
Entry Point: 0x00000000
Hash algo: crc32
Hash value: b76ff40c
Verifying Hash Integrity ... crc32+ OK
## Loading fdt from FIT Image at a0000000 ...
Using 'ls1046afrwy' configuration
Trying 'ls1046afrwy-dtb' fdt subimage
Description: ls1046afrwy-dtb
Created: 2021-03-23 22:10:05 UTC
Type: Flat Device Tree
Compression: uncompressed
Data Start: 0xa922ea64
Data Size: 31528 Bytes = 30.8 KiB
Architecture: AArch64
Load Address: 0x90000000
Hash algo: crc32
Hash value: d872df6c
Verifying Hash Integrity ... crc32+ OK
Loading fdt from 0xa922ea64 to 0x90000000
Booting using the fdt blob at 0x90000000
Uncompressing Kernel Image ... OK
Using Device Tree in place at 0000000090000000, end 000000009001ab27
WARNING failed to get smmu node: FDT_ERR_NOTFOUND
WARNING failed to get smmu node: FDT_ERR_NOTFOUND
...
[ 2.084255] Trying to unpack rootfs image as initramfs...
[ 5.647102] rootfs image is not initramfs (read error); looks like an initrd
[ 5.792695] Freeing initrd memory: 135696K
...
[ 7.531828] RAMDISK: gzip image found at block 0
[ 7.579631] RAMDISK: incomplete write (9263 != 9306)
[ 7.584612] write error
[ 7.598930] List of all partitions:
[ 7.602432] 0100 4096 ram0
[ 7.602433] (driver?)
[ 7.608535] 0101 4096 ram1
[ 7.608535] (driver?)
[ 7.614634] 0102 4096 ram2
[ 7.614635] (driver?)
[ 7.620738] 0103 4096 ram3
[ 7.620738] (driver?)
[ 7.626836] 0104 4096 ram4
[ 7.626837] (driver?)
[ 7.632953] 0105 4096 ram5
[ 7.632954] (driver?)
[ 7.639058] 0106 4096 ram6
[ 7.639059] (driver?)
[ 7.645170] 0107 4096 ram7
[ 7.645171] (driver?)
[ 7.651273] 0108 4096 ram8
[ 7.651273] (driver?)
[ 7.657412] 0109 4096 ram9
[ 7.657413] (driver?)
[ 7.663518] 010a 4096 ram10
[ 7.663519] (driver?)
[ 7.669719] 010b 4096 ram11
[ 7.669720] (driver?)
[ 7.675915] 010c 4096 ram12
[ 7.675916] (driver?)
[ 7.682101] 010d 4096 ram13
[ 7.682102] (driver?)
[ 7.688300] 010e 4096 ram14
[ 7.688301] (driver?)
[ 7.694486] 010f 4096 ram15
[ 7.694487] (driver?)
[ 7.700689] 1f00 524288 mtdblock0
[ 7.700690] (driver?)
[ 7.707223] 1f01 65536 mtdblock1
[ 7.707224] (driver?)
[ 7.713769] b300 30326784 mmcblk0
[ 7.713771] driver: mmcblk
[ 7.720576] b301 23706 mmcblk0p1 661e76c1-01
[ 7.720577]
[ 7.727371] b302 1048576 mmcblk0p2 661e76c1-02
[ 7.727372]
[ 7.734172] b303 29188096 mmcblk0p3 661e76c1-03
[ 7.734173]
[ 7.740977] No filesystem could mount root, tried:
[ 7.740978] ext3
[ 7.745854] ext4
[ 7.747776] ext2
[ 7.749692] squashfs
[ 7.751609] vfat
[ 7.753884] fuseblk
[ 7.755805] btrfs
[ 7.757982]
[ 7.761473] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(1,0)
Is there an issue with my bootarg? Why is this error happening.
Thanks I have managed to build and boot ubuntu:lite and yocto:tiny.
I have tried adding additional packages to the file system of both images with no luck.
I need to add the nfs helper files. I tried to add nft-utils as an additon package. I don't see any change to the filesystem
In the end I also need to add Python3 as well.
I added the packages to additional_lite_packages_list
and the local_arm64_tiny.conf but don't see a change. What do I need to rebuild.
Please add "nfs-common" to "additional_lite_packages_list" in configs/ubuntu/additional_packages_list
Then execute the following command.
$ flex-builder -i clean-rfs -r ubuntu:lite
$ flex-builder -i mkrfs -r ubuntu:lite
$ flex-builder -i packrfs -r ubuntu:lite
So I am able to build and boot using buildroot:tiny.
How do I add packages to a buildroot filesystem?
When the build root image boots it does not bring up the network interface via dhcp. What do I need to change to get that to work on boot.
1. add new “BR2_PACKAGE_NFS_UTILS=y” in configs/buildroot/qoriq_arm64_tiny_defconfig
2. rebuild it
$ flex-builder -i clean-rfs -r buildroot:tiny
$ flex-builder -i mkrfs -r buildroot:tiny
I am runing flex-builder in a virtual box vm on a Windows 10 host.
When I run: flex-builder -i mkrfs -r ubuntu:lite
It fails with this error.
gpgv: Good signature from "Ubuntu Archive Automatic Signing Key (2012) <ftpmaster@ubuntu.com>"
terminate called after throwing an instance of 'std::runtime_error'
what(): random_device::random_device(const std::string&)
qemu: uncaught target signal 6 (Aborted) - core dumped
/usr/local/bin/flex-mkdistrorfs: line 151: 7489 Aborted (core dumped) DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true LC_ALL=C LANGUAGE=C LANG=C apt -y update
I believe this is an error running qemu? Should I expect flex-builder to run in a VM?
According to your following log, it seems that you didn't download the rootfs filesystem completely. As normal, the date size of ramdisk Image should be 600-700M.
Trying 'initrd' ramdisk subimage
Description: initrd for arm64
Created: 2021-03-23 22:10:05 UTC
Type: RAMDisk Image
Compression: uncompressed
Data Start: 0xa0d6e72c
Data Size: 138956800 Bytes = 132.5 MiB
Architecture: AArch64
You could regenerate the itb image with the following procedure.
$ flex-builder -i clean-rfs
$ rm packages/rfs/initrd/rootfs_lsdk2012_ubuntu_main_arm64.cpio.gz
$ flex-builder -i mkitb -r ubuntu:main -a arm64
In addition, the ubuntu:main rootfs is too large to run on LS1046AFRWY, you could use Ubuntu-based lite rootfs filesystem(Include Ubuntu 18.04 base packages and part of NXP's packages), it is about 180M, you could generate the itb image with the following command.
$ flex-builder -i mkitb -r ubuntu:lite -a arm64
Now I am having problems build ubuntu:lite
I am running flex-builder in a virtual box vm instance of Ubuntu 18.04
When I try to run
flex-builder -i clean-rfs -r ubuntu:lite -a arm64
flex-builder -i mkrfs -r ubuntu:lite -a arm64
I goes all along and runs into this error.
gpgv: Good signature from "Ubuntu Archive Automatic Signing Key (2012) <ftpmaster@ubuntu.com>"
terminate called after throwing an instance of 'std::runtime_error'
what(): random_device::random_device(const std::string&)
qemu: uncaught target signal 6 (Aborted) - core dumped
/usr/local/bin/flex-mkdistrorfs: line 151: 7489 Aborted (core dumped) DEBIAN_FRONTEND=noninteractive DEBCONF_NONINTERACTIVE_SEEN=true LC_ALL=C LANGUAGE=C LANG=C apt -y update