Task sequence and OSD

0x80070057: The parameter is incorrect

A program or step got a value it could not use. In SCCM check the command line, the step settings and any variables that may be empty.

Hex code0x80070057
Decimal-2147024809
NameE_INVALIDARG
Logs to readsmsts.log, AppEnforce.log, execmgr.log

What 0x80070057 means

0x80070057 means "The parameter is incorrect". A program was called with a value it does not accept. The value may be empty, badly formed or out of range.

In SCCM you see it most often in smsts.log on a failed task sequence step. It can also show for an application in AppEnforce.log and in the console under Monitoring > Deployments.

Common causes

  • A task sequence variable used in a step is empty or has the wrong value.
  • A disk step targets a disk or partition that does not match the hardware.
  • The install command has a bad switch, a missing quote or a path with spaces and no quotes.
  • A script passes a wrong argument to a Windows tool or API.

How to fix 0x80070057

  1. Find the step and its values

    Open smsts.log and search for "Failed to run the action". Note the step name. Read the lines above it. The log prints the command line and the values the step used.

  2. Check variables used by the step

    Look for any variable in the step, written as %Name%. Find where it is set: on the collection, on the device or in an earlier step. An empty variable leaves a gap in the command line.

    Add a Run Command Line step before the failed step to write the variables to a file. Use cmd.exe /c set with output sent to a text file, then read the file.

  3. Check disk steps against the hardware

    If the failed step is Format and Partition Disk or Apply Operating System Image, check the disk number and the partition layout. Press F8 in Windows PE if command support is on in the boot image. Run diskpart, then list disk, to see what the machine has.

  4. Check the quoting in the command line

    For an application, open AppEnforce.log and copy the command line. Put quotes around any path with spaces. Check each switch against the vendor's install guide. Then test the command as SYSTEM on a test machine.

Commands that help

Write all environment values to a file from a Run Command Line step · Command Prompt
cmd.exe /c set > C:\Windows\Temp\ts-variables.txt
Got a different code?

Turn any hex or decimal error code into its meaning, or search every code on this site.

Error code lookup All SCCM error codes

✉

Get new articles in your inbox

SCCM guides, AI tools, automation tips — sent when published. No spam.