Carl Stalhood

Thursday 13 October 2011

Publish applications via citrix.

c:\Windows\explorer.exe /n,/e,::{20D04FE0-3AEA-1069-A2D8-08002B30309D}
for My computer

c:\Windows\explorer.exe /n P:\ for my documents,

My doc
C:\WINDOWS\explorer2.exe /e,::{450D8FBA-AD25-11D0-98A8-0800361B1103}

my computer
C:\WINDOWS\explorer2.exe /n ,::{20d04fe0-3aea-1069-a2d8-08002b30309d}

Publish an application with a command line of:

\IEXPLORE.EXE [–e |] (specify %windir% for the working directory).

Example:

“c:\Program Files\Internet Explorer\IEXPLORE.EXE" -e c:\

- Or -

“c:\Program Files\Internet Explorer\IEXPLORE.EXE" http://www.citrix.com

Friday 30 September 2011

A program on your computer has corrupted your default search provider settings for Internet Explorer.



Users are using IE through Citrix Presentation server 3.0

All users are affected.
-error stating that the internet search option is corrupted and once user clicks on OK then the “Manage Add –Ons “ window Pops up.
While we have done quite some investigations, we have found that uninstalling IE8 rolls this back to IE6. Further upgrade to IE7 and then onto IE8 resolves this issue. This has been tested on a test server and so far we haven’t seen issues when we have tried to open IE multiple times. We shall monitor this for a few days more and then raise a change to uninstall and further upgrade IE6 to IE8. This also requires a reboot of the server.

For single user issue on local desktop:-
There is one easier thing to try. It worked for me anyway.... (XP 32 bit, SP3)
1. Login to a different account on the machine
2. Unhide hidden files and folders and show protected operating system files
3. Browse to the desktop folder of the affected user
4. Delete 'Desktop.ini'
When you log back in, Windows will recreate it.
Good Luck.

Sunday 28 August 2011

What is TS server drain mode?

How to put a terminal server into drain mode?

There are two ways an administrator can put a terminal server into drain mode: 1) using the command-line tool chglogon.exe, or 2) using Terminal Services Configuration UI.
1. Command-line settings

The command-line tool chglogon.exe (or “change logon”) may be used to configure the drain mode. There are five options: /QUERY, /ENABLE, /DISABLE, /DRAIN, /DRAINUNTILRESTART, as shown in the following screen shot:



By default, all connections are allowed on a terminal server. To configure a server into drain mode, use the /DRAIN option.



To configure a server into drain mode temporarily, use the /DRAINUNTILRESTART option. After restart, user logons will automatically be re-enabled:



To take the server out of drain mode and restore connectivity, use the /ENABLE option:



The “chglogon /DISABLE” command has the same behavior as in Windows Server 2003 – no remote connections will be allowed, even if a user has an existing session.
2. Terminal Services Configuration UI

Terminal Services Configuration UI (Administrative Tools -> Terminal Services -> Terminal Services Configuration) is the other way to configure TS server drain settings:



The UI shows the current status of the drain mode. Double-clicking “Terminal Server Drain Mode” brings up another dialog box:



The three settings listed are defined as follows:
“Allow new user logons” – All remote connections are allowed
“Deny new user logons” – Terminal Server is in drain mode
“Deny new user logons until restart” – Terminal Server is in drain mode until the server is restarted

Update: The settings are changing slightly:
“Allow all connections” – All remote connections are allowed
“Allow reconnections, but prevent new logons” – Terminal Server is in drain mode
“Allow reconnections, but prevent new logons until the server is restarted” – Terminal Server is in drain mode until the server is restarted

Also, the above blog post is accurate for Longhorn Server Beta3. There is a minor change for RC1 in the TsConfig UI – now the drain mode is called "user logon mode"

The Logon User Interface DLL Ctxgina.dll failed to load. Contact your system administrator to replace the DLL, or restore the original DLL

Symptoms

When rebooting a MetaFrame Presentation (XenApp) Server, you receive the following error message:

"User Interface Failure. The Logon User Interface DLL Ctxgina.dll failed to load."

Causes

Potential causes of this error message include:
Corrupted or deleted *GINA.DLL,
Failed installation (or uninstallation) of Metaframe Presentation (XenApp) Server or its corresponding service packs, hotfix rollup packs, or hotfixes.
An install conflict with applications such as the Novell Client, PCAnywhere, or any key that modifies the HKLM\Software\Microsoft\WindowsNT\Current Version\Winlogon\GinaDLL value.
Incomplete or missing Path statements set in Environment Variables.

Wednesday 24 August 2011

Load e-valuator rules

Load throttling ?

This rule determines load based on how user logon operations affect server performance. If logon is an expensive operation, set this to High (default).

Context Switches ?


This rule allows your load evaluator to calculate a load based on the CPU context switches. A context switch occurs every time the operating system switches from one executing process to another.
When the CPU context switches are within the low and high thresholds, Load Manager reports a load percentage based on the threshold values.
When the CPU context switches exceed the high threshold, Load Manager reports full load.
When the CPU context switches are less than the low threshold, Load Manager reports no load.
The valid range for the high and low thresholds is 0 to 2147483647.

Page faults ?

This rule allows your load evaluator to calculate a load based on the number of page faults per second. A page fault occurs every time the operating system accesses physical memory that has been flushed to disk.
When the number of page faults per second is within the low and high thresholds, Load Manager reports a load percentage based on the threshold values.
When the number of page faults per second exceeds the high threshold, Load Manager reports full load.When the number of page faults per second is less than the low threshold, Load Manager reports no load.
The valid range for the high and low thresholds is 0 to 2147483647.

Scheduling ?

This rule schedules the availability of selected servers or published applications. This rule sets the weekly days and hours during which the server or published application is available to users and can be load managed. For example, you can use this rule to prevent access to sensitive data outside of regular business hours.
For each day of the week, you can specify a list of time intervals, during which Load Manager will report no load. During the other times of the day, Load Manager will report full load.
To view the list of time intervals for a day of the week, select the day from the Day of Week list. The list of time intervals appears under Times of Day. To add an interval to the list, click Add Interval. To remove an interval, select it and then click Remove Interval.
This rule should be used in conjunction with another rule because it will not balance connection load if used by itself.


Sunday 7 August 2011

About Citrix load balancing and prefrential load balancing

By default there are two type of load evaluators in Citrix Xenapp 5.0
1- Advanced
2- Default

Advanced : Available rules
CPU Utilization
Load throttling
Memory usage
Page swaps


This is used when, all servers are not with same configuration.Some are P3 or some p4.

This rule allows your load evaluator to calculate a load based on the number of users accessing a specific published application on the attached server.

When the number of users accessing the published application is less than or equal to the threshold value indicated here, Load Manager reports a load percentage based on the threshold value.

The valid range for this rule is 1 to 10000.

Default : Available rules
Load Throttling
Server user load

This is used when, all servers are same configuration.

This rule allows your load evaluator to calculate a load based on the number of users accessing a specific published application on the attached server.

When the number of users accessing the published application is less than or equal to the threshold value indicated here, Load Manager reports a load percentage based on the threshold value.

The valid range for this rule is 1 to 10000.

creating new load evaluators:
Load evaluator rules:
Application User Load
Context Switches
CPU Utilization
Disk Data I/O
Disk Operation
IP Range
Load Throttling
Memory Usage
Page Swaps
Scheduling
Server User Load



Apply load valuator for server :

Apply load valuator for application

Select application

select Load manage application

Select a server

Client Drive mapping

From Web interface for java client :
Open web-interface > Xenapp website>client deployment > Client for JAVA


2 - From Xenapp Advance Configuration :
Goto Policies> HDX Plug and Play > client Resources> Drives> Mapping >Enable



3 - C:\>TSCC.msc

check ICA client not RDP
Prpertied> client setting





4 - c:\>dsa.msc
user properties> Environment Tab > connect client drive at logon




Home drive mapping> user profile>Terminal service profile

Saturday 30 July 2011

Interview questions 5

How to Recreate the Local Host Cache?
If the IMA service does not start, the cause may be a corrupt LHC. Verify the data store is available before beginning this procedure. If the data store is not available, the IMA service fails to start until the data store is available.

Recreating the Local Host Cache after a minimum of SP1 has been installed

1. Stop the IMA service. This can be done via the command line, net stop imaservice or from services.
2. From the command line run: dsmaint recreatelhc which renames the existing LHC database, creates a new database and modifies the registry key HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\IMA\Runtime\PSRequired key to 1. Setting the value PSRequired to 1 forces the server to establish communication with the datastore in order to populate the Local Host Cache database. When the IMA service is restarted, the LHC is recreated with the current data from the data store.
3. Restart the IMA service. This can be done via the command line, net start imaservice, or from services.
Recreating the LHC database on servers that do not have a minimum of SP1 installed
1. Stop the IMA service, if it is started. This can be done via the command line, net stop imaservice, or from services.
2. Go to %ProgramFiles%\Citrix\Independent Management Architecture and rename the imalhc.mdb to imlhc.mdb.bak
3 Launch the ODBC Data Source Administrator:
• On Windows Server, choose Control Panel > Administrative Tools > Data Sources (ODBC).
4. Select the File DSN tab and browse to %ProgramFiles%\Citrix\Independent Management Architecture.
5. Select the imalhc.dsn file and click Configure.
6. In the Database area, click Create. The New Database dialog box appears.
7. In the Database Name box, type the name imalhc.mdb for the new local host cache database.
8. Click OK to create the database, and then click OK to close the ODBC Data Source Administrator.
9. Open regedt32 and navigate to the registry key: HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\IMA\RUNTIME and modify the value of PSRequired (REG_DWORD): 0x1
10. Restart the IMA service. This can be done via the command line, net start imaservice, or from services.

How to disable print drivers from automatically updating the DataStore?
When a new printer or printer driver was installed on a MetaFrame server, a substantial amount of traffic (in the order of 8 to 10MB per second) occurred between the IMA Service and the data store the IMA Service was using. This occurred because the IMA Service needed to update the Management Console for MetaFrame XP with the information about the new printer or printer driver, which caused the huge amount of network traffic.
To resolve this problem, navigate to the following registry key and change the value of fDisablePrinterWorkerThread to 1:
HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\IMAPrinter
Type: REG_DWORD
Value: fDisablePrinterWorkerThread = 1
After making this change to the registry, restart the IMA Service for the change to take effect.
When the registry switch is set to 1, the IMA Service does not automatically update printer or printer driver information to the Management Console. You need to update this information manually. To do this, click Printer Management in the left panel of the Management Console and then double-click Update Printer and Driver.
Note: Ensure the latest MfPrintSs.dll is installed on the server.

How do I disable the Citrix Management Console splash screen?
There are two ways to disable the Citrix Management Console splash screen:
• Add -nologo to the Ctxload.exe command line. For example, if you publish ctxload as a published application, edit the published application and add -nologo to the end of the command line.
• If you run the Citrix Management Console from the toolbar, open the Program Files\Citrix\Administration folder. Create a shortcut to ctxload. Open the properties of that shortcut and add -nologo to the end of the target box. Click OK. Add the shortcut to the toolbar.

What is licenses auto-activation?
License auto-activation is a benefit offered to customers purchasing MetaFrame XP product through an electronic licensing program with Citrix. License auto-activation removes the need to activate MetaFrame product licenses via the Citrix Activation System. With license auto-activation, MetaFrame XP product licenses purchased through an electronic licensing program are automatically activated when they are installed on the MetaFrame XP server.

How to install XenApp client in command prompt and apply policies?
Run the XenAppHosted.msi in command prompt
"c:\>msiexec /a xenapphosted.msi"
This will launch "Client Packager Installation". We can create a pre-configured client package with the answer file for the questions asked by the installer, so that we can have silent installation of the client in various systems in the environment.
There is another way to create client installation package.
Type the command "msiexec.exe /I path/XenAppHosted.msi [Options]"
To add Group Policy to manage the client we need to add the .ADM by Citrix to the existing Administrative Template of the Group Policy Management. This is available where Citrix Clients have been already installed. It is located in "c:\program files\Citrix\ICA Client\Configuration\icaclient.adm"
We can manage Citrix Client connectivity by the Windows Group Policy

How to change the Citrix XML Service Port on Metaframe Servers ?
Un-registering the XML Service
1. Open a Command Prompt window and run ‘ctxxmlss /u’ (This command will un-register the Citrix XML service and mark it for deletion)
2. Reboot the server
Registering the XML on a port other than sharing with IIS
1. Un-register the service using the instructions above.
2. Open a ‘Command Prompt’ window and run ctxxmlss /r[Port Number] (Notice that there is no space between the switch “/r” and the port number.
3. Reboot the server or open the service control manager and manually start the Citrix XML Service
Registering the XML Service to share the port with IIS on Windows Server 2003 running IIS 6.0
By default when installing IIS 6.0, the virtual Scripts Folder is not created
1. Un-register the service using the instructions above.
2. Navigate to the ‘\Inetpub’ folder and create a new folder with the name of ‘Scripts’
3. Open the IIS Manager MMC Snap-in
4. Right click on the ‘Default Web Site’ and select New | Virtual Directory…
5. Click Next
6. Under Alias: type the name ‘Scripts’ and click Next
7. Under Path: type C:\Inetpub\Scripts and click Next
8. Under Allow the following permissions: make sure that the following are selected
a. Read
b. Run Scripts (such as ASP)
c. Execute (such as ISAPI applications or CGI)
9. Click Next and click Finish
10. Right click on the Scripts virtual directory and go to Properties
11. Under the Virtual Directory tab make sure that the Execute Permissions: field is set to Scripts and Executables
12. Under the Directory Security tab click on Edit… under Authentication and Access Control and make sure that the Enable anonymous access check box is checked
13. Now copy the files ctxxmlss.txt, clm.dll, wpnbr.dll to the newly create Scripts folder under the Inetpub folder.

Note: The file ‘ctxxmlss.txt’ is located in the ‘Program Files\Citrix\System32’ folder and the files ‘clm.dll’ and 'wpnbr.dll' are located in the ‘%SYSTEMROOT%\System32’ folder
If Microsoft IIS is installed, the administrator of the MetaFrame XP installation is given the option to install the Citrix XML Service and share a port with IIS.
In fact, no separate XML service is running. IIS serves the XML data using an ISAPI filter named Wpnbr.dll located in the \Inetpub\Scripts folder. To remove the Citrix XML Service functionality from your MetaFrame server, simply rename or delete the Wpnbr.dll file.
Once the XML Service port is changed on the Metaframe Servers you will need to change NFuse or WI to point to the new port.

Interview questions 4

What are the commonly used Citrix commands ?


dsmaint config [/user:username] [/pwd:password] [/dsn:filename]
dsmaint backup destination_path
dsmaint failover direct_server
dsmaint compactdb [/ds] [/lhc]
dsmaint migrate [{ /srcdsn:dsn1 /srcuser:user1 /srcpwd:pwd1}] [{/dstdsn:dsn2 /dstuser:user2 /dstpwd:pwd2}]
dsmaint publishsqlds {/user:username /pwd:password}
dsmaint recover
dsmaint recreatelhc
dsmaint verifylhc
-----------------------------------------------------------------------------------------------------------------------------------
driveremap
driveremap /drive:M
driveremap /u
driveremap /noreboot
driveremap /IME
-----------------------------------------------------------------------------------------------------------------------------------
dscheck
dscheck [Options] [ /full | /clean]
[ Servers | Apps | Printers | Groups | MSLicense | Folders | Licenses ]
dscheck /full Servers [Options] Verify/Clean or Delete the server. May be left blank. Defaults to all servers.
/Clean - Modify the data store to correct the errors.
/DeleteAll - Delete the server entries from the data store.
/DeleteMF - Delete the MetaFrame Server entry from the data store.
/DeleteComSrv - Delete the Common Server entry from the data store.
dscheck /full Apps [Options]
< AppName> - Verify/Clean or Delete the application. May be left blank. Defaults to all applications.
/Clean - Modify the data store to correct the errors.
/ServerCheck - Verify that all applications are hosted by valid servers.
/DeleteMF - Delete the MetaFrame Application entry from the data store.
/DeleteComApp - Delete the Common Application entry from the data store.
dscheck /full Printers [Options]
/purge_replications - Removes all printer replications from the data store.
/purge_client_printers - Removes all Client Auto-Create printers pending deletion from the data store.
/purge_drivers - Removes all drivers that are not associated with any servers from the data store.
dscheck /full Groups [Options]
/Clean - Removes the group object. GroupName is the relative DN from the Context.
/Clean -Removes the group from the parent group.
Use the output of DSCHECK.exe GROUPS /verify" for both ParentGroupName and GroupName.
dscheck /full MSLicense [Options]
/purge_licenses - Removes all Microsoft Licenses from the data store.
/list - Lists all Microsoft Licenses in the data store.
dscheck /full Folders /clean - Collapse orphaned folders in the data store.
dscheck /full Licenses /clean - Removes all corrupt licenses from the data store.
-----------------------------------------------------------------------------------------------------------------------------------
altaddr
altaddr [/server:servername] [/set alternateaddress ] [/v]
altaddr [/server:servername] [/set adapteraddress alternateaddress] [/v]
altaddr [/server:servername] [/delete] [/v]
altaddr [/server:servername] [/delete adapteraddress] [/v]
-----------------------------------------------------------------------------------------------------------------------------------
query
query view information about server farms, processes, servers, ICA sessions and users
query farm shows the servername, protocol and ip address
query farm /app shows the published applications
query farm /disc shows the disconnected session data for the server farm
query farm /load displays server load information
query user displays the current connections
queryhr is used to display info about the member servers in the farm. Executing queryhr with no parameters lists all servers in the farm.
-----------------------------------------------------------------------------------------------------------------------------------
chfarm is used to change the farm membership of a Citrix server
icaport is used to query or change the TCP/IP port number used by the ICA protocol
imaport is used to change the IMA port used by the server
ctxxmlss is used to change the XML service port
enablelb is used to re-enable the server back to load balancing after it fails
twconfig confgure ICA display settings
auditlog is used to view the report of users logoff and logon activity. With auditlog /time we can get time the users spent in the servers

interview questions3

What is Printer terminology in Citrix?
An administrator can configure the following types of printers for use in an ICA session:
Client local printer
Network printer
Server Local printer
Client Printers: The definition of a client printer depends on the ICA Client platform. On DOS-based and WinCE client devices, a client printer is physically connected by a cable to a port on the client device. On 32-bit Windows platforms (Windows 9x, Windows NT, and Windows 2000), any printer that is set up in Windows (these printers appear in the Printers folder on the client device) is a client printer.
Network Printers: Printers that are connected to print servers and shared on a Windows network are referred to as network printers. In Windows network environments, users can set up a network printer on their computers if they have permission to connect to the print server. When a network printer is set up for use on an individual Windows computer, the printer is a client printer on the client device.
Local Printers: Printers that are connected directly to Citrix servers are local printers within a particular server farm. This definition includes a printer that is connected to the Citrix server that hosts a user’s ICA session, as well as printers that are connected to other Citrix servers in the same server farm. If a printer is connected to a Citrix server outside of a server farm (either the server is not a member of a server farm or is a member of a different server farm), the server farm considers the printer a network printer, not a local printer.

How to implement Policies in Citrix?
Presentation Server policies are created by adding policy rules. Policy rules are broken down into the following categories:
Bandwidth
Client Devices
Printing
Security
User Workspace
An administrator can apply policies by filtering:
Client IP address
Users and user groups
Client names
Servers
Access Control
Once a policy is created it has to be prioritized for effective functioning. Following options are available for prioritizing a policy
Make Highest priority
Increase Priority
Decrease Priority
Make Lowest Priority

Citrix Policies can be configured from XenApp Advanced Configuration Console
If there are any policies which conflicts to each other,the resultant applied policies are the one with higher priority
Policies Override
1. Citrix Policy
2. Group Policy
3. ICA Session Setting
4. User Object Setting

What is IMA?
Independent Management Architecture (IMA) provides the framework for server communications and is the management foundation for MetaFrame Presentation Server. IMA is a centralized management service comprised of a collection of core subsystems that define and control the execution of products in a server farm. IMA enables servers to be arbitrarily grouped into server farms that do not depend on the physical locations of the servers or whether the servers are on different network subnets.
IMA runs on all servers in the farm. IMA subsystems communicate through messages passed by the IMA Service through default TCP ports 2512 and 2513. The IMA Service starts automatically when a server is started. The IMA Service can be manually started or stopped through the operating system Services utility.
IMA can be defined as a SERVICE, PROTOCAL and as a DATASTORE.
IMA Service: IMA Service is the central nervous system of Presentation Servers. This service is responsible for just about everything server-related, including tracking users, sessions, applications, licenses, and server load.
IMA Data store: Which stores Presentation server configuration information, such as published applications, total licenses, load balancing configuration, security rights, Administrator Accounts, Printer configuration, etc?
IMA Protocol: Which is used for transferring the ever-changing background information between Presentation servers, including server load, current users and connections, and licenses in use.
Ports used by IMA:
2512: Used for Server to Server Communication
2513: Used for CMC to Data store Communication

“Independent Management Architecture” is a term Citrix uses to describe the various back-end components that make up a CPS environment. In the real world, IMA consists of three components that we actually care about.
It is a database (called the “IMA Data Store”) used for storing Citrix Presentation server configuration information, such as published applications, load balancing configuration, security rights, policies, printer configuration, etc.
A Windows service (called the “IMA Service”) that runs on every Presentation Server that handles things like server-to-server communication.
A protocol (called the “IMA Protocol”) for transferring the ever-changing background information between Presentation Servers, including server load, current users and connections, licenses in use, etc.
In Presentation Server, the IMA protocol does not replace the ICA protocol. The ICA protocol is still used for client-to-server user sessions. The IMA protocol is used for server-to-server communication in performing functions such as licensing and server load updates, all of which occur “behind the scenes.”
If we open IMA data store database with SQL Enterprise Manager, we'll see it has four tables:
DATATABLE
DELETETRACKER
INDEXTABLE
KEYTABLE
IMA data store is not a real relational database. It’s actually an LDAP database. IMA Data Store Size 1MB per server.
We can’t access the IMA data store directly through SQL Enterprise Manager. (technically you can, but if you run a query you’ll get meaningless hex results.) If we try to edit any of the contents of the data store directly in the database, it will be definitely corrupt.
There’s a tool on the Presentation Server installation CD called “dsview.” There is another tool called “dsedit” a “write-enabled” version of dsview.

What is USRLOGON.cmd?
Whenever a user logs on to the Citrix server, the USRLOGON.CMD file runs. This file is located in %systemroot%/system32. It is configured to run automatically when each user logs in.
This file has two functions:
1. USRLOGON.CMD creates the ROOTDRIVE variable. This variable is used by the Logon Script to identify the user's home directory.
2. USRLOGON.CMD calls USRLOGN2.CMD. USRLOGN2.CMD runs the application scripts that fix user level problems with certain applications

How to identify Citrix License been consumed by a Device?
LMSTAT command shows a Client Hardware ID, a license has been assigned to that device.
Lmstat is the license administration command shows what licenses are assigned to which client or server. This utility is run on a license server from a command prompt by browsing to \Program files\Citrix\Licensing\LS. The *.lic must be present in the \Program Files\Citrix\Licensing\MyFiles directory that excludes the built-in citrix_startup.lic file. Lmstat prints information that it receives from the license server but does not contact the product server.
Syntax
lmstat [-a] [-A] [-c “license_file”]
Open the command prompt and change the directory to \Program Files\Citrix\Licensing\LS
Type: lmstat –a
Example output of an lmstat -a command indicating two user machines accessing the farm and consuming two user license assignments.
A Client with Hardware ID that consumed a Citrix license is shown in hexadecimal number like below
Hardware ID for Session 1 6f78c1bd
Hardware ID for Session 2 3a7379f6

Interview questions 2

What is ICA and what is the advantage of ICA?
The Independent Computing Architecture (ICA) is the communication protocol by which servers and client devices exchange data in a server environment. ICA is optimized to enhance the delivery and performance of this exchange, even on low-bandwidth connections.
The ICA protocol transports an application’s screens from the server it is running on to the user’s client device, and returns the user’s input to the application on the server. As an application runs on a server, MetaFrame Presentation Server intercepts the application’s display data and uses the ICA protocol to send this data (on standard network protocols) to the client software running on the user’s client device.
When the user types on the keyboard or moves and clicks the mouse, the client software sends this data to the application on the server. ICA requires minimal client workstation capabilities and includes error detection and recovery, encryption, and data compression.
Citrix ICA protocol is used for remote application sessions between users and Presentation servers. The ICA protocol supports TCP/IP, NetBIOS, or IPX/SPX. Citrix ICA protocol is responsible for transmitting background information between the ICA clients and the Presentation servers, including the port mappings, drive mappings, print jobs, and sound. Only Sends Screen Updates & Mouse/Key Board Strokes. Only 30 – 35 kb/sec (Printing and File Transfer increase this) Fat Apps VS Thin Apps
Ports used by ICA:
1494: ICA Protocol on TCP (TCP + HTTP) & 1604: ICA Protocol on UDP.

Describe ZDC Election Process in detail?
Incase ZDC is not be available, another server in the zone can take over that role. The process of taking the role is called ZDC election. Server Administrators should choose the Zone Data Collector strategy carefully during the farm design itself. When an election needs to occur in a zone, the winner of the election is determined by
1. Highest version of Presentation Server first
2. Highest rank (as configured in the Management Console)
3. Highest Host ID number (Every server has a unique ID called Host ID).
When the existing data collector for Zone failed unexpectedly or the communication between a member server and the Zone Data Collector for its zone failed or the communication between data collectors failed, then the election process begins in the Zone. If the server is shutdown properly, it triggers the election process before it goes down. The servers in the zone recognize the data collector has gone down and starts the election process. Then the ZDC is elected and the member servers send all of their information to the new ZDC for the zone. In turn the new data collector replicates this information to all other data collectors in the farm.
Note: The data collector election process is not dependent on the data store. If the data collector goes down, sessions connected to other servers in the farm are unaffected .The data collector election process is triggered automatically without administrative interference. Existing as well as incoming users are not affected by the election process, as a new data collector is elected almost instantaneously.
C:\ QueryHR.exe
------ Showing Hosts for "10.22.44.0" ------
Host 1:
-----------------------------
Zone Name: 10.22.44.0
Host Name: TEDDYCTX02
Admin Port: 2513
IMA Port: 2512
Host ID: 4022
Master Ranking: 1
Master Version: 1
---------------------------------
------ Show Host Records Completed -------
To see the Host ID number and its version, run queryhr.exe utility (with no parameters).

Each server in the zone has a rank assigned to it. The administrator can configure such that the servers in a zone can be ranked to make the server as the most desired to serve as the zone master or ZDC. The ties between servers with the same administrative ranking are broken by using the HOST IDs assigned to the servers.
When a Presentation Server starts or when the IMA service starts, the IMA service starts trying to contact other servers via the IMA protocol on port 2512 until it finds one that’s online. When it finds, it queries it to find out which server is acting as the data collector. The winner of this Zone Data Collector election is determined by the newest version of the IMA service. We can control which server will act as data collector by keeping that server the most up-to-date.
Data Collection Election Priority
Whichever server has the most recent version of the IMA Service running. (This may include hotfixes) and the server with the highest preference set in the data store
Basically data collectors and data store are not really related. The data store holds permanent farm configuration information in a database, and the data collector tracks dynamic session information in its RAM.
In addition to their primary role to provide dynamic farm information for admin consoles or for incoming connection requests, data collectors also take part in the distribution of configuration changes to Presentation Servers in the farm. When we make a changes in a presentation server that change is written to the local host cache of whichever server we connected to, and then immediately replicated to the data store. Presentation Server only looks for changes in the central data store every 30 minutes. Whenever a change is made to the data store, that change is sent to the data collector for the zone.
The data collector then distributes that change (via IMA port 2512) to all of the servers in its zone, allowing each server to update its own local host cache accordingly. Furthermore, if we have more than one zone, the initial data collector contacts the data collectors in the other zones. It sends its change to them, and in turn those data collectors forward the change to all of the servers in their zones.
Coolest part is if the change is larger than 64k, the data collectors don't send the actual change out to its zone. Instead they send out a notification which causes the servers in the zone to perform an "on demand" sync with the central data store. However it's rare for a single change to be more than 64k in size.
The data collector election priority settings in the management console
Presentation Server Java Management Console > Right-click on farm name >Properties > Zones > highlight server > “Set Election Preference”
We can totally control which server is our data collector by manually setting the preferences in the Java console. We can manually configure four levels of Zone's Data Collector election preference options
Most Preferred
Preferred
Default Preferred
Not Preferred
The important thing to remember is that these preferences will be ignored if a newer server is up for election.

How Load Evaluator works?
QFARM /LOAD command executed in a Presentation Server farm will display all servers in the farm along with each server’s respective load value. Each and every Presentation Server generates its own “score” and sends this information to the data collector in the respective zone. This score will be a decimal number between 0 and 10,000, with zero representing a “no load” situation, and 10,000 indicating the particular server is fully loaded and is not accepting any more connections. Citrix Load Management is handled by load evaluator and its simply a set of rules that determine a particular server’s “score”, or current load value. It is the “score” that determine the decisions that distribute loads within the server farm. Load evaluators can be applied to servers and/or published applications. If any servers in the Zone go down then Load Evaluators are used to overcome the situation. In default XenApp installation there are Advanced and Default Load Evaluators are there.D
Default Load Evaluator includes only two rules, Load Throttling and Server User Load.
Advanced Load Evaluator includes four rules, CPU Utilization, Load Throttling, Memory Usual and Page Swaps.

How Zone Preference and failover configured?
Zone preference and failover can be configured from Policies. It is located in User Workspace > Connections in Citrix Policy. You can select the server group in which order the connections are preferred. This is useful when an entire zone goes down

What is Preferred Load Balancing?
Preferred Load balancing is the feature in XenApp Platinum edition, which allows you to configure preference for the particular users to access the applications in the XenApp farm.
We can see this in Server properties in Advanced Management Console. In Memory/CPU > CPU Utilization Management, there will be the third option called "CPU sharing based on Resource Allotments"
To give more resources to particular application in the server, we can configure in Application properties > Advanced > Limits and Application important in Access Management Console. So if you set the Application importance to High, then when those application is used by the users will get more CPU cycles than the users accessing other applications
To give more resources to the users, we can configure it in Citrix Policies in XenApp Advanced Configuration. To enable it go to the policy properties > Service Level > Session Importance > enable, and assign preferred Importance Level (High, Medium, Low).
Application Importance + Session Importance = Resource Allotmment.

What are the different Types of Citrix Load Evaluators?
There are two type of Load Evaluators - 1- Default -2- Advance

Below is the load evaluator rules-
1. CPU Utilization
2. Memory Utilization
3. Page Swap
4. Application User Load
5. Context Switches
6. Disk Data I/O
7. Disk Operations
8. IP Range
9. Page Faults
10. Scheduling
11. Server User Load

How to recover from IMA failing?
There are many reasons that the IMA Service doesn't start
1. IMA Service load time
2. IMA Service subsystem
3. Missing Temp directory
4. Print spooler service
5. ODBC configuration
6. Roaming Profile
Check the Windows Registry setting: HKEY_LOCAL_MACHINESOFTWARECitrixIMARuntimeCurrentlyLoadingPlugin
If there is no value specified in the CurrentlyLoadingPlugin portion of the above Windows Registry entry then the IMA Service could not connect to the data store or the local host cache is missing or corrupt.
If a CurrentlyLoadingPlugin value is specified the IMA Service made a connection to the data store and the value displayed is the name of the IMA Service subsystem that failed to load.
If administrators see an "IMA Service Failed" error message with an error code of 2147483649 when starting the Presentation Server the local system account might be missing a Temp directory which is required for the IMA Service to run.
Change the IMA Service startup account to the local administrator and restart the server. If the IMA Service is successful in starting under the local administrator account then it is likely that a missing Temp directory for the local system account is causing the problem.
If the Temp directory is not present then manually create one as >Temp. For example: C:\Windows\Temp
Also verify that the TMP and TEMP system environment variables point to the temporary directory. Restart the server to restart the IMA Service

What is Special Folder Redirection?
Special Folder Redirection (SFR) allows for the automatic redirection of server-side Special Folders to their client-side equivalents. When a user clicks on the Documents folder in their XenApp 5 session, the folder that opens will actually be the local Documents folder. When SFR is used, all file operations will take place in the client-side folder. SFR is only available when XenApp 5 is installed on Windows Server 2008 and also requires XenApp Plugin version 11 (client).

What is Citrix Resource Manager?
Citrix Resource Manager (RM) is a tool that is used to manage resources on single or multiple MetaFrame servers. RM enables the ability to collect, display, store, and analyze data about system performance, application or process use, and user activity. RM provides real-time system monitoring, reporting of system activity, and billing reports to charge users for use of resources using a summary database.
In XenApp5 Resource Manager is moved to EdgeSight. We cannot connect to RMSummaryreport database from XenApp5. But still we can see some of the reports from Report Center in Access Management Console. One of the important reports is Policy Report.

Interview questions 1

What are the default tests available in Health Monitoring & Recovery Tool?
XenApp Health Monitoring and Recovery Tool have the following default tests.
1. Citrix IMA Service test
2. Logon Monitor test
3. Terminal Service test
4. XML Service test
Health Monitoring & Recovery in the farm-wide configuration allows us to select the maximum percentage of servers that HMR can exclude from load balancing. The default value is 10% of server.

What is Hotfix Management and how to configure Server Restart Schedule?
Hotfix Management in Access Management Console allows us to check the Hotfixes installed in the particular server as well as compare the Hotfixes with the scope of server. But this tool will not automatically intimate or download available Hotfixes from the Citrix website. We can configure server restarting schedule for the servers in the XenApp farm. Right-Click the server and go to All Task.Go to Set restart options and Set restart schedule.

What is the session reliability service in Windows services?
Citrix XTE Server is the Windows service for session reliability.

What is Installation Manager?
Installation Manager will not be in the part of Citrix installation setup. It should be downloaded from the Citrix website and installed separately. We need to have PowerShell already installed in the server. Install the IM component in the workstation/system you want to manage from and the IM utility in the XenApp servers. After installing the we can access it through the Windows management console. We can select the shared msi file path from where the application to be deployed and the server and the time of installation. We can also schedule command-line task to install exe files or to run some commands or queries in the servers.

What is Configuration logging?
Administrative Configuration Logging is the new feature in XenApp 5.0 and it can be configured in farm-wide properties. We can store all the administrative changes in the farm. We can see the log from the Report Center. We can clear log from the farm properties. We can configure to have credential to clear the log.

How to configure SecureICA and SSL/TSL connection in XenApp?
To configure SecureICA, Go to Access Management Console and right click the application and go to the properties. In the Client option select the Encryption level. This should be configured both in client and server side. If we use XenApp client it will automatically select the Encryption type. If we use Program Neighbourhood we have to select the proper Encryption type in the client side. We can enforce these properties in the Group Policies or in Citrix policy in XenApp Advanced Configuration. We can Enable the SecureICA encryption and select the Encryption Level. If we enable SSL/TSL connection, we should have installed Citrix SSL Relay and Server Certificate installed in the server. We can configure this in Citrix SSL Relay Configuration Tool in Citrix Administration.

How to recover Citrix License Server?
The Citrix servers can function without contacting the license server and it is 30-days fault tolerant, and in Enterprise version an alert can be set with Resource Manager to send an email in case of License Server Connection Failure. If the license server reconnects at any time in the thirty days the problem resolves itself. If the server is not going to come back up, then the license file, digitally signed with the case-sensitive hostname of the old license server, is the critical component. The license file, a *.lic file, can be backed up to a thumb drive separately, and restored to a new server with the same name of the old license server, and the Citrix License server software installed.

What is "Citrix Startup License" in Citrix presentation server license management console?
The Startup license does not affect the license count. It is used to allow Citrix products to communicate with the license server using a continuous open connection. Every five minutes the license server and the products send a heartbeat message to each other to verify that they are mutually communicating.

How to restore the data source to the new server?
To restore the data store to a different server, or just to move it to a more convenient place on the network, the procedure is as follows:
1. Place the mf20.mdb that was backed up in the proper directory: C:\ProgramFiles\Citrix\Independent Management Architecture;
2. Create a file dsn to the new data store;
3. Run dsmaint config /user:user /pwd:password /dsn:path to dsn on the new data store server and restart IMA;
4. Run dsmaint failover newdatastoreservername on all the other servers in the farm and restart IMA
To create a dsn file, go to the control panel, administrative tools, of the Citrix server that holds the new data store, and go to “Data Sources (ODBC)”. On the tab marked “file dsn”, create a new file, with Access 4.0 drivers, that is in the same directory as the mdb file is, and can be named anything, but for convention should be mf20.dsn. on the final screen, the actual database that the dsn file is supposed to point to must be selected. Under the select button, highlight the proper database, (not the imalhc.mdb but the mf20.mdb) and close the utility.

What is CtxHide? How to solve CtxHide.exe Causing Citrix Session’s to Hang on Logon?
CtxHide.exe is responsible for hiding the DOS window in which UsrLogon.cmd is running.
Workarounds
1. Remove CtxHide.exe from the appsetup key in the registry
Use the registry editor to navigate to the following value:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\AppSetup
Double Click on the AppSetup value and remove the CtxHide.exe entry as the example shows below. Note that your AppSetup value may contain more than the following example.
Windows Registry Editor Version 6.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
"AppSetup"="CtxHide.exe UsrLogon.Cmd,cmstart.exe"
The result of removing CtxHide.exe is that users can see usrlogon.cmd running on logon.
2. Swap CtxHide.exe for Runh.exe
Runh.exe has been used to hide usrlogon.cmd script from the user experience prior to Metaframe Presentation Server 3.0. It performs the same function as CtxHide.exe. For more information on runh and to download the executable go to: http://thin.msterminalservices.org/runh.cfm.
Download runh.exe from the above link and place the runh.exe in the server’s system32 directory. In Windows registry navigate to the AppSetup key, remove CtxHide.exe and replace with runh. Runh will now call and hide usrlogon.cmd.
Windows Registry Editor Version 6.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon]
"AppSetup"="runh UsrLogon.Cmd,cmstart.exe"
To return to the original configuration navigate to the AppSetup value, remove runh and add CtxHide.exe.

Monday 18 July 2011

Unable to Launch Published Applications from XenApp 6

Symptoms

You are unable to open published applications from XenApp 6 and receive the following error messages:

“Cannot connect to the Citrix XenApp server.
The Citrix XenApp servers are reporting full load and cannot accept your connection at this time.
Try to connect again after a few minutes. If you continue to receive this message, contact your Citrlx administrator.”
“Unable to Launch your application, Contact your help desk with the
following information: Cannot connect to the Citrix XenApp server.”

“Protocol Driver error”
Cause

Several configuration options might prompt these errors.

Consider one of the following solutions below to resolve the errors:

Resolution 1

Check that the Web Interface XML configuration is set properly.
Open Citrix Web Interface Management.
Select XenApp Web Sites.
Click on Server Farms on the far right of the window pane.
Click on Edit:

a. Ensure that the correct XML broker(s) are listed under server.

b. Verify that the correct XML port is entered inside XML Service Port.
Resolution 2

Ensure that both RDP and ICA listeners are not set to a specific network adapter.
From the XenApp Server(s) open Administrative Tools.
Remote Desktop Services
Remote Desktop Session Host Configuration
Select RDP listener:
Right click go into properties and verify all network adapters are selected:
After verifying all Network Adapters are selected, review the ICA adapters (only applies to XenApp 6 / Windows 2008 R2 x64). Click on Start > All Programs > Citrix > Administrative Tools > ICA Listener Configuration.
Resolution 3

Ensure XenApp 6 policies are configured correctly.
Open the Citrix Delivery Services Console.
From the left pane, select Policies .
Select Computer from right pane and edit the unfiltered policy.
When the Identify your policy window opens, click Next.
Review your policies and enable the following settings:

a. License Server Host

b. License Server Port

c. XenApp Product Edition

d. XML Service Port
Save the Policy.
Run gpupdate /force from server command prompt.
Resolution 4

Ensure that you have registered the correct the port on the XenApp 6 server(s):
From the XML broker(s) (XenApp Server) open Services.msc. Ensure the Citrix XML service is started.
If the service is not started, you might need to register the correct XML port on the server and restart the service:
Resolution 5

Always clear Local Host Cache on all servers in farm to ensure a fresh copy of the datastore subset is applied to the XenApp and Zone Data Collectors.
Though IIS and XML can share the same port by default during an initial installation of XenApp 6, it is recommended as a best practice to assign a different port (for example: 8080) to XML

The "Cannot connect to the Citrix MetaFrame Server. Protocol driver error." Error Message is Displayed when Connecting to a MetaFrame Server

Symptoms

The following error messages that are displayed when connecting to a Citrix MetaFrame server:
If you enable Session Reliability, then the following error message is displayed:
Cannot connect to the Citrix MetaFrame Server. Protocol Driver error.
If you disable Session Reliability, then the following error message is displayed:
Cannot connect to the Citrix MetaFrame Server. The Citrix MetaFrame server you have selected is not accepting connections.
Note: The ICA-TCP and RDP-TCP listeners are enabled on the Citrix MetaFrame server. Additionally, the options to log on to the server are enabled.

You might also observe the following issues:
You are not able to connect to the port 1494, the Independent Computing Architecture (ICA) port, of the server by using the telnet utility.
You are not able to connect to the port 3389, the Remote Desktop Protocol (RDP) port, of the server by using the telnet utility.
When you run the NETSTAT -a command, the output of the command does not display that the server listening on port 1494.
When you run the NETSTAT -a command, the output of the command does not display that the server listening on port 3389.

Resolution

To resolve the issue, complete the following procedure:
Open the Systems Properties dialog box.
Activate the Remote tab.
Select the Allow users to connect remotely to your computer option, as shown in the following screen shot:
Note: You cannot make remote connections to the server, if you do not enable the Allow users to connect remotely to your computer option.

Error: Cannot connect to the Citrix server.

SYMPTOMS

A domain user, logged on to a Windows 2000 Professional Workstation, can browse for the list of applications and servers by a custom ICA connection. When the domain user tries to connect, the following error message appears:

Cannot connect the Citrix server.

If the domain user is added to the Power Users or the Administrators group, connection succeeds.

CAUSE

Applying the basic workstation policy provided by Windows 2000 Profesional, Basicwk.inf, prevents domain users access to the MSLicensing key in the workstation registry.

Domain users have insufficient rights to the HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\MSLicensing key in the workstation registry.

RESOLUTIONS

WARNING: Using Registry Editor incorrectly can cause serious problems that may require you to reinstall your operating system. Citrix cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk. Back up the registry before you edit it.

1. Run Regedt32 and give full control to the above MSLicensing key for domain users.

2. From the policy, enable the permissions for domain users to the MSLicensing key in the registry.

Cannot connect to Citrix XenApp server

We have used below steps of above article and got solution:-

Resolution




1. Verify that the Session Reliabilit​y port is reachable.​ This port is set in the Management​ Console by default as port 2598 and is configurab​le. Use the command line utility, Telnet /?.

2. Ensure that the port used by Session Reliabilit​y is not being shared by any other service, such as ICA, XML, IIS, or SQL. Use the command line utility, Netstat /?.

3. Ensure there are no Citrix Licensing issues or Product Code mismatches​.

4. Ensure the configurat​ion file, httpd.conf​, exists under the Citrix\XTE​\conf folder

5. Copy C:\Program​ Files\Citri​x\XTE\logs\x​te.pid from a good server. Note: When the XTE service is stopped, the XTE.pid file disappears​. If permission​s on the directory have been restricted​, then it is possible that the XTE service will not start as it cannot create the pid file. This file essentiall​y only holds the process ID of the XTE service.

6. Ensure the Citrix XTE service is started.

7. If the Citrix XTE service is started, Citrix may advise that the ICA listener be deleted, the system rebooted, and the listener recreated.

8. As a test, add the account for the XTE service from Network Service to Local System OR change the account for the service to Local System. Check permission​s on the C:\Program​ Files\Citri​x\XTE directory make sure that the Network service account has full rights

9. Users were unable to launch published applicatio​ns if the Session Reliabilit​y feature was enabled and an option other than All network adapters with this protocol was configured​ for the ICA protocol in the Citrix Connection​ Configurati​on utility.

This fix introduces​ support for session reliabilit​y even if you limit a protocol to a particular​ network adapter.

To enable this functional​ity:

a. Open the file httpd.conf​, located in the Program Files\Citr​ix\Xte\conf folder, in a text editor.

b. Below the line #Citrix_En​d, add the following line:

CgpSpecifi​edIcaLocalAd​dress

c. Save your changes.

d. Restart the server.

If you have this functional​ity enabled, assign a static IP to the server or, if you are using DHCP, create a script to automatica​lly update the IP address of CgpSpecifi​edIcaLocalAd​dress in the httpd.conf​ file. If the IP address of CgpSpecifi​edIcaLocalAd​dress does not match the actual IP address of the server, you receive an error stating that there is no route to the specified subnet address.

The remote sesssion was disconnected because there are no terminal server license servers available to provide a license

1. Go to Start->RUN->(Type) Regedit

2. Right Click on My computer-> Export->Save it on local disk.

3. Go to HKEY_Local_Machine->Software->Microsoft->MSLicensing.

4. Right Click on the folder(MSLicensing) and delete.

5. Restart the computer

Saturday 16 July 2011

Error: Protocol driver error ... When Launching Published Applications Through Access Gateway

Symptoms

Users receive the following error message when launching published applications through Citrix Access Gateway:

“Error: Protocol driver error”


Cause

Access Gateway is in Advanced Access Control mode using a legacy access center.

Applications are being launched from the Program Neighborhood Content Delivery Agent (CDA).

When using the Program Neighborhood CDA, the CitrixAuthService on the Advanced Access Control server acts as a secure ticket authority (STA) to issue and validate ticket requests.

Example of ticket issued:
Address=AS;P7XXQEFRFRYWOMC1VXSS;BB828B5B4D02E858403D3F09246A6C38

Once the ICA file is built and sent to the client, the Access Gateway has 15 seconds to validate the ticket against the STA server for a successful connection to occur. If the ticket verification takes longer than 15 seconds the connection is dropped and users see the generic “Protocol driver error” message.

Example of an Access Gateway log showing failure:
This line shows a request to nfuselaunch at 13:11:48:
(08/31/06 13:11:48): 2:server:aacd:: request: https://10.10.10.25:0/labs/cds/host.xps?category=&page=NfuseLaunch&cmd=refreshraw&action=launchica&cdaid=%7BA5DBC0E4-0F42-11D4-8FF1-0050DA2FEE7E%7D%7CNfuseLaunch&cdainstanceid=CDA67AE146092174F12ADCEE58024A68B82&method=SEAMLESS&appname=b7b713aa%2D13dd%2D4d39%2Dbfff%2D0ab8b4077a1b%2FRemote%20Desktop&enumstate=enumstate_cdabd951ee583ef49e68359ef36bab07c5e

This line shows a failed STA ticket check at 13:12:27:
(08/31/06 13:12:27): 2:server:cgp_proto: : failed STA ticket check!

This line shows the Common Gateway Protocol (CGP) connection being closed at 13:12:27:
(08/31/06 13:12:27): 2:server:cgp_proto: : closing CGP connection

Example of an Access Gateway log showing a successful launch:
This line shows a request to nfuselaunch @ 13:23:32:

(08/31/06 13:23:32): 2:server:aacd:: request: https://10.10.10.25:0/labs/cds/host.xps?category=&page=NfuseLaunch&cmd=refreshraw&action=launchica&cdaid=%7BA5DBC0E4-0F42-11D4-8FF1-0050DA2FEE7E%7D%7CNfuseLaunch&cdainstanceid=CDA67AE146092174F12ADCEE58024A68B82&method=SEAMLESS&appname=b7b713aa%2D13dd%2D4d39%2Dbfff%2D0ab8b4077a1b%2FRemote%20Desktop&enumstate=enumstate_cdabd951ee583ef49e68359ef36bab07c5e

This line shows a succeessful check at 13:23:36:
(08/31/06 13:23:36): 2:server:cgp_proto: user[cagtest]: CGP MPS tunnel succeeded

This line shows an application launched at 13:23:36:
(08/31/06 13:23:36): 2:server:cgp_proto: user[cagtest]: CGP Application launched [Remote Desktop]

Resolution


You must increase the time for the Access Gateway to verify the STA ticket using the following procedure:
Increase the ticket timeout value in the web.config file on the Advanced Access Control server. The path to the file is:

C:\Intepub\wwwroot\CitrixAuthService\Web.config
Find lines 104-106 in the web.config file. The default setting for the CGP ticket time is 15 seconds (shown below):




Increase the expiration time from 15 to 85 or to something a bit more suitable for your particular environment. For example:




Save the web.config file and restart the Advanced Access Control services using the service configuration.

This document applies to:
Advanced Access Control 4.2

Error: "1030 - Protocol Driver Error" Troubleshooting Steps and Suggestions

The 1030 Protocol Driver Error could be caused by a number of different things. Each step must be taken and verified true.

WARNING: Using Registry Editor incorrectly can cause serious problems that may require you to reinstall your operating system. Microsoft cannot guarantee that problems resulting from the incorrect use of Registry Editor can be solved. Use Registry Editor at your own risk. For information about how to edit the registry, view the "Changing Keys and Values" Help topic in Registry Editor (Regedit.exe) or the "Add and Delete Information in the Registry" and "Edit Registry Data" Help topics in Regedt32.exe. Note that you should back up the registry before you edit it. If you are running Windows NT, you should also update your Emergency Repair Disk (ERD).

First, look at the server's configuration:

1. Ensure the server has the latest Terminal Server or Windows 2000 Service Pack Level.

2. Ensure the Network Interface Card (NIC) has the latest driver installed.

3. For MetaFrame 1.8, enure to have Service Pack 2 installed.

4. Check the Event Viewer for any 1004 Terminal Server Licensing Errors.

5. Check that the subnet mask is consistent on every MetaFrame server in the farm.

On the client:

1. Ensure that you are using the latest client build. For updates to this, go to http://www.citrix.com/download. A listing of the latest clients and their respective build numbers are available there.

2. Ensure to use the latest IP stack for the client operating system.

--------------------------------------------------------------------------------------------

If all appropriate updates to the server and client are applied, try the following items:

1. Increase the idle winstation pool count in the registry. By default, Terminal Server creates two idle winstations. Increase this count by two and re-try. Edit the following registry key by using REGEDT32:

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Terminal Server
IdleWinStationPoolCount.

NOTE: Each idle winstation will take up 1 MB RAM. Take this into consideration when adjusting this count.

2. Adjust or remove any TCP KeepAlive settings that may have been added. For this functionality to be added, MetaFrame 1.8 Service Pack 1or higher is required. Refer to Citrix Document: CTX708444

--------------------------------------------------------------------------------------------

If connecting over a WAN or Internet connection, ensure that the following ports are opened:

• Port 1494 for TCP/IP is opened.

• Port 1604 for UDP is open Inbound on the firewall.

• Port 1023 and above (The High Ports) are opened for TCP and UDP outbound.

If using Network Address Translation, refer to the Solutions Knowledgebase Article "ICA Browsing With Firewall Address Translation (NAT)".

In some instances (depending on Firewall manufacturer) all connections through the Firewall may be reset when a rule is added to the Firewall. This has been verified to occur on Checkpoint Firewalls.

--------------------------------------------------------------------------------------------


If users are receiving this error when attempting to authenticate to a Server Farm, make sure that the Program Neighborhood Service is started. If this is confirmed, the load level of the Server Farm(s)
could be an issue. The following Solutions Knowledgebase Documents should assist you with troubleshooting this:

• Application Load Levels Defined: 10000, 10000!, 10001, 10002, 9999

• Additional Information on Qserver /App Load Factor 10002

If none of the above items resolve the issue, there may be an issue with the ICA Master Browser. Check and see if the ICA Master Browser Service is started on the server that you are trying to connect to.
If the service is started, and you have multiple Citrix servers in your environment, configure a different Citrix server to become the ICA Master Browser by default. Then, force an election. Once the new
server is registered as the ICA Master Browser, try the connection again.
-------------------------------------------------------------------------------------------

Special Considerations when Connecting to an Application with Citrix A.L.E.


If you receive an Error 1030: Protocol Driver Error when connecting to a web published application, try a connection with the full version of the ICA Client for Win32. Create a Custom ICA Connection to
the published application and attempt the connection. If this is not successful, follow the instructions previously noted. If this type of connection works, then the contents of the ICA File need to be
reviewed. For more information refer to the Solutions Knowledgebase Article "Checklist for Connecting to a Citrix Server by ICA Link on Web Page". Look for a section titled "The ICA File".

If you are running the ICA Client to connect to a Windows 2000 Server, you are required to have one of each of the following licenses:

• Microsoft Client Access License.

• Terminal Services Client Access License.

If you do not have a sufficient number of these licenses installed onto your server, you will not be able to connect to the Windows 2000/MetaFrame 1.8 server.

Customer's using Windows 9x may get the 1030 protocol driver error while Windows 2000 based clients do not.

In order to connect to Windows 2000/MetaFrame 1.8, use client version 4.21.779 or higher on Windows 32-bit workstations. With the release of this client, the connection checks for available Microsoft Licenses (both regular CAL and Terminal Services CAL (if not connecting from a Windows 2000 Professional based client) before a connection is established. If the connection fails, then check the Microsoft product License manager to see if you are complying with this licensing scheme.

Also, be sure that your Windows 2000 Terminal Licenses are activated! If they are not activated, you will see the 1030 error.

For more detailed information, refer to the Microsoft White Paper "MS Windows 2000 Terminal Services Licensing"

Troubleshooting and Explaining the Citrix Universal Print Driver

This article explains the Citrix Universal Print Driver and provides troubleshooting help.

The Citrix Universal Printer, originated in Presentation Server 4.0. Refer to the following:

CTX107059 – Advanced Concepts Guide for Presentation Server 4.0, pages 243-250

CTX106812 – The Citrix Universal Printer Explained

The PCL5c UPD driver, originated in MetaFrame XP, Feature Release 3, is based on the HP Color LaserJet 4500, is 600 dpi, and supports color.

The PCL4 universal driver, originated in MetaFrame XP, Feature Release 2, is the native Windows HP LaserJet Series II driver, monochrome, and 300 dpi.

Naming
Q: Is it possible to change the name of the Universal Print Driver (UPD)?
For example:
From “HP Color Laser Jet 4500 (MetaFrame PCL5c Universal Driver)” to just “MetaFrame PCL5c Universal Driver” for demonstration purposes.

Changes to the Registry Value: DriverAlias under HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\UniversalPrintDrivers\”Type of Driver” have no effect.


A: The part in parentheses is strictly an annotation we add to help administrators to identify the UPDs from all of the other Windows printer drivers. This is not actually part of the name.

So the actual name of the driver is “HP Color LaserJet 4500.” This driver is a stock Windows printer driver that comes with Windows by default.


The universal drivers are installed and treated like any other Windows print driver. MetaFrame XP Feature Release 3 changes the driver list in the Management Console so the universal drivers have a special icon and tag line.

Altering the Default Driver for the UPD

The key


HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\UniversalPrintDrivers\
Value:DriverList
Data of Type REG_SZ: EMF(Presentation Server 4.0 and 4.5) PCL4;PS;PCL5c.

Example: In MetaFrame XP Feature Release 3, if you remove PCL5c, the printer is mapped as PCL4. Certain MetaFrame version can toggle this functionality by altering the Feature Release level.

Notes:

If EMF is removed, restart the Citrix Print Manager Service. A customer was publishing the RDP Client from the Presentation Server 4.5 and then connecting to both Citrix and non-Citrix Terminal Servers. The printers in the second hop were not creating.

The creation of the UPD requires that the appropriate feature release is set and the server is obtaining the corresponding feature release license. If these conditions are not in place, an attempt to manually map the UPD printer as outlined in CTX681954 - Troubleshooting Citrix ICA Printer Autocreation will not show the UPD printer as an option.

Note: Native printers will map.

If you leave only PS, no printer is mapped. The “PS” universal driver is intended for use with UNIX Clients, where Postscript is the default printer control language.

You do not need a PCL-compatible printer/driver to take advantage of the PCL5c or PCL4 universal printing feature. The PCL interpreter, Pcl4rast.dll, is built into the Win32 and Macintosh Clients (version 6.20 or later). The PCL print streams generated by these server-side drivers are interpreted by our client software, VDSPL30N.dll, and rendered locally on the client utilizing the printer drivers and operating system of the client device. To summarize, all the PCL UPDs need a working printer/driver on the client device. Local printers or clients that are unable to support the basic features of the UPD drivers functionality may not print correctly.

Presentation Server 4.0 and 4.5 uses a client-side EMF metafile handler, EMFRENDR.dll, and a client-side EMF interpreter, VDSPL30N.dll. These features are available in the ICA Client for Windows version 9.0 and later. The EMF handler captures the data of the inbound spool file into the user’s temp directory and launches CPVIEWER.exe (responsible to interpret the EMF spool files by playing back each record) to preview and print this file.

Known Issues / Limitations

Issues related to the native PCL5c Windows driver that MetaFrame XP uses, may cause minor corruptions in a limited subset of documents when printed through UPD. However, the version that ships with Windows Server 2003 seems to have fewer problems. Therefore, it is advisable to have the customer upgrade their Windows 2000 server driver with the version that ships with Windows Server 2003.

CTX105353 - Universal Print Driver Output Is Faded and Illegible
CTX102574 - UPD, Universal Print Driver Client, Fixes in the 8.0 Win32 ICA Client
CTX107069 - SAP Frontend Printing Fails When Running SAPGUI for Windows on Presentation Server 4.0
CTX102919 - Wfica32.exe � Program Error may Occur when Printing from the ICA Version 7.100 Client using Universal Print Driver PCL:4
CTX488760 - Event ID 1106, Client Printer Autocreation Failed
CTX113551 - Color PDF Files Print in Black and White When Using the Universal Print Driver
CTX115464 - Print Field Commands Not Printed with Universal Printer Driver
CTX115553 – Presentation Server Client 10.x Introduces a New Method for Printing Documents From the Advanced Universal Print Driver
CTX115762 – Controlling Which Universal Printer Driver Gets Loaded on a Citrix Presentation Server 4.5 64-bit Server
CTX109196 – Mirrored/Inverted Print Jobs Appear when Printing from Presentation Server 4.0
CTX114287 – How to Enable Preview on a Client as the Default for Citrix Universal Autocreated Client Printers
CTX114755 – CPVIEWER Consumes Memory and Freezes the Local Workstation When Using the Universal Print Driver
CTX109149 – Error: The spool data received does no appear to be a Windows Server EMF spool file. ... No Printouts Appear When Using EMF Printing
CTX118131 – Current Known Issues about Garbled Printing with EMF-based Citrix Universal Printer.

CTX118554 – XenApp 5.0 Univeral Print Driver Defaults to EMF Printing in Windows 2008

The UPD Fails to Install

A few possible reasons are as follows:

1. The spooler was stopped/hung during the install.

2. The spooler service is set other than “local system” or account that is installing MetaFrame XP.

3. Console Error, Digital Signature Not Found. This is unusual because the HP LaserJet Series II driver is signed. A policy that disallows the addition of print drivers may be configured

4. There is a possible sequence in the upgrade path in MetaFrame XP.

CTX105821 - Error: Printer rundll command failed.

CTX105860 - How to Re-install the MetaFrame PCL5c Universal Driver

Print Jobs Appear to have an Increased Size when using the UPD with MetaFrame XP and MetaFrame Presentation Server 3.0

Autocreated/universal print driver (UPD) printers have a smaller print job size on a MetaFrame server, which is in PCL4/5c format. The PCL4/5c format is suitable for network transmission because of its small payload. However, when the print job reaches the client, the print job is rasterized, thus creating a larger print job. In the case of Hewlett-Packard and other native printer drivers, the print job created on the MetaFrame server is usually in EMF format but is converted to a native printer format on the client. Depending upon the efficiency and architecture of the native printer driver, the size of the EMF print job may be larger than the native format and vice versa.

When using UPD, the following steps occur:

1. The job is created in PCL format on the server by the universal print driver.

2. Data is sent to the client within an ICA virtual channel.

3. PCL data is converted into a bitmap on the client.

4. The bitmap is spooled on the local printer.

The result is that the bitmap image of PCL data in the client printer spooler is larger then the PCL data sent across the network to the client. This permits optimizing the bandwidth that is available between the client and server, but printing the job with the UPD could be slower when the print job reaches the client. The UPD is best suited for print driver management, bandwidth utilization, and autocreating client printers but does not support special printing features such as double-sided printing.

Printer Will not Autocreate Using the Universal Print Driver

1. Does removing any third-party printer drivers resolve the issue?

2. If a known server is “working” and one is “broken,” attempt to replicate/import the UPD from the working server to the non-working server.

3. Is the server licensed and the appropriate feature release level set correctly?

4. Ensure the UPD is installed and no policies are preventing the installation of printer drivers.

5. Ensure the Version 7.0 client or latter is being used for the MetaFrame Feature Release 3 UPD and that the Pcl4rast.dll is present on the client machine.

6. Ensure the Version 9.0 client or greater is being used for the MetaFrame Feature Release 3 UPD and that the EMFRENDR.dll is present on the client machine.

7. CTX111308 – Session Printers Assigned Through a Policy Are Not Using the Citrix Universal Print Driver

Setting the UPD for All, Except a Few Printers (MetaFrame XP Feature Release 3)

This is addressed in CTX105385 - Error: Client autocreation printer failure - Print driver not allow based on compatibility list and Event ID 1104

Alternate Method:

1. Select Use Universal Driver only if Native Driver is Unavailable in the Management Console.

2. Clear the following box:


3. For printer drivers that are never to be used, add the names of any of these drivers to this list:

4. Restrict users from adding drivers:

Q262202
Q239536
Q180545
Q259574
Q234270

Troubleshooting UPD Printing Within Applications

1. Connect a printer locally to the MetaFrame server and select the HP LaserJet Series II or current UPD alias driver in the Add Printer wizard.

2. If you cannot connect this printer to the server, browse and connect to a shared network printer and modify the driver on the Advanced tab of the Explorer’s printer properties dialog box.

3.
Create an alias UPD printer and set the port as FILE, run the application, and print to the alias UPD printer.

4. Verify how the application behaves when executed on the console with the same driver that is used by the UPD.

5. Do any other similar print outputs in other applications experience the same behavior as the UPD?

6. Do print jobs from the applications experience any issues when mapped to the same driver as the client device?

7. When printing certain forms using the universal print driver, the page does not print as displayed?

8.
When printing using Version 2.0 of the universal printer driver with custom in-house fonts, the print job renders an incomplete print, especially when using large font sizes. This fix offers a workaround by allowing you to disable print optimization in the printer settings. To do this, you must set the following registry key:

HKEY_LOCAL_MACHINE\Software\Citrix\UniversalPrintDrivers\PCL5c
Name: DisablePrintOptimizations
Type:REG_DWORD
Data=1

[From MPSE300R05W2K3006][#128201]
Cause
The application is directly inserting PCL of its own origin into the print stream using the form overlay capability of the PCL language. The PCL form overlay feature can be accessed through an escape function provided by most PCL5 printer drivers, the 4500 driver included. It basically allows an application to insert arbitrary PCL directly into the print data stream.

Resolution

Configure the application to use strictly GDI rendering instead of PCL EscapePassThrough or the standard device driver’s instead of the universal print driver.

Can the UPD Margin Settings Be Changed?
The margins presented by the new universal driver, HP Color LaserJet 4500, are different. However, the bitmap-to-page registration algorithm is unchanged. Because MetaFrame XP Feature Release 2 uses the HP LaserJet Series II driver, the nonprintable region of a Series II printer is ¼-inch on each side of the page.

Citrix uses the UPD as a proxy driver on the server and the non-printable region of the client printer is most likely going to be different. Therefore, the real nonprintable area of the printer may be larger than that of the universal driver. A print job where the application places data on the page near the printable limit of the UPD may drop out on the printed page because it falls outside the printable limit of the underlying client printer.