(07-06-2022, 12:27 PM)ichbins Wrote: Hello everybody,
I am trying to make a fresh install on my Pinephone, but it results in a device that is not booting anymore. I am flashing mobian-installer-pinephone-phosh-20220621.img to eMMC and the installation works as usual. After the installation I run apt update and apt upgrade and get this message in the status bar:
Low Disk Space on "Filesystem root"
The volume "Filesystem root" has only
166.3 MB disk space remaining.
The update process shows a littlebit later: No more disk space available.
Code:cp: Fehler beim Schreiben von '/var/tmp/mkinitramfs_sbR54T//usr/lib/aarch64-linux-gnu/libharfbuzz.so.0.20704.0':
Auf dem Gerät ist kein Speicherplatz mehr verfügbar
ERROR: Couldn't copy /bin/osk-sdl
E: /usr/share/initramfs-tools/hooks/osk-sdl failed with return 1.
update-initramfs: failed for /boot/initrd.img-5.15-sunxi64 with 1.
run-parts: /etc/kernel/postinst.d/initramfs-tools exited with return code 1
I: u-boot-menu: syncing /usr/lib/linux-image-5.15-sunxi64 to /boot/dtb-5.15-sunxi64
P: Checking for EXTLINUX directory... found.
P: Writing config for vmlinuz-5.15-sunxi64...
dpkg: Fehler beim Bearbeiten des Paketes linux-image-5.15-sunxi64 (--configure):
»installiertes post-installation-Skript des Paketes linux-image-5.15-sunxi64«-Unterprozess gab den Fehlerwert 1
zurück
I never had this disk space problem before, when I made a fresh installation. How should I make the installation and update to get a working system?
Emmc/SD card not being expanded on the Pinephone
On specific Pinephone installer images the storage medium Mobian is installed to does not get expanded to the full disk size. This can cause storage issues but can be fixed on the Pinephone in the terminal.
Assuming a ext4 setup.
First install parted by running
sudo apt install parted
Next, use parted on the correct drive
sudo parted /dev/mmcblkX
put 2 if its on a emmc. 0 for sd card verify with lsblk
To further verify run
Resize the second partition
resizepart 2 100%
Verify it has changed with
If you have FDE(Full Disk Encryption) setup run this to resize the encrypted device. If not using disk encryption skip this command.
sudo cryptsetup resize calamares_crypt
Next, resize the ext4 filesystem.
sudo resize2fs /dev/mapper/calamares_crypt
check the result with
df -h
This should fix the issue with file expansion on a fresh install.
If you have problems with parted I saved this from the faq and had to use the updated resize --> resizepart commands https://www.gnu.org/software/parted/manual/parted.html