RRR|Patch - utility to help you manage and apply patches to your AR Server

Version 4
    Share This:


    I usually prefer to apply patches file by file, as opposed to running the server, mid-tier, etc installers.

    The reason is that the installer may "restore" things in the work-flow, such as changing the permissions on the User-form, or modifying a server setting in ar.cfg.

    The problem with the file-by-file method is that it requires a lot of manual downloading and copying of files. It is very hard to get it 100% right.

    The solution to this is rrrPatch.exe or rrrPatch.pl, depending on your preference.


    This tool has only been tested on a few version/platform-combinations of ITSM7 installs.
    Running the perl script should make this work fine for both unix and linux.
    If you need to specify user/passwd for your proxy, this does not work yet...

    Support and improvements:

    If you experience any problems or need help, please contact me directly at miz@rrr.se.
    If you have any suggestions, please let me know!


    Create a directory for your patches, and drop the executable/perl-script in there. For example C:\rrrPatch\.

    Download a patch for all operating system including the client installers:

    C:\rrrPatch> rrrPatch -m GET -p 7.1.0/patch008 -installers
    - creates a directory with all files under C:\rrrPatch\7.1.0\patch008\
    - ftps all the patch files to the directory

    Backup the server files before applying the server patch:

    (In this sample, I have mapped my server drive to Z:)
    C:\rrrPatch> rrrPatch -m BACKUP -p 7.1.0/patch008 -a "Z:\AR System" -o winnt -d ora
    - This will create a sub directory C:\rrrPatch\7.1.0\patch008\backup\
    - The files will be backed up ONCE only
    - Sample backup file C:\rrrPatch\7.1.0\patch008\backup\Z\AR Server\arapi71.dll
    - The system will backup each individual arapi71.dll it finds individually

    Applying a patch to your server:

    (In this sample, I have mapped my server drive to Z:)
    (I have also stopped all AR System related services)
    C:\rrrPatch> rrrPatch -m APPLY -p 7.1.0/patch008 -a "Z:\AR System" -o winnt -d ora
    - Applying the patch will backup any unbacked file before overwriting the file

    Restoring the backed up file if it did not work:

    (In this sample, I have mapped my server drive to Z:)
    (I have also stopped all AR System related services)
    C:\rrrPatch> rrrPatch -m RESTORE -p 7.1.0/patch008 -a "Z:\AR System" -o winnt -d ora
    - The backed up files will be restored to the original path

    Complete list of options:

    usage: rrrPatch -m { GET|BACKUP|APPLY|RESTORE } -p path [ -installers ]
    [ -a applydir1 [ -a applydir2 [ ... ]]]
    [ -o { winnt|aix|hpux|linux|solaris|hpia32|hpia64 } [ -o ... ]]
    [ -d { ora|mssql|db2|syb|inf } [ -d ... ]]
    [ -x match [ -x ... ]]
    [ -i match [ -i ... ]]
    [ -proxyhost host:port ]
    [ -ftphost host:port ] [ -ftpuser rpatches ] [ -ftppasswd Supp0rt89 ]
    [ -ftproot /smbu_patches/ars/ ]

    rrrPatch -ver

    This program is used to retrieve, and apply patches.

    -m GET
    The path can be, / (all versions and patch levelse) to a very specicic version/patch/directory/ combination.

    -m BACKUP
    The path must have a minimum path of /version/patch/ specified. The apply-dir(s) must also be specified. A backup-directory will be created under the name ./version/patch/backup/. The files will be stored in a structure that corresponds to the original place of the file.
    NOTE that each file will only be backed upp once, to make sure that you do not overwrite a previous backup.

    -m APPLY
    Any file with corresponding file name from the path will be replaced.

    -m RESTORE
    Will revert back to the backup directory.

    -p path
    Could be /version/patch/ or something more specific, for example /7.1.0/patch008/ or /7.1.0/patch008/server/winnt/.

    -installers includes the /installers/ directory when downloading

    -a path
    This option specifies where to apply the patch. The directories will be search for exact name-matches of the files in the patch. The files found will be put (once) in the backup directory.
    Note that you can specify more than one apply directory.

    -o os
    This parameter is used to limit download of a specific operating system.
    You can specify multiple -o arguments in GET mode.

    -d db
    This parameter is used to specify the server database vendor. This will be used to rename the correct server file from arservora => arserverd, srvora.exe => arserver.exe, etc.
    You can specify multiple -d arguments in GET mode.

    -x match
    This excludes files that match the case insensitive match-string. For example -x BOB will exclude all files and direcotries containing "bob". The default exclude files are TMP, TEMP, BACKUP, BAK, OLD and PATCH.

    -i match
    This overrides the default exclude match, and extra -x match specified. For example -i PATCH001 will still exclude directory "cmdb patch002" but will include "cmd patch001".
    The default exclude files are TMP, TEMP, BACKUP, BAK, OLD and PATCH.

    -proxyhost host:port
    This parameter can be used to specify a proxy server for ftp. The tool does not currently support proxy user/passwd settings.

    -ftphost host:port
    Overrides the default server epddownload.bmc.com.

    Overrides default login credentials.

    -ftproot /smbu_patches/ars/
    Overrides default start directory on the ftp-server.

    -ver prints version information

    The mode BACKUP will show you a list of files that will be applied. If you run APPLY without doing a BACKUP first, a backup will automatically be done. Note that BACKUP will only be done once per /version/patch/ and individual file.

    Copyright (c) 2009, Misi Mladoniczky, RRR AB, http://rrr.se