Nextbox No space left error on firmware upgrade

I am running a Nextbox-snap with an Ubuntu image on a Rasperry 2.
My probem is after running upgrades I always get an error message stating that initramfs-tools can’t complete the post-installation process, stating that the /boot/firmware-folder is out of space. This process creates backup copies of the old files in the firmware folder, resulting in missing space and incomplete initrd.img an vmlinuz files, which makes the system unbootable.

In my configuration the folder
/boot/firmware is the first partition of the sd-card, which contains the firmware. Initially it contained only 60 MB rougly, so I enlarged it to 400 MB. But the error message keeps on popping up. So I am wondering what is going here and would appreciate any help.

My System:
Linux nextcloud 4.4.0-1017-raspi2 #23-Ubuntu SMP Thu Jun 30 21:50:40 UTC 2016 armv7l armv7l armv7l GNU/Linux

    martin@nextcloud:~$ df
    Filesystem     1K-blocks      Used Available Use% Mounted on
    /dev/root      959206864 100258320 810200616  12% /
    devtmpfs          467856         0    467856   0% /dev
    tmpfs             473100         0    473100   0% /dev/shm
    tmpfs              94620      2952     91668   4% /run
    tmpfs               5120         0      5120   0% /run/lock
    tmpfs             473100         0    473100   0% /sys/fs/cgroup
    /dev/mmcblk0p1    425744     43272    382472  11% /boot/firmware
    /dev/loop1         85120     85120         0 100% /snap/core/10187
    /dev/loop0         85120     85120         0 100% /snap/core/10130
    /dev/loop3         46848     46848         0 100% /snap/core18/1889
    /dev/loop2         46592     46592         0 100% /snap/core18/1882
    /dev/loop4         56832     56832         0 100% /snap/lxd/16931
    /dev/loop5        231424    231424         0 100% /snap/nextcloud/23744
    /dev/loop6        235008    235008         0 100% /snap/nextcloud/23502
    tmpfs              94620         0     94620   0% /run/user/1001

error message at the end of the update process

    mv: cannot move '/boot/firmware/bcm2708-rpi-b-rev1.dtb' to '/boot/firmware/bcm2708-rpi-b-rev1.dtb.bak': No space left on device
run-parts: /etc/initramfs/post-update.d//flash-kernel exited with return code 1
dpkg: Fehler beim Bearbeiten des Paketes initramfs-tools (--configure):
 »installiertes initramfs-tools-Skript des Paketes post-installation«-Unterprozess gab den Fehlerwert 1 zurück
Fehler traten auf beim Bearbeiten von:
 initramfs-tools
E: Sub-process /usr/bin/dpkg returned an error code (1)

Can I see the output of df -i, please?

Hello kyrofa,
thanks for helping me.
Here is the output:

martin@nextcloud:~$ df -i
Filesystem       Inodes  IUsed    IFree IUse% Mounted on
/dev/root      60915712 206487 60709225    1% /
devtmpfs         116964   1395   115569    2% /dev
tmpfs            118275      1   118274    1% /dev/shm
tmpfs            118275   1358   116917    2% /run
tmpfs            118275      3   118272    1% /run/lock
tmpfs            118275     14   118261    1% /sys/fs/cgroup
/dev/mmcblk0p1        0      0        0     - /boot/firmware
/dev/loop1        12497  12497        0  100% /snap/core/10187
/dev/loop0        12486  12486        0  100% /snap/core/10130
/dev/loop5        24001  24001        0  100% /snap/nextcloud/23502
/dev/loop6        23784  23784        0  100% /snap/nextcloud/23744
/dev/loop2        10440  10440        0  100% /snap/core18/1882
/dev/loop3        10458  10458        0  100% /snap/core18/1889
/dev/loop4         1371   1371        0  100% /snap/lxd/16931
tmpfs            118275     22   118253    1% /run/user/1001

This is not the state of the /dev/mmcblk0p1 after the failed upgrade. As the system did not reboot properly after upgrade I reflashed the firmware partition with a backup I had made before.

Interesting, can I also see the output of mount, please?

Here you are:

martin@nextcloud:~$ mount
/dev/sda2 on / type ext4 (rw,noatime,data=ordered)
devtmpfs on /dev type devtmpfs (rw,relatime,size=467856k,nr_inodes=116964,mode=755)
sysfs on /sys type sysfs (rw,nosuid,nodev,noexec,relatime)
proc on /proc type proc (rw,relatime)
securityfs on /sys/kernel/security type securityfs (rw,nosuid,nodev,noexec,relatime)
tmpfs on /dev/shm type tmpfs (rw,nosuid,nodev)
devpts on /dev/pts type devpts (rw,nosuid,noexec,relatime,gid=5,mode=620,ptmxmode=000)
tmpfs on /run type tmpfs (rw,nosuid,nodev,size=94620k,mode=755)
tmpfs on /run/lock type tmpfs (rw,nosuid,nodev,noexec,relatime,size=5120k)
tmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755)
cgroup on /sys/fs/cgroup/systemd type cgroup (rw,nosuid,nodev,noexec,relatime,xattr,release_agent=/lib/systemd/systemd-cgroups-agent,name=systemd)
pstore on /sys/fs/pstore type pstore (rw,nosuid,nodev,noexec,relatime)
bpf on /sys/fs/bpf type bpf (rw,nosuid,nodev,noexec,relatime)
cgroup on /sys/fs/cgroup/cpu,cpuacct type cgroup (rw,nosuid,nodev,noexec,relatime,cpu,cpuacct)
cgroup on /sys/fs/cgroup/perf_event type cgroup (rw,nosuid,nodev,noexec,relatime,perf_event)
cgroup on /sys/fs/cgroup/blkio type cgroup (rw,nosuid,nodev,noexec,relatime,blkio)
cgroup on /sys/fs/cgroup/net_cls,net_prio type cgroup (rw,nosuid,nodev,noexec,relatime,net_cls,net_prio)
cgroup on /sys/fs/cgroup/freezer type cgroup (rw,nosuid,nodev,noexec,relatime,freezer)
cgroup on /sys/fs/cgroup/devices type cgroup (rw,nosuid,nodev,noexec,relatime,devices)
cgroup on /sys/fs/cgroup/memory type cgroup (rw,nosuid,nodev,noexec,relatime,memory)
systemd-1 on /proc/sys/fs/binfmt_misc type autofs (rw,relatime,fd=28,pgrp=1,timeout=0,minproto=5,maxproto=5,direct)
mqueue on /dev/mqueue type mqueue (rw,nosuid,nodev,noexec,relatime)
debugfs on /sys/kernel/debug type debugfs (rw,nosuid,nodev,noexec,relatime)
tracefs on /sys/kernel/tracing type tracefs (rw,nosuid,nodev,noexec,relatime)
fusectl on /sys/fs/fuse/connections type fusectl (rw,nosuid,nodev,noexec,relatime)
configfs on /sys/kernel/config type configfs (rw,nosuid,nodev,noexec,relatime)
/dev/mmcblk0p1 on /boot/firmware type vfat (rw,relatime,fmask=0022,dmask=0022,codepage=437,iocharset=ascii,shortname=mixed,errors=remount-ro)
/var/lib/snapd/snaps/core_10187.snap on /snap/core/10187 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/core_10130.snap on /snap/core/10130 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/nextcloud_23502.snap on /snap/nextcloud/23502 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/nextcloud_23744.snap on /snap/nextcloud/23744 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/core18_1882.snap on /snap/core18/1882 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/core18_1889.snap on /snap/core18/1889 type squashfs (ro,nodev,relatime,x-gdu.hide)
/var/lib/snapd/snaps/lxd_16931.snap on /snap/lxd/16931 type squashfs (ro,nodev,relatime,x-gdu.hide)
tmpfs on /run/snapd/ns type tmpfs (rw,nosuid,nodev,size=94620k,mode=755)
nsfs on /run/snapd/ns/nextcloud.mnt type nsfs (rw)
nsfs on /run/snapd/ns/lxd.mnt type nsfs (rw)
tmpfs on /run/user/1001 type tmpfs (rw,nosuid,nodev,relatime,size=94620k,mode=700,uid=1001,gid=1001)

Ah, fat? Why did you go that route? That explains the inode output. We’re a bit out of my wheelhouse here then, but check this out:

Not sure. I did flash the sd-card long time ago with Snappy Ubuntu. Me myself I did not choose that filesystem. You suggest, I should use another one like ext? I’ll give it a shot.