Skip past navigation linksSecure Global Desktop 4.40 Administration Guide > Printing > Configuring SGD Print Job Conversion

Configuring SGD Print Job Conversion

With SGD printing, print jobs are sent from an application server to an SGD server. The SGD server then sends the print job to the client, which sends it to the user's printer. When print jobs arrive at the SGD server, they might need to be converted to a format suitable for the client printer.

To decide whether a print job needs to be converted, the SGD server checks a printer type configuration file to see whether the format used by the client printer matches the format used by the application server. If the format matches, the print job is forwarded to the client device printer without any conversion. If the formats do not match, the SGD server converts the print job to the right format using the tta_print_converter script.

Print jobs from a Microsoft Windows 2000 or 2003 application session that uses the the Microsoft RDP Windows Protocol are never converted because they are assumed to be in the correct format.

Only use this page to resolve issues with the print job formats, for example where a print job is created as a postscript print job but the client printer is a PCL printer. In many cases, using Secure Global Desktop PDF printing provides a better solution to issues with print job formats.

To ensure that print jobs are formatted correctly, you might have to edit a printer type configuration file and the tta_print_converter script. This is described in the following sections.

Editing Printer Type Configuration Files

SGD uses the following configuration files to determine the printer type:

You can edit these files if you want to support particular printers, or to add new types of printer.

Note If you add a new printer type, you might also have to edit the tta_print_converter script.

If there is insufficient detail or inaccurate mappings in these files, SGD might convert print jobs unnecessarily or not at all.

Editing the Printer Configuration File for UNIX, Linux, and Mac OS X Platform Clients Devices

See Configuring Printing for UNIX, Linux, and Mac OS X Platform Client Devices for details of how to configure printers, including setting the printer type.

Editing the Printer Configuration File for Microsoft Windows Client Devices

For Microsoft Windows client devices, the printertypes.txt file maps printer drivers, for example, pscript.dll, to printer types, for example PostScript.

The printertypes.txt file includes comments to help you customize it. By default, the file includes mappings for PostScript, PCL and text-only printers. You must log on as superuser (root) to edit this file.

Note The printertypes.txt file used for Windows clients also contains entries for UNIX and Apple Macintosh. This is used only as a fallback. For UNIX or Linux platforms, it maps UNIX types to printer types. For Apple Macintosh, it maps printer names to printer types.

On Microsoft Windows systems, to find out the name of the printer driver used by a client device, print a test page and check the Driver Name field.

To add support for a new printer type, add lines following the same pattern. For example:

Skip past command syntax or program codeMyNewType=mydriver.drv

Example

Rusty Spanner's client device, cairo, runs Windows 2000 and its default printer is PCL. The printer driver in use is unidrv.dll.

The Windows 2000 section in printertypes.txt has the following:

Skip past command syntax or program code[Windows2000]
PostScript=pscript5.dll;pscript.dll
PCL=rasdd.dll
PostScript=*

As there is no specific match for unidrv.dll, the final entry applies: PostScript. This means that when Rusty prints, print jobs are incorrectly converted to PostScript before being sent to cairo.

To fix this, edit printertypes.txt as root to add a specific match for unidrv.dll:

Skip past command syntax or program codePCL=rasdd.dll;unidrv.dll

Now SGD correctly identifies the printer configured on cairo, and print jobs are converted to PCL for that client device.

Editing The tta_print_converter Script

The tta_print_converter script converts print jobs from the format used by the application server to the format required by the client device and is determined by the printer type. By default, the script recognizes PostScript and non-PostScript formats. The script uses Ghostscript, available separately, to convert print jobs from PostScript to PCL.

You can edit the tta_print_converter script to recognize and convert between different print job formats, or to add support for a new printer type.

The shell function GetDataType determines the print job format from the first 128 bytes of the print job. The data is URL-encoded: for example, the % character is encoded as %25.

The client printer type is passed to this script in upper case, for example POSTSCRIPT or MYNEWTYPE.

The tta_print_converter script can be found in the /opt/tarantella/bin/scripts directory and it includes comments to help you customize it.

If you experience problems printing to a PCL printer, the tta_print_converter script contains some code which has been commented out. You can use this code to see if this solves the problem.

Note You must log on as superuser (root) to edit the script.

Ghostscript

The tta_print_converter script uses Ghostscript to convert print jobs from PostScript to PCL. For best results, download and install the additional fonts.

When you install SGD, Secure Global Desktop Setup automatically detects Ghostscript if it is installed in one of the following locations:

If Ghostscript is installed elsewhere, you must run the prtinstall.en.sh script with the --gsbindir option to tell SGD where to find Ghostscript.

If more than one version of Ghostscript is installed, you must run the prtinstall.en.sh script with the --gsbindir option to tell SGD which version to use.

If Ghostscript is not installed, you must install it and then run the prtinstall.en.sh script.

Related Topics