When ESXi boots, the system tries to find a suitable partition on a local disk to create a scratch partition. If you install ESXi on SD/USB media you will see the below error.
When the location for system logs is not configured, your system uses the scratch partition by default. When you install ESXi using SD/USB media the scratch location is set to non-persistent storage, such as /tmp.
Scratch space can be manually configured for an ESXi host using the vSphere Client, vCLI or PowerCLI. Changing the configured scratch location requires a reboot of the ESXi host for the changes to take effect.
Configuring a persistent scratch location using the vSphere Client :
To configure persistent scratch space for ESXi using the vSphere Client:
- Connect to vCenter Server or the ESXi host using the vSphere Client.
- Click the ESXi host in the inventory.
- Under the Configuration tab, click Storage.
- Right-click a datastore and click Browse.
- Create a uniquely-named directory for this ESXi host (for example, .locker-ESXHostname).
- Click Advanced Settings under Software.
- Select the ScratchConfig section.
- Change the ScratchConfig.ConfiguredScratchLocation configuration option, specifying the full path to the directory. For example: /vmfs/volumes/DatastoreUUID/.locker-ESXHostname
- Click OK.
- Put the ESXi host into maintenance mode and reboot for the configuration change to take effect.
You can find more information on below KB articles: