Upgrading ESXi host to 7.x fails with error "invalid magic\ntar: short read\n'" while extracting to locker partition
search cancel

Upgrading ESXi host to 7.x fails with error "invalid magic\ntar: short read\n'" while extracting to locker partition

book

Article ID: 318883

calendar_today

Updated On: 02-07-2025

Products

VMware vSphere ESXi

Issue/Introduction

Symptoms:
  • Upgrading ESXi hosts to any version prior to ESXi 7.0 Update 3c fails
  • This issue can occur during all types of upgrades
  1. Using esxcli to do a upgrade/install
  2. Lifecycle manager upgrade - using baselines.
  3. Lifecycle manager upgrade - using a single image for the cluster.
  • On the ESXi host, /var/run/log/esxupdate.log contains entries similar to:
--> esximage.Errors.InstallationError: Error untarring to /locker/packages/, return code: 1
--> stdout: b''
--> stderr: b'tar: invalid magic\ntar: short read\n'
  • On the vCenter Server, /var/log/vmware/vmware-updatemgr/vum-server/hostUpgrade/vua-<ESXi_hostname>.log contains entries similar to:
--> esximage.Errors.InstallationError: Error untarring to /locker/packages/, return code: 1
--> stdout: b''
--> stderr: b'tar: invalid magic\ntar: short read\n'
  • when upgrading using esxcli command, errors are triggered such as:
[InstallationError]
Error untarring to /locker/packages/, return code: 1
stdout: b''
stderr: b'tar: invalid magic\ntar: short read\n'
cause = Error untarring to /locker/packages/, return code: 1
stdout: b''
stderr: b'tar: invalid magic\ntar: short read\n'
vibs = ['VMware_locker_tools-light_11.2.6.17901274-18295176']


Note: The preceding log excerpts are only examples. Date, time, and environmental variables may vary depending on the environment.

Environment

VMware vSphere ESXi 7.0.0
VMware vSphere ESXi 7.0.2
VMware vSphere ESXi 6.5
VMware vSphere ESXi 7.0.1
VMware vSphere ESXi 6.7

Cause

  • This issue occurs when the installer fails to load json file in the locker partition
  • This issue is seen randomly on some ESXi hosts which had several prior upgrades

Resolution

This issue is resolved in ESXi 7.0 Update 3c build 19193900 . To obtain a patch file:

  1. Login to support.broadcom.com.
  2. Click "My Downloads".
  3. On the second page of products, click "VMware vSphere".
  4. Click "VMware vSphere - Enterprise Plus", then "8.0".
  5. On the "VMware vSphere Hypervisor (ESXi)" row, click "View Group".
  6. Click the dropdown menu above "Expand All", and select "7.0U3c".


Workaround:
To workaround this issue while upgrading ESXi hosts to versions prior to ESXi 7.0 Update 3c, perform the below steps:
 

1. Connect to the ESXi host via SSH
2. Delete the payloadFileMapping.json from the locker partition using the following command

rm -f /scratch/locker/packages/payloadFileMapping.json

3. Re-try the install/upgrade