OpenELEC / OpenELEC.tv

OpenELEC - The living room PC for everyone
http://openelec.tv
1.6k stars 887 forks source link

[IMX6] Cubox-i4Pro - storage partition resize fails on first boot #5004

Closed Andy-ABTec closed 7 years ago

Andy-ABTec commented 7 years ago

Hi, have been playing with devel-20170121115440-r23710-gf0a2bdf on my Cubox-i4... Everything looked good until I realized that the /storage partiton had not been resized at initial boot and was full viz:

OpenELEC:~ # df Filesystem 1K-blocks Used Available Use% Mounted on devtmpfs 738288 0 738288 0% /dev /dev/mmcblk0p1 524008 163544 360464 31% /flash /dev/mmcblk0p2 27633 26978 0 100% /storage /dev/loop0 156416 156416 0 100% / tmpfs 903020 0 903020 0% /dev/shm tmpfs 903020 8204 894816 1% /run tmpfs 903020 0 903020 0% /sys/fs/cgroup tmpfs 903020 236 902784 0% /var tmpfs 903020 0 903020 0% /tmp OpenELEC:

Which played merry hell with the database and the ability to create advancedsettings.xml.

Only other oddity I spotted is that the red light on the front of the cube is flashing rather than on all the time (flash-flash-pause, flash-flash-pause).

Other than that,looks good and appears to play video without problems (so far so good)...

Andy B.

Andy-ABTec commented 7 years ago

OK, so resizing the partition with gparted "fixes" the problem, the database updates as expected and I can even point the cube at a MySQL server on my NAS.

Still have the flashing led problem, and the partition problem obviously needs a proper sort out (by someone brighter than me! - Not hard...)

sraue commented 7 years ago

thanks for the report, will look at this

Andy-ABTec commented 7 years ago

Since opening this issue I've been poking about trying to figure out how the ext4 partition gets resized on first boot, and I'm not having a lot of luck.. Can some kind soul point me in the right direction please? Thanks...

Andy-ABTec commented 7 years ago

OK, So I've just built yet another image from scratch... BEFORE testing in the box I mounted the images as files systems to check their content. The 2nd (32MB) partition contains a single empty file /storage/.please_resize_me which is correct. Copying SYSTEM from the 1st (512MB) partition elsewhere and unsquashing it give me access to

/usr/lib/openelec/fs-resize /usr/lib/systemd/system/fs-resize.service /usr/lib/systemd/system/fs-resize.target

The content of which all seems to be fine...

Acid test, make a new "disk" and boot it, no partition resize, I'm at a loss...

sraue commented 7 years ago

should work now, create a new report if this problem still exist