If I upgrade the OS to buster on an OS disk (SD card or USB stick) on my pi 3, will it work if I boot a pi 4 off that?
Upgrading to Buster from Stretch isn't recommended. Install a new card and copy your old programs & data from the old system.
As long as you get the new kernel and firmware/bootcode for the BCM2711 processor installed on your SDCard it will boot on a RPi4.
If the card has NOOBS then forget it. Updating NOOBS for a new processor is a pain (always has been). It's not impossible, but it's not easy.
This can be done, but requires a bit of work to get the bootloader updated for Raspberry Pi 4. Here's how I did it:
- Back up your SD card!!! This can go wrong any number of ways. Not my fault if you bork something!
- Upgrade Raspbian on your Pi 3 to Raspbian Buster.
- Use Gparted on another computer to enlarge the boot partition of the card to 250MB. Make sure you don't move the start position of the boot partition.
- Put the card back in the Pi 3 and update the bootloader with the command
sudo apt install --reinstall raspberrypi-bootloader raspberrypi-kernel
- Put the card in your Pi 4 and hope for the best.