Uploaded image for project: 'Mender'
  1. Mender
  2. MEN-1511

Very large updates with a lot of unused space causes unexpected EOF while doing the update

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Done
    • Priority: Higher
    • Resolution: Fixed
    • Affects Version/s: 1.2.0, 1.1.1
    • Fix Version/s: 1.3.0
    • Labels:

      Description

      Log from mailing list:

      2017-09-21 13:28:11 +0000 UTC debug: handle update fetch state
      2017-09-21 13:28:11 +0000 UTC info: Mender state: update-fetch -> update-install
      2017-09-21 13:28:11 +0000 UTC debug: handle update install state
      2017-09-21 13:28:11 +0000 UTC debug: Read data from device manifest file: device_type=firefly
      2017-09-21 13:28:11 +0000 UTC debug: Found needed line: device_type=firefly
      2017-09-21 13:28:11 +0000 UTC debug: Current manifest data: firefly
      2017-09-21 13:28:11 +0000 UTC debug: Trying to install update of size: 3145728000
      2017-09-21 13:28:11 +0000 UTC debug: Have U-Boot variable: mender_boot_part=3
      2017-09-21 13:28:11 +0000 UTC debug: List of U-Boot variables:map[mender_boot_part:3]
      2017-09-21 13:28:11 +0000 UTC debug: Setting active partition from mount candidate: /dev/mmcblk1p3
      2017-09-21 13:28:11 +0000 UTC debug: Detected inactive partition /dev/mmcblk1p2, based on active partition /dev/mmcblk1p3
      2017-09-21 13:28:11 +0000 UTC info: opening device /dev/mmcblk1p2 for writing
      2017-09-21 13:28:11 +0000 UTC info: partition /dev/mmcblk1p2 size: 4194304000
      2017-09-21 13:43:38 +0000 UTC error: failed to write image data to device /dev/mmcblk1p2: unexpected EOF
      2017-09-21 13:43:38 +0000 UTC info: wrote 2167668224/3145728000 bytes of update to device /dev/mmcblk1p2
      2017-09-21 13:43:39 +0000 UTC error: update install failed: installer: failed to read and install update: update: can not install update: &{linaro-rootfs.img 33188 1000 1000 3145728000 2017-09-18 13:40:27 +0200 CEST 48    0 0 0001-01-01 00:00:00 +0000 UTC 0001-01-01 00:00:00 +0000 UTC map[]}: update: can not install: unexpected EOF
      2017-09-21 13:43:39 +0000 UTC info: Mender state: update-install -> fetch-install-retry-wait
      2017-09-21 13:43:39 +0000 UTC debug: handle fetch install retry state
      2017-09-21 13:43:39 +0000 UTC debug: wait 1m0s before next fetch/install attempt
      2017-09-21 13:44:39 +0000 UTC debug: wait complete
      2017-09-21 13:44:39 +0000 UTC info: Mender state: fetch-install-retry-wait -> update-fetch
      2017-09-21 13:44:39 +0000 UTC debug: handle update fetch state
      2017-09-21 13:44:40 +0000 UTC info: Mender state: update-fetch -> update-install
      2017-09-21 13:44:40 +0000 UTC debug: handle update install state
      2017-09-21 13:44:40 +0000 UTC debug: Read data from device manifest file: device_type=firefly
      2017-09-21 13:44:40 +0000 UTC debug: Found needed line: device_type=firefly
      2017-09-21 13:44:40 +0000 UTC debug: Current manifest data: firefly
      2017-09-21 13:44:40 +0000 UTC debug: Trying to install update of size: 3145728000
      2017-09-21 13:44:40 +0000 UTC debug: Inactive partition: /dev/mmcblk1p2
      2017-09-21 13:44:40 +0000 UTC info: opening device /dev/mmcblk1p2 for writing
      2017-09-21 13:44:40 +0000 UTC info: partition /dev/mmcblk1p2 size: 4194304000
      2017-09-21 13:59:45 +0000 UTC error: failed to write image data to device /dev/mmcblk1p2: unexpected EOF
      2017-09-21 13:59:45 +0000 UTC info: wrote 2285633024/3145728000 bytes of update to device /dev/mmcblk1p2
      2017-09-21 13:59:45 +0000 UTC error: update install failed: installer: failed to read and install update: update: can not install update: &{linaro-rootfs.img 33188 1000 1000 3145728000 2017-09-18 13:40:27 +0200 CEST 48    0 0 0001-01-01 00:00:00 +0000 UTC 0001-01-01 00:00:00 +0000 UTC map[]}: update: can not install: unexpected EOF
      2017-09-21 13:59:45 +0000 UTC info: Mender state: update-install -> fetch-install-retry-wait
      2017-09-21 13:59:45 +0000 UTC debug: handle fetch install retry state
      2017-09-21 13:59:45 +0000 UTC debug: wait 1m0s before next fetch/install attempt
      2017-09-21 14:00:45 +0000 UTC debug: wait complete
      2017-09-21 14:00:45 +0000 UTC info: Mender state: fetch-install-retry-wait -> update-fetch
      2017-09-21 14:00:45 +0000 UTC debug: handle update fetch state
      2017-09-21 14:00:45 +0000 UTC info: Mender state: update-fetch -> update-install
      2017-09-21 14:00:45 +0000 UTC debug: handle update install state
      2017-09-21 14:00:45 +0000 UTC debug: Read data from device manifest file: device_type=firefly
      2017-09-21 14:00:45 +0000 UTC debug: Found needed line: device_type=firefly
      2017-09-21 14:00:45 +0000 UTC debug: Current manifest data: firefly
      2017-09-21 14:00:45 +0000 UTC debug: Trying to install update of size: 3145728000
      2017-09-21 14:00:45 +0000 UTC debug: Inactive partition: /dev/mmcblk1p2
      2017-09-21 14:00:45 +0000 UTC info: opening device /dev/mmcblk1p2 for writing
      2017-09-21 14:00:45 +0000 UTC info: partition /dev/mmcblk1p2 size: 4194304000
      2017-09-21 14:16:25 +0000 UTC error: failed to write image data to device /dev/mmcblk1p2: unexpected EOF
      2017-09-21 14:16:25 +0000 UTC info: wrote 2283142656/3145728000 bytes of update to device /dev/mmcblk1p2
      2017-09-21 14:16:27 +0000 UTC error: update install failed: installer: failed to read and install update: update: can not install update: &{linaro-rootfs.img 33188 1000 1000 3145728000 2017-09-18 13:40:27 +0200 CEST 48    0 0 0001-01-01 00:00:00 +0000 UTC 0001-01-01 00:00:00 +0000 UTC map[]}: update: can not install: unexpected EOF
      2017-09-21 14:16:27 +0000 UTC info: Mender state: update-install -> fetch-install-retry-wait
      2017-09-21 14:16:27 +0000 UTC debug: handle fetch install retry state
      2017-09-21 14:16:27 +0000 UTC debug: wait 1m0s before next fetch/install attempt
      2017-09-21 14:17:27 +0000 UTC debug: wait complete
      2017-09-21 14:17:27 +0000 UTC info: Mender state: fetch-install-retry-wait -> update-fetch
      2017-09-21 14:17:27 +0000 UTC debug: handle update fetch state
      2017-09-21 14:17:28 +0000 UTC info: Mender state: update-fetch -> update-install
      2017-09-21 14:17:28 +0000 UTC debug: handle update install state
      2017-09-21 14:17:28 +0000 UTC debug: Read data from device manifest file: device_type=firefly
      2017-09-21 14:17:28 +0000 UTC debug: Found needed line: device_type=firefly
      2017-09-21 14:17:28 +0000 UTC debug: Current manifest data: firefly
      2017-09-21 14:17:28 +0000 UTC debug: Trying to install update of size: 3145728000
      2017-09-21 14:17:28 +0000 UTC debug: Inactive partition: /dev/mmcblk1p2
      2017-09-21 14:17:28 +0000 UTC info: opening device /dev/mmcblk1p2 for writing
      2017-09-21 14:17:28 +0000 UTC info: partition /dev/mmcblk1p2 size: 4194304000
      2017-09-21 14:20:06 +0000 UTC debug: handle update status report state
      2017-09-21 14:20:06 +0000 UTC info: attempting to report data of deployment [8d1decee-81cd-4f15-8da6-a4de87fea6fd] to the backend; deployment status [failure], try 0
      2017-09-21 14:20:06 +0000 UTC debug: attempting to upload deployment logs for failed update
      2017-09-21 14:20:06 +0000 UTC info: attempting to report data of deployment [8d1decee-81cd-4f15-8da6-a4de87fea6fd] to the backend; deployment status [failure], try 0
      

      This happens because large updates with a lot of unused space contain a lot of null data. Since this compresses to virtually nothing, the connection is stuck on a certain download block for a very long time while the client writes all that data. Eventually the server terminates the connection, wrongfully assuming that the connection has stalled.

        Attachments

          Container Issues

            Activity

              People

              • Assignee:
                a10040 Kristian Amlie
                Reporter:
                a10040 Kristian Amlie
              • Votes:
                1 Vote for this issue
                Watchers:
                6 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Zendesk Support

                    Summary Panel