Tiny Core Linux
Tiny Core Base => TCB Q&A Forum => Topic started by: bobl on June 25, 2016, 12:42:46 AM
-
I want to reduce the size of the package partition mmcblk0p2 in my case but that requires mmcblk0p2 to be unmounted. Doing that though kills ssh. so best I put the resize2fs command into a startup script that runs before mmcblk0p2 gets mounted. Where should that go?
-
Depending on available RAM and installed TCZ packages the easiest way is to copy all used extensions to RAM. Than you can safely umount mmcblk2 and do what you want.
-
do you have a magic incantation for that
-
I managed to do it in the shutdown script by changing the script to
umount /dev/mmcblk0p2
/resize2fs /dev/mmcblk0p2 <size>
umount -afr
...
and copying resize2fs into the root directory, the beauty is that once executed the scripts are wiped clean across the reboot because / is in ram.
After the reboot I reduced the partition size to match in fdisk.