rasberry pi upgrade 3b->4 - Page 1
Forum section: electronics / general

author: bogdant
author_rank: Regular Contributor
timestamp: July 15, 2021, 03:53:39 pm
content: I have a raspberry pi 3b with a ubuntu server 20 is a working state (connected via eth to a router) and today arrived the upgrade rasberry pi 4 8G.The question is if I just move the SDCARD from rassbery pi 3b to rasberry pi 4 will it boot and have the chance to connect via ssh ?

author: SiliconWizard
author_rank: Super Contributor
timestamp: July 15, 2021, 05:37:34 pm
content: Quote from: bogdant on July 15, 2021, 03:53:39 pmI dont think so.If I'm not mistaken:- The RPi3B has a BCM2837 SOC. This is based on a Cortex-A53.- The RPi4 has a BCM2711 SOC. Based on Cortex-A72.Both CPUs are 64-bit ARM, but not the same. I would expect a number of incompatibilities. There probably are several other hardware differences with onboard peripherals.

author: jenniferkim
author_rank: Contributor
timestamp: July 22, 2021, 09:01:41 pm
content: It is not recommended, but after making a full back up change the sources from Stretch to Buster:This has a section for Jessie to Stretch, just change the names:https://www.raspberrypi.org/documentation/raspbian/updating.mdPersonally just went with creating a fresh Raspbian Buster in yourRPi4with Desktop SD Card......

author: dave j
author_rank: Regular Contributor
timestamp: July 23, 2021, 08:49:08 am
content: Quote from: jenniferkim on July 22, 2021, 09:01:41 pmThe OP is asking about moving from a Pi3 to a Pi4 whilst running Ubuntu not migrating to a new version of Raspberry Pi OS.@bogdantLooking at theUbuntu for Raspberry Pi download page, they don't have separate 64 bit versions for Pi3s and Pi4s. Assuming you are running an up to date 64 bit Ubuntu on your Pi3 there's a good chance it will work. It doesn't say the 32 bit version won't run on the Pi4 but with 8Gb of memory, you'd probably want to be using the 64 bit version anyway.

author: ralphrmartin
author_rank: Frequent Contributor
timestamp: July 24, 2021, 04:16:57 pm
content: I had an RPI3B running a web server, samba server, rss server, with raspbian and software fully updated, with root file system on an SSD. I just switched the SD and SSD over to an RPI4, rebooted, and everything "just worked".Now, there may be corner cases which rely on the hardware in some way, or speed of operation, etc, but for "straightforward" use cases, a simple switch of this kind appears to work just fine for raspbian. Ubuntu should be similar, but may differ.

author: SiliconWizard
author_rank: Super Contributor
timestamp: July 24, 2021, 04:48:37 pm
content: Well, if the Linux install you had on the 3B was up to date enough, I guess it would have all required hardware support in the kernel already anyway, so that part should work. But say you have a Linux install dated from when the 3B was just released and you never updated it, then I would doubt things would be as smooth already...I would also have suspected possible differences in the specific boot code that's on the SD card (or SSD) and which runs on the SoC's GPU, initializes hardware prior to handing over control to the ARM CPU. For this part, I am pretty surprised it would work without a hitch...In any case, I would ask relevant advice on the RPi forums at the very least, hopefully getting an answer from some engineer from RPi itself. Just because it appears to work OK doesn't mean it's fully reliable or won't get you intro troubles later on. Again knowing how the boot process works on those boards (and the fact the boot code on the GPU - Videocore - is not open source) makes me pretty wary.What I would personally do at the very least would be to overwrite the boot file with one that is officially compatible with the RPi4. That's the "bootcode.bin" file. I know there's also a fixup file (for instance named "fixup4.dat" for the RPi4). Which role I frankly am not sure about.So, while the Linux part itself should be no problem as long as it's recent enough, I am frankly not comfortable with all this boot process that is largely undocumented, and different for each RPi version as far as I've seen.

author: ralphrmartin
author_rank: Frequent Contributor
timestamp: July 25, 2021, 04:35:24 pm
content: The Raspberry Pi 4B does not use the bootcode.bin file, but an EEPROM based bootloader.

author: SiliconWizard
author_rank: Super Contributor
timestamp: July 25, 2021, 05:05:05 pm
content: Quote from: ralphrmartin on July 25, 2021, 04:35:24 pmAh, thanks. I had to look up for that info. You can see it here:https://www.raspberrypi.org/documentation/hardware/raspberrypi/bootmodes/bootflow_2711.mdI did baremetal dev on RPi4's so far. IIRC I got the links to the bootcode files and such from the RPi forum. Guess I was not the only one confused about the RPi4 boot process then... I'll just have to check now. Certainly I can just remove the bootcode.bin file and it should boot normally? It was just not using it if I got it right...So that would explain how easy it is as long as your OS supports the RPi4 SOC and related hardware.

author: ejeffrey
author_rank: Super Contributor
timestamp: July 26, 2021, 05:30:24 pm
content: As far as I understand the way it is *supposed* to work, at least in the standard Raspberry pi os is that the bootcode, either bootcode.bin or the built in bootloader is supposed to use the hardware ID, load the appropriate device tree overlays for the version and type, then the kernel which is a 32-bit kernel that is compatible with all PI SoCs. There is a 64-bit build but AFAIK that is still beta / development only.Other operating systems for the Pi (such as ubuntu or debian) do things slightly differently and may not support all hardware versions. For instance when I was playing around with debian, it didn't have all of the device tree overlays in the boot partition. That means that if you needed a specific overlay to be present to boot into a usable configuration you could be hosed.

author: bogdant
author_rank: Regular Contributor
timestamp: July 27, 2021, 04:41:56 am
content: Thank you all for the answers. I did not try it the boot with the sd-card of 3b on 4, but instead I installed a new fresh image on new sdcard for rp4.The hardware is different and I did not want to risk the damage of the rp3b image. The effort to reinstall all software will not be necessary, I will split the tasks: on rp 3b remains the web server, and on rp4 i did migrate the git server, and I am thinking to install a private plex server to play music but I am not sure it has the necessary system requirements to do this.

author: ralphrmartin
author_rank: Frequent Contributor
timestamp: July 27, 2021, 03:38:09 pm
content: I run a plex server on another RPI 4B (again under raspbian).

author: bogdant
author_rank: Regular Contributor
timestamp: July 28, 2021, 05:24:39 am
content: I installed plex a private server on raspberry pi 4 yesterday and runs without any problem, it is specific for music. I did order an extern HDD 4T WD on USB3 to upgrade the space(128G now).

author: ralphrmartin
author_rank: Frequent Contributor
timestamp: July 28, 2021, 05:29:37 pm
content: Yes, perhaps I should have also said my plex server is for music only, and I haven't tried using it for video.