Mender partitions (A/B/data) within the SDcard image?
Aufschlauer opened this issue · 2 comments
Hi,
I'm stuck on first boot with my image. Here is the context:
- Target: Jetson Nano Developer Kit
- Branch:
hardknott
- Machine:
jetson-nano-devkit
- Distro:
tegrademo-mender
- Image:
core-image-minimal
- SD card: 32GB
Flashed using the dosdcard.sh
script on host
$ sudo ./dosdcard.sh /dev/mmcblk0
On first boot the system gets stuck at first boot
[ 6.806289] systemd[1]: Starting Mender service to grow data partition size...
...
[ 6.916597] systemd[1]: mender-grow-data.service: Main process exited, code=exited, status=1/FAILURE
[ 6.917367] EXT4-fs (mmcblk0p1): re-mounted. Opts: (null)
[ 6.931597] systemd[1]: mender-grow-data.service: Failed with result 'exit-code'.
[ 6.940498] systemd[1]: Failed to start Mender service to grow data partition size.
When I look at the status of the mender grow service (target is maintenance mode)
Mar 24 10:25:19 jetson-nano-devkit mender-client-resize-data-part[3566]: cat: can't open '/sys/block/mmcblk0/mmcblk0p3/size': No such file or directory
So, fdisk
shows that there is a single partition only:
$ fdisk -l /dev/mmcblk0
Disk /dev/mmcblk0: 29.72 GiB, 31914983424 bytes, 62333952 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 8223F1A7-3AD2-41DC-8A71-E8B92B422E8D
Device Start End Sectors Size Type
/dev/mmcblk0p1 2048 29362175 29360128 14G Linux filesystem
The mender data partition is not available and the mender-grow-data.service is right.
So, my question is whether the mender data partition should be within the image that is written to SDcard? Or at what point the mender data partition will be created?
Thanks.
The SDcard should have three partitions on it, if you're using the default flash layout we have for jetson-nano-devkit
in the tegrademo-mender
distro. The output from running the dosdcard.sh
script should have ended with something like this:
Init...APP...APP_b...UDA...[OK]
Writing...APP...APP_b...UDA...[OK: /dev/sda]
and your fdisk
output should be like this:
Disk /dev/mmcblk0: 29.72 GiB, 31914983424 bytes, 62333952 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: gpt
Disk identifier: 0C2780B4-C60E-458F-B6A7-8830E1599064
Device Start End Sectors Size Type
/dev/mmcblk0p1 2048 10459135 10457088 5G Linux filesystem
/dev/mmcblk0p2 10459136 20916223 10457088 5G Linux filesystem
/dev/mmcblk0p3 20916224 62333918 41417695 19.7G Linux filesystem
And if you examine the flash.xml.in
file you get after unpacking the tegraflash.tar.gz
package for your image build, you should see partition entries for all three partitions - APP
, APP_b
, and UDA
. I just checked this on a hardknott build of my own.
The flash layout for the non-Mender tegrademo
distro uses the L4T stock flash layout which places just the APP
partition on the SDcard. If you were trying non-Mender as well as Mender builds, perhaps there was a mixup somewhere?
Ok, thanks. I started over and now I got the same output and a login prompt of tegrademo-mender
distro.