Procedure for enlarging filesystem on CM4
Egon Rath (2225) 54 posts |
Hi, is there a procedure on how to enlarge the internal eMMC storage of a CM4? Have the version with 32 GB eMMC and want to make use of the whole space – the downloadable 5.30 for the Raspberry Pi has only a 2 GB filesystem on it. With kind regards, |
David Pitt (9872) 363 posts |
Once RISC OS is on the CM4 SystemDisc can be used. Copy RISC OS onto a second device first, an NVMe here. That is how I fully utilised the 32GB eMMC here. Not having SystemDisc might be considered an obstacle though. I already had a 32GB SD card with RISC OS on it, that will be easy I thought, use Imager or rpiboot to write that to the 32GB eMMC. The flaw in that is the obvious one, some 32GB devices are more 32GB than other 32GB devices!! |
Chris Hall (132) 3554 posts |
You need to do some preparation first. For example take a RISC OS formatted USB drive and put on it !SystemDisc and a directory containing the firmware from SDFS::eMMc4.$.Boot.Loader as well as the HardDisc contents on the eMMc. Run !SystemDisc from the USB drive (which completely wipes the eMMc storage and adds a single DOS image file Boot:Loader), then without resetting your machine, copy the firmware into Loader and copy the HardDisc contents (except Boot:Loader) onto the eMMc. Remove the USB drive and reboot. |
Jon Abbott (1421) 2651 posts |
Alternatively, if your CM4 is already ’net connected you could use Partition Manager to initialise a Pi boot drive. Unfortunately, because you can’t format the drive RISC OS booted from without RISC OS breaking horribly, it is a bit of a convoluted process:
This will get you a bare bones RISC OS machine with PackMan and NetSurf. It will not contain all the extras the SD image comes with as ROOL do not provide them in ZIP format. If that’s an issue, instead of using PM to create the temporary boot drive:
|
David Pitt (9872) 363 posts |
For some reason RISC OS will not boot from the CM4’s USB A sockets, it stops at a black screen. Some video is there, the monitor light is green not yellow, but there is no other sign of life. RISC OS can however see them once from elsewhere. Raspberry Pi OS on the other hand will boot from those USB A sockets. USB boot priority is set on my CM4 to enable a Raspberry Pi OS boot, overriding the default eMMC boot in case it was to get garbaged somehow, for example by installing a beta ROM image that fails to start. Raspberry Pi OS can see the eMMC FAT partition. |
Chris Gransden (337) 1207 posts |
I had that problem until I upgraded the bootloader to the latest version.
|
Egon Rath (2225) 54 posts |
Thanks for all the information, will go the Partition Manager way! |
Egon Rath (2225) 54 posts |
@Chris Grandsen Can you please share your boot.conf (especially the BOOT_ORDER variable) – I can’t get my CM4 to boot from USB even with the eeprom updated to 2024/05/17 (the same you run) |
David Pitt (9872) 363 posts |
Neither can I. *vcgencmd bootloader_version 2024/05/17 12:26:58 ... *vcgencmd bootloader_config [all] ... BOOT_ORDER=0xf145 * Previously with a Jan23 eeprom it was possible to boot Raspberry Pi OS from a USB device but not now. With no USB devices connected the splash screen does show the boot mode as :-
Then it tries f14 before starting eMMC. f15 should be sufficient but didn’t work either. |
David Pitt (9872) 363 posts |
Boot order is set to f15. On the CM4 the last eeprom that allows Raspberry OS on a USB device to start is 24-04-15, eeproms after that fail and hang the CM4 so that the eMMC does not get to start. So far, RISC OS never boots from USB. It is possible different IO boards may behave differently, here it is a Waveshare PoE Board (B). |
Egon Rath (2225) 54 posts |
Hi, just wanted to quickly outline the way I used to get it up and running without being able to boot from USB: 1.) Set jumper J2 to force the CM4 into bootloader mode With kind regards, |
Koen (10031) 9 posts |
I have my CM4 at the ready. Just waiting for the direct version to get the 5.30 treatment. |
Chris Hall (132) 3554 posts |
Is there a reason for the 2GB maximum size? Yes. It is within the maximum file size under RISC OS. It means the download is small. It works with pretty much any SD card. Given that most machines have 2GB or more RAM it is a pity that we don’t have a utility that will read in the contents of the SD card to RAM and offer to reformat the SD card to a size that you require and copy the files back again. |
André Timmermans (100) 655 posts |
I am pretty sure Jeffrey extended the maximum file size limit to 4GB quite a while ago. Or was that only in FileSwitch and FileCore is still tuck to 2GB? |
Steve Pampling (1551) 8170 posts |
bq. Is there a reason for the 2GB maximum size? You can do nested quotes by entering the markers HTML style inside < > See the Textile help (main link at the foot of the thread page, specific for blockquotes HTML section of this linked page |