gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 1:23 pm

I am writing from the 32-bit Raspbian Os of my new Pi3 B+, but as you know this has 64-bit chips inside.

What's the easiest way to upgrade to any ARM64 distro - preferably Ubuntu, Debian, Fedora?

I did hear that OpenSUSE might be better for ARM64/KVM? If the kernel has KVM/hardware virtualization enabled then it should it appear under /dev/kvm

Does R Pi3 B+ have a bios? Can it boot from a live USB/SD created with Rufus?

If I have to work with an img.xz or tar.gz is there a step-by-step guide I can follow to ensure this gets copied across correctly and is bootable?

fruitoftheloom
Posts: 16608
Joined: Tue Mar 25, 2014 12:40 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 2:06 pm

gilius wrote:
Sun Apr 08, 2018 1:23 pm
I am writing from the 32-bit Raspbian Os of my new Pi3 B+, but as you know this has 64-bit chips inside.

What's the easiest way to upgrade to any ARM64 distro - preferably Ubuntu, Debian, Fedora?

I did hear that OpenSUSE might be better for ARM64/KVM? If the kernel has KVM/hardware virtualization enabled then it should it appear under /dev/kvm

Does R Pi3 B+ have a bios? Can it boot from a live USB/SD created with Rufus?

If I have to work with an img.xz or tar.gz is there a step-by-step guide I can follow to ensure this gets copied across correctly and is bootable?

Regards BIOS, no Raspberry Pi has one and all boot from the VPU.

Regards Booting Options see:

https://www.raspberrypi.org/documentati ... /README.md
Adieu

User avatar
mahjongg
Forum Moderator
Forum Moderator
Posts: 10583
Joined: Sun Mar 11, 2012 12:19 am
Location: South Holland, The Netherlands

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 2:56 pm

no "upgrade paths" exist to a 64-bit version.
Some experimental 64-bit OS's do exists, but these are for the 3B and have probably not have had time to write an upgrade to the 3B+.

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 3:14 pm

First step seems to be getting mass USB storage working - done:
https://www.raspberrypi.org/documentati ... des/msd.md

Presumably nobody has got UEFI boot working yet for live distros?
https://github.com/andreiw/RaspberryPiPkg
So that does not leave many options for replacing the default operating system.

Instead of upgrading then, how to get a fresh ARM64 distro onto the Pi 3 b+? Experimental would be fine. Just need a decent AARCH64 kernel with KVM enabled...

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 5:12 pm

I managed to get a version of Ubuntu Mate to boot from USB by following the instructions above, but I had to first remove the SD card (till I find a way to change the boot order).

The installer was an experimental/custom one that somebody had put together for the Pi3 specifically. I was able to copy it to USB in DDImage mode using Rufus - included 2 partitions. The SDCard procedure appears to be different.

So far so good... Now I'm looking for an ARM64 one to try - hopefully with KVM installed.

feelslikeautumn
Posts: 225
Joined: Wed Aug 09, 2017 9:51 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 5:32 pm

gilius wrote:
Sun Apr 08, 2018 1:23 pm
I am writing from the 32-bit Raspbian Os of my new Pi3 B+, but as you know this has 64-bit chips inside.

What's the easiest way to upgrade to any ARM64 distro - preferably Ubuntu, Debian, Fedora?

I did hear that OpenSUSE might be better for ARM64/KVM? If the kernel has KVM/hardware virtualization enabled then it should it appear under /dev/kvm

Does R Pi3 B+ have a bios? Can it boot from a live USB/SD created with Rufus?

If I have to work with an img.xz or tar.gz is there a step-by-step guide I can follow to ensure this gets copied across correctly and is bootable?
If you are just after arm64 KVM, then I think all you need is a 64 bit kernel rather than upgrading the whole os to 64 bit. There is also multi-arch - https://wiki.debian.org/Multiarch/HOWTO

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 7:24 pm

feelslikeautumn wrote:
Sun Apr 08, 2018 5:32 pm
gilius wrote:
Sun Apr 08, 2018 1:23 pm
I am writing from the 32-bit Raspbian Os of my new Pi3 B+, but as you know this has 64-bit chips inside.

What's the easiest way to upgrade to any ARM64 distro - preferably Ubuntu, Debian, Fedora?

I did hear that OpenSUSE might be better for ARM64/KVM? If the kernel has KVM/hardware virtualization enabled then it should it appear under /dev/kvm

Does R Pi3 B+ have a bios? Can it boot from a live USB/SD created with Rufus?

If I have to work with an img.xz or tar.gz is there a step-by-step guide I can follow to ensure this gets copied across correctly and is bootable?
If you are just after arm64 KVM, then I think all you need is a 64 bit kernel rather than upgrading the whole os to 64 bit. There is also multi-arch - https://wiki.debian.org/Multiarch/HOWTO
That would be even better!! How can I upgrade just the kernel to 64-bit KVM based on a 32-bit Os?

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Apr 08, 2018 7:58 pm

This seems to have almost worked in 32-bit Ubuntu Mate, but there was some errors at the end:
$ sudo dpkg --add-architecture arm64
$ sudo apt-get update
$ sudo apt-get install linux-image-generic:arm64


Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
devio:arm64 flash-kernel:arm64 gcc-6-base:arm64 libc-dev-bin libc6
libc6:arm64 libc6-dev libgcc1:arm64 linux-image-4.4.0-119-generic:arm64
Suggested packages:
u-boot-tools:arm64 glibc-doc glibc-doc:arm64 locales:arm64 fdutils:arm64
linux-doc-4.4.0:arm64 | linux-source-4.4.0:arm64 linux-tools:arm64
linux-headers-4.4.0-119-generic:arm64
The following NEW packages will be installed:
devio:arm64 flash-kernel:arm64 gcc-6-base:arm64 libc6:arm64 libgcc1:arm64
linux-image-4.4.0-119-generic:arm64 linux-image-generic:arm64
The following packages will be upgraded:
libc-dev-bin libc6 libc6-dev
3 upgraded, 7 newly installed, 0 to remove and 531 not upgraded.
Need to get 61.2 MB of archives.
After this operation, 246 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://ports.ubuntu.com xenial-updates/main armhf libc6-dev armhf 2.23-0ubuntu10 [1,639 kB]
Get:2 http://ports.ubuntu.com xenial-updates/main armhf libc-dev-bin armhf 2.23-0ubuntu10 [59.4 kB]
Get:3 http://ports.ubuntu.com xenial-updates/main armhf libc6 armhf 2.23-0ubuntu10 [2,147 kB]
Get:4 http://ports.ubuntu.com xenial/main arm64 gcc-6-base arm64 6.0.1-0ubuntu1 [14.3 kB]
Get:5 http://ports.ubuntu.com xenial/main arm64 libgcc1 arm64 1:6.0.1-0ubuntu1 [30.1 kB]
Get:6 http://ports.ubuntu.com xenial-updates/main arm64 libc6 arm64 2.23-0ubuntu10 [2,195 kB]
Get:7 http://ports.ubuntu.com xenial/main arm64 devio arm64 1.2-1build2 [17.2 kB]
Get:8 http://ports.ubuntu.com xenial-updates/main arm64 flash-kernel arm64 3.0~rc.4ubuntu62.2 [18.1 kB]
Get:9 http://ports.ubuntu.com xenial-updates/main arm64 linux-image-4.4.0-119-generic arm64 4.4.0-119.143 [55.0 MB]
Get:10 http://ports.ubuntu.com xenial-updates/main arm64 linux-image-generic arm64 4.4.0.119.125 [2,404 B]
Fetched 61.2 MB in 7s (8,427 kB/s)
Preconfiguring packages ...
(Reading database ... 172539 files and directories currently installed.)
Preparing to unpack .../libc6-dev_2.23-0ubuntu10_armhf.deb ...
Unpacking libc6-dev:armhf (2.23-0ubuntu10) over (2.23-0ubuntu5) ...
Preparing to unpack .../libc-dev-bin_2.23-0ubuntu10_armhf.deb ...
Unpacking libc-dev-bin (2.23-0ubuntu10) over (2.23-0ubuntu5) ...
Preparing to unpack .../libc6_2.23-0ubuntu10_armhf.deb ...
Unpacking libc6:armhf (2.23-0ubuntu10) over (2.23-0ubuntu5) ...
Selecting previously unselected package libc6:arm64.
Preparing to unpack .../libc6_2.23-0ubuntu10_arm64.deb ...
Unpacking libc6:arm64 (2.23-0ubuntu10) ...
Setting up libc6:armhf (2.23-0ubuntu10) ...
Processing triggers for libc-bin (2.23-0ubuntu5) ...
Processing triggers for man-db (2.7.5-1) ...
Selecting previously unselected package libgcc1:arm64.
(Reading database ... 172843 files and directories currently installed.)
Preparing to unpack .../libgcc1_1%3a6.0.1-0ubuntu1_arm64.deb ...
Unpacking libgcc1:arm64 (1:6.0.1-0ubuntu1) ...
Selecting previously unselected package gcc-6-base:arm64.
Preparing to unpack .../gcc-6-base_6.0.1-0ubuntu1_arm64.deb ...
Unpacking gcc-6-base:arm64 (6.0.1-0ubuntu1) ...
Processing triggers for libc-bin (2.23-0ubuntu5) ...
Setting up gcc-6-base:arm64 (6.0.1-0ubuntu1) ...
Setting up libgcc1:arm64 (1:6.0.1-0ubuntu1) ...
Setting up libc6:arm64 (2.23-0ubuntu10) ...
Processing triggers for libc-bin (2.23-0ubuntu5) ...
Selecting previously unselected package devio:arm64.
(Reading database ... 172848 files and directories currently installed.)
Preparing to unpack .../devio_1.2-1build2_arm64.deb ...
Unpacking devio:arm64 (1.2-1build2) ...
Selecting previously unselected package flash-kernel:arm64.
Preparing to unpack .../flash-kernel_3.0~rc.4ubuntu62.2_arm64.deb ...
Unpacking flash-kernel:arm64 (3.0~rc.4ubuntu62.2) ...
Selecting previously unselected package linux-image-4.4.0-119-generic:arm64.
Preparing to unpack .../linux-image-4.4.0-119-generic_4.4.0-119.143_arm64.deb ...
Done.
Unpacking linux-image-4.4.0-119-generic:arm64 (4.4.0-119.143) ...
Selecting previously unselected package linux-image-generic:arm64.
Preparing to unpack .../linux-image-generic_4.4.0.119.125_arm64.deb ...
Unpacking linux-image-generic:arm64 (4.4.0.119.125) ...
Processing triggers for man-db (2.7.5-1) ...
Setting up libc-dev-bin (2.23-0ubuntu10) ...
Setting up libc6-dev:armhf (2.23-0ubuntu10) ...
Setting up devio:arm64 (1.2-1build2) ...
Setting up flash-kernel:arm64 (3.0~rc.4ubuntu62.2) ...
Setting up linux-image-4.4.0-119-generic:arm64 (4.4.0-119.143) ...
Running depmod.
update-initramfs: deferring update (hook will be called later)
Examining /etc/kernel/postinst.d.
run-parts: executing /etc/kernel/postinst.d/apt-auto-removal 4.4.0-119-generic /boot/vmlinuz-4.4.0-119-generic
run-parts: executing /etc/kernel/postinst.d/initramfs-tools 4.4.0-119-generic /boot/vmlinuz-4.4.0-119-generic
update-initramfs: Generating /boot/initrd.img-4.4.0-119-generic
cryptsetup: WARNING: failed to detect canonical device of /dev/sda2
cryptsetup: WARNING: could not determine root device from /etc/fstab

gzip: stdout: No space left on device
E: mkinitramfs failure cpio 141 gzip 1
update-initramfs: failed for /boot/initrd.img-4.4.0-119-generic with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
Failed to process /etc/kernel/postinst.d at /var/lib/dpkg/info/linux-image-4.4.0-119-generic.postinst line 1052.
dpkg: error processing package linux-image-4.4.0-119-generic:arm64 (--configure):
subprocess installed post-installation script returned error exit status 2
dpkg: dependency problems prevent configuration of linux-image-generic:arm64:
linux-image-generic:arm64 depends on linux-image-4.4.0-119-generic; however:
Package linux-image-4.4.0-119-generic:arm64 is not configured yet.

dpkg: error processing package linux-image-generic:arm64 (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
E: Sub-process /usr/bin/dpkg returned an error code (1)

feelslikeautumn
Posts: 225
Joined: Wed Aug 09, 2017 9:51 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 7:13 am

You've just run out of space on the /boot partition. This is going to be the least of your troubles. I wouldn't want you to waste your time on this, it is probably easier to install 64bit fedora or opensuse. Alexander Graf is involved in KVM and opensuse arm, so of the two, I would say that is the most likely to have working KVM on the pi.

You've got a new 3B+ so that complicates things a little. You'll probably have to update the firmware bootloader files and sort out a missing dtb file. Have a read of their arm mailing lists and pi wiki pages. If you have to ask a question on a mailing list, you'll get a much better response if you demonstrate that you've tried to solve the problem yourself and have thoroughly researched the problem.


gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 6:47 pm

feelslikeautumn wrote:
Mon Apr 09, 2018 12:11 pm
Debian arm64 instructions for the 3B+ https://github.com/Debian/raspi3-image-spec/issues/12
Thanks, but before I can copy the firmware to the first partition, how can I create the two imaged partitions in the first place (including the file system) from one of these packages to a USB/SDCard?
https://d-i.debian.org/daily-images/arm64/daily/

If they were distributed as an IMG file with 2 partitions then it would be so much more simpler.

feelslikeautumn
Posts: 225
Joined: Wed Aug 09, 2017 9:51 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 8:46 pm

gilius wrote:
Mon Apr 09, 2018 6:47 pm
If they were distributed as an IMG file with 2 partitions then it would be so much more simpler.
They are https://wiki.debian.org/RaspberryPi3

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 9:09 pm

It's now copying onto my empty SDCard, so let's see what happens... *fingers crossed*

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 9:34 pm

Unfortunately, booted with a black screen of death - and seems to have ruined my primary USB Noobs/Raspbian operating system too, for some reason, even though I outputted it to the SDCard - so now I guess I need to replace the boot files. How about if I just copied them from Noobs and put them on here - would that work?

Directory of E:\Torrents\NOOBS_v2_7_0

09/04/2018 22:29 <DIR> .
09/04/2018 22:29 <DIR> ..
14/03/2018 09:38 15,983 bcm2708-rpi-0-w.dtb
14/03/2018 09:38 15,779 bcm2708-rpi-b-plus.dtb
14/03/2018 09:38 15,520 bcm2708-rpi-b.dtb
14/03/2018 09:38 15,239 bcm2708-rpi-cm.dtb
14/03/2018 09:38 16,758 bcm2709-rpi-2-b.dtb
14/03/2018 09:38 17,980 bcm2710-rpi-3-b-plus.dtb
14/03/2018 09:38 17,859 bcm2710-rpi-3-b.dtb
14/03/2018 09:38 16,615 bcm2710-rpi-cm3.dtb
14/03/2018 09:38 52,064 bootcode.bin
14/03/2018 09:38 302 BUILD-DATA
14/03/2018 09:37 <DIR> defaults
14/03/2018 09:37 2,356 INSTRUCTIONS-README.txt
14/03/2018 00:33 <DIR> os
14/03/2018 09:37 <DIR> overlays
14/03/2018 09:38 99 recovery.cmdline
14/03/2018 09:38 671,556 recovery.elf
14/03/2018 09:38 2,873,816 recovery.img
14/03/2018 09:38 28,565,504 recovery.rfs
14/03/2018 09:38 2,947,752 recovery7.img
14/03/2018 09:38 0 RECOVERY_FILES_DO_NOT_EDIT
14/03/2018 09:37 9,728 riscos-boot.bin
18 File(s) 35,254,910 bytes

Directory of g:\

08/01/2018 18:40 50,248 bootcode.bin
08/01/2018 18:40 6,563 fixup.dat
08/01/2018 18:40 2,596 fixup_cd.dat
08/01/2018 18:40 9,708 fixup_db.dat
08/01/2018 18:40 9,706 fixup_x.dat
08/01/2018 18:40 2,819,300 start.elf
08/01/2018 18:40 668,388 start_cd.elf
08/01/2018 18:40 4,958,852 start_db.elf
08/01/2018 18:40 3,904,164 start_x.elf
08/01/2018 18:42 17,342,976 vmlinuz-4.14.0-3-arm64
08/01/2018 18:42 18,573,306 initrd.img-4.14.0-3-arm64
08/01/2018 18:42 12,632 bcm2837-rpi-3-b.dtb
08/01/2018 18:42 296 config.txt
08/01/2018 18:42 114 cmdline.txt
14 File(s) 48,358,849 bytes

The file system partition looks good, so I guess it's just this boot partition that needs fixing.

gilius
Posts: 50
Joined: Sun Apr 08, 2018 1:12 pm

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Mon Apr 09, 2018 10:32 pm

I managed to get it to boot up!!! :D But I had to look deep inside this package and extract the firmware, overwriting the Debian ones on the boot partition:
https://packages.debian.org/sid/arm64/r ... e/download
firmware.PNG
firmware.PNG (26.68 KiB) Viewed 801 times
Username: root
Password: raspberry

Unfortunately, there's no internet access/working network drivers nor GUI, so I don't think I am going to be able to do much on it. However, it's good progress nevertheless...

Olle2
Posts: 11
Joined: Wed Jan 04, 2017 7:59 am

Re: Upgrading to *any* ARM64 distro - with a KVM-enabled kernel?

Sun Jun 03, 2018 5:51 am

Did you try devuan_ascii_2.0.0-rc_arm64_raspi3.img.xz
as found here https://files.devuan.org/devuan_ascii_rc/embedded/ ?

kvmtool https://git.kernel.org/cgit/linux/kerne ... mtool.git/ is available in synaptic.

Some virtuals https://files.devuan.org/devuan_ascii_rc/virtual/

Good luck! /Olle

Return to “Other”

Who is online

Users browsing this forum: No registered users and 12 guests