MYOB Acumatica PatchTool: General Information

This topic shows you how to use the PatchTool command-line utility to check for, apply, and roll back patches for your MYOB Acumatica application instance.

Attention:
  • Applying or rolling back a patch replaces files in the instance and restarts its website. Either lock out the system (see Upgrading of MYOB Acumatica: To Schedule the System Lockout) or make sure that all users know about the restart so that they can save their work.
  • PatchTool needs internet access to check for and download patches. If necessary, configure your firewall to allow this.
  • Run PatchTool with administrator privileges, as these are necessary to modify files in the MYOB Acumatica application instance folder.

Learning Objectives

In this chapter, you will learn how to do the following:

  • Correctly use PatchTool and its syntax
  • Check if new patches are available for your MYOB Acumatica application instance by using the utility
  • Use PatchTool to download and apply patches for your MYOB Acumatica application instance
  • Roll back a previously installed patch by using PatchTool

Applicable Scenario

You may want to use the PatchTool utility if you’re a system administrator responsible for keeping your MYOB Acumatica instance up to date.

Using PatchTool

The PatchTool command-line utility is an executable file named PatchTool.exe. By default, the file is located in the %Program Files%\MYOB Acumatica\Data\ folder on the computer with MYOB Acumatica installed.

Alternatively, you can download the utility from the MYOB website: https://update.acumatica.com/rest/api/patch/tool.

When you run PatchTool.exe, you specify:
  • An action name (check, patch, or rollback)
  • A set of command-line parameters, with each presented in the following format
    -parameter "parameter value"

When you pass a command-line command to PatchTool, use the following syntax.


PatchTool.exe check|patch|rollback
-p|--path "path to the instance folder"
[-z|--zip "path to the backup archive"] 
[-a|--archive "path to the local patch archive"]
Note:
  • Parameter values are case-sensitive and must be in quotation marks.
  • You can use each parameter’s short form or full name.
  • If you specify a parameter more than once, its last value will be used.

For details, see MYOB Acumatica PatchTool: Parameters and Values.

Checking for Patches

You can check if new patches are available for the MYOB Acumatica application instance by running the following command.

PatchTool.exe check 
--path "path to the instance folder"

PatchTool returns the following:

  • If it finds a patch: A new patch found: <VERSION> P<X>. VERSION is the version number of the MYOB Acumatica application instance, and X is the patch number.
  • If no patches are available: No patches are available for download.

Applying Patches

To download the patch from the MYOB website, create a .zip archive with backup files and apply the patch to the MYOB Acumatica application instance by using the following command.

PatchTool.exe patch 
--path "path to the instance folder" 
[--zip "path to the backup archive"]

If the machine where your MYOB Acumatica instance is installed doesn’t have internet access, contact the MYOB support team to get the patch as a .zip archive. Copy the patch archive to the machine where your MYOB Acumatica instance is installed locally and then use the following command.

PatchTool.exe patch 
--path "path to the instance folder" 
--archive "path to the local patch archive" 
[--zip "path to the backup archive"]

The -z|--zip parameter is optional. If you omit it, PatchTool creates a .zip archive with backup files in the default backup folder. The folder’s location (typically, %Program Files%\MYOB Acumatica\BackUp\Sites\<instance name>) is defined by the BackupFolder parameter of the instance's web.config file. In the folder’s name, <instance name> is the name of the application instance website.

PatchTool returns the following:

  • On successful application: The patch with the <VERSION> P<X> version has been applied. VERSION is the version number of the MYOB Acumatica application instance, and X is the patch number.
  • When no patches are available: No patches are available for download.

Uninstalling Patches

To roll back a patch and restore files from the backup archive, use the following command.

PatchTool.exe rollback 
--path "path to the instance folder"  
[--zip "path to the backup archive"]

The -z|--zip parameter is optional. If you omit it, PatchTool looks in the default backup folder.

PatchTool returns one of the following:
  • On successful rollback: Rollback completed.
  • When no patch had been applied: Nothing to roll back. The site has not been patched.