Import Export PA
- Published: Thursday, 24 May 2007
Normally in a Citrix Environment the most changed configuration part are the Published Application Settings. So also in this part the most mistakes can be made for example removing a complete Published Application, changing display settings or remove/adding the wrong server or users from a Published Applications.
Therefore you could document the settings via tools as described in the Glance at Free article CPS Farm Inventory, but you could also export those settings in such way you can import with a single command again in your farm.
This can be accomplished via MFCOM commands which are included in every Citrix Presentation Server (as described in the MFcom manual, but it is much easier to use one of the available tools. In this article I will describe some of the available tools.
This tool can be found on Thomas Koetzing website. It exists of one single executable that should be run on one of your Citrix Presentation Servers from the command line. The tools have three parameters available. The first one you should use is the parameter /EA. With this parameter all applications are exported. The tool creates one file per application with the PA configuration and one file with all the application settings included. In this way you could restore the settings of one application or if needed all applications of your farm. Importing the settings will be done via the parameter /IA followed by the file name of the application you would to restore (use the AllApps file to restore all applications).
The last parameter is /DA with specify the filename of the application. With this parameter you can remove the application from the Citrix datastore. The file still exist so you can add the application again with the /IA parameter.
Published Application Importer Exporter
The second tool is created by Haakon Flender. This utility exists of two file. One WFS script that is the basis of the tool and a HTM file which is used to "build" the graphical user interface. The tool can be used from the command line using parameters or via a GUI when starting the WFS script without parameters. When using the tool via the command line two parameters are available. With export (followed by a filename for saving the settings) all the applications are exported to one file. Using the import parameter the settings in the specified file are restored in the Citrix Datastore. There is no possibility to restore one single application. When you start the WFS without parameters a simple graphical interface is displayed. In this GUI you actually can specify the same options as via the command line, so exporting or importing the applications from/to which file.
Published Application Utility
The third utility is written by Dennis Smith of Gourami. The review is based on the beta product, but version 1.0 (with the same functionality) is just released. This is the only tool that is included with a small installation. Besides it requires .Net Framework 2.0 to function.
The tool is more than an import and export tool of Published Applications. First the utility will query the Citrix Datastore for the available Published Applications. These will be displayed in the tool. For exporting the applications you can select the applications followed by Save Applications from the Application Menu. Via the same menu you can load application setting into the tool. Within the tool you can change all kind of settings of the Published Applications. For example you can search and replace (parts of) the settings (application name, description, working directory and command line) by searching for a specific set of characters, load and save server name to republish the application on more or other servers or add/remove groups and users to/from the Published Applications. The tools displays that there are changed made to the Published Applications which are not available in the Datastore. For example you loaded the settings of an application that is not available anymore or changed some settings to the PA via the tool. With the option Save Changes in the File Menu the notified changes in the tool are imported in the Datastore.
Exporting your Published Applications in case of disaster or mistakes during daily operations is very good idea. In this article I described three tools which can accomplish this activity.
The Published Application Importer Exporter has command line and GUI possibilities. Unfortunate you can only export and import all the applications, there is no option to restore a single application.
The Published Application Utility looks really promising. The tool has a nice Graphical User Interface and besides the possibility to export and import Published Applications it can also be use to change setting to several Published Applications at once. The tool is still in beta and it is unclear if this tool will be available as freeware.
The PAT tool is easy to use from a command line with a few parameters. Because the tool creates a file per application as for all application you can restore one application or all applications. You can also delete applications from the Citrix Datastore with the tool, but I don't think that option will be used much. Because of some limitation in the other tools I think this tool is the most useful at this moment.