Friday, December 14, 2012

WMI error retrieving object MetaFrame_DisconnectedSession_Happening: Received error: 0x80041002: Not found

In Eventvwr under Application Log  WSH


Citrix Monitoring Script Event 2
Citrix MetaFrame Compute Event Rate:
WMI error retrieving object MetaFrame_DisconnectedSession_Happening:
Received error: 0x80041002: Not found 

Event Type: Error
Event Source: WSH
Event Category: None
Event ID: 1 
 Description:
Citrix Monitoring Script Event 2
Citrix MetaFrame Compute Event Rate:
WMI error retrieving object MetaFrame_DisconnectedSession_Happening:
Received error: 0x80041002: Not found 


SOLUTION:

Recompile the complete WMI repositories and then run the following commands for recreating these files.
  • Recompile Microsoft Windows .MOF files:
  • net stop winmgmtc: cd %systemroot%\system32\wbem rd /S /Q repository
    regsvr32 /s %systemroot%\system32\scecli.dll regsvr32 /s %systemroot%\system32\userenv.dll
    mofcomp cimwin32.mof mofcomp cimwin32.mfl mofcomp rsop.mof mofcomp rsop.mfl for /f %s in ('dir /b /s *.dll') do regsvr32 /s %s for /f %s in ('dir /b *.mof') do mofcomp %s for /f %s in ('dir /b *.mfl') do mofcomp %s 


  • Recompile Citrix .MOF files:
  • cd %programfiles%\citrix\system32\citrix\wmi for /f %s in ('dir /b *.mof *.mfl') do mofcomp %snet start winmgmt

    Sunday, December 9, 2012

    Windows cannot open Help and Support because a system Service is not running

    Windows cannot open Help and Support because a system Service is not running 



    Windows cannot open Help and Support because a system Service is not running


    We have seen a rash of these problems on Windows Server 2003. Research seems to indicate the problem is related to the installation of Windows Server 2003 Service Pack 2 (SP2).
    The simplest fix we have found is this:
    • Open a Command Prompt
    • Run the following commands
      • %SystemDrive%
      • CD %windir%\PCHealth\HelpCtr\Binaries
      • start /w helpsvc /svchost netsvcs /regserver /install
    The service should install and start automatically.


    The Citrix XML Service service on Local computer started and then stopped


    CITRIX XML SERVICE :

    If you ever do any research on what port to use for the XML service in a Citrix XenApp environment, you’ll notice that there are options to share port 80 with IIS, use port 443 with SSL on IIS and finally port 8080.  I haven’t really found any official documentation on what is best practice but I was able to find forum posts where Citrix engineers recommend the use of port 8080 and not to rely on IIS.
    The process of changing the XML service port to 8080 is quite easy but since I know I’m bound to forget after not having to perform the configuration on a regular basis, I thought it would be good to write a blog post so I can reference it in the future.
    Begin by logging onto your XenApp server and stop the Citrix XML Service:
    clip_image002
    image
    Once the service has been stopped, proceed with opening up the command prompt as an administrator an executing the following command to unregister the Citrix XML Service port:
    ctxxmlss /u
    image
    Once the command completes successfully, proceed with executing the following command to register the port to 8080:
    ctxxmlss /r8080
    image
    Once the command successfully completes, proceed with starting the Citrix XML Service:
    clip_image002[6]
    … then open up the registry to confirm that the changes have been applied via the following registry key:
    Computer\HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\CtxHttp
    Name: TcpPort
    Type: REG_DWORD
    Data: 0x00001f90 (8080)
    clip_image002[4]
    Once the port change has been confirmed, log onto your Web Interface server and reconfigure the farm settings for your websites:
    image

    Wednesday, December 5, 2012

    Troubleshooting ICA Client / PNAgent Error 2306


    Program Neighbourhood Agent / PNAgent Error 2306
    On setting up the ICA Client 10.105 I received the following error on trying to connect via the applications listed under the PNAgent.', 'On setting up the ICA Client 10.105 I received the following error on trying to connect via the applications listed under the PNAgent:
    This was being caused because the ICA file was being deleted before the PNAgent had finished reading it… very strange. After browsing a few forum posts I found that by modifying my local workstation registry I could resolve the issue by changing the ‘RemoveICAFile’ entry to equal false:
    HKEY_LOCAL_MACHINE\SOFTWARE\Citrix\ICA Client\Engine\Lockdown Profiles\All Regions\Lockdown\Client Engine\ICA File
    Alternately, if you are an Administrator wanting to resolve this for all of your PNAgent users and Web Interface users simply follow these instructions:
    Modify the \Inetpub\wwwroot\Citrix\MetaFrame\conf\default.ica on all of your Citrix Servers that have the web interface.
    Change the line "RemoveICAFile=yes" to "RemoveICAFile=no"

    Monday, November 19, 2012

    Windows could not start the Citrix XTE server on the local computer.

    Error: Windows could not start the Citrix XTE server on the local computer. The service terminated with a service-specific error 1

    Cause: Session Reliability port (2598) is not configured.
    Solution:
    Step 1: Verify the Session Reliability port is configured by using the below command 
    C:>netstat -an |find /i “2598″
    Step 2: Take the backup of httpd.conf file
    Step 3: Edit the C:\Program Files\Citrix\XTE\conf\httpd.conf (64 bit OS: C:Program Files (X86)

    copy the following content in httpd.conf file
    #CGP Listen Port
    Listen 2598
    # Log Level
    loglevel emerg
    Save the file and start the Citrix XTE Server service.


                                                                             OR

    Rename httpd.conf file in the path C:\Program Files\Citrix\XTE\conf and export from any of the working server. Then start the Citrix XTE Server service.

    Sunday, November 18, 2012

    The Citrix SMA service on Local Computer started and then stopped




    The Citrix SMA service on Local Computer started and then stopped



    “The Citrix SMA service on Local Computer started and then stopped. Some services stop automatically if they
    have no work to do, for example, the Performance Logs and Alerts service.”
    Resolution 1:
    To resolve the preceding issue, complete the following procedure:
    • Stop the SmaService.exe service by using the Task Manager.
    • Citrix SMA Service Properties and under the Log on tab, selectLocal System Account.
    • Set the SMA  Service to Manual and restart it, once the service started
    • Change Citrix SMA Service Properties and under the Log on tab, select Local Service Account.
    • Set the SMA  Service to Automatic and restart it

    Resolution 2:

    Please create a folder named " Active" in the path C:\Program Files\Citrix\Sma and try to start the service

    Tuesday, September 18, 2012

    4 States of Citrix Session

    Here are the 4 states and the differences between them:
    • Active - a user is active within a remote desktop session, for example, running applications, web browsing or similar stuff that involves using a mouse or keyboard.
    • Idle - User is considered idle after a period of mouse/keyboard inactivity in the RDP session. The user will be considered idle if there is no activity (e.g. keyboard strokes or mouse movement) in the configured time period. The default Terminal Services idle timeout is 1 minute, and the default for the Terminal Services Log is 5 minutes.
    • Disconnected - When a user is disconnected from the session but the session is still running. User could have been disconnect due to network or other failure or did not use proper log out procedure and just closed the Remote Desktop session window with the Close button [x]. This session is still running on the server and consuming resources, the users can reconnect and resume their disconnected session.
    • Remote Control - user is in remote control state if a user is remote controlling another user (also known as shadowing on Citrix servers).

    Tuesday, September 4, 2012

    Citrix Client Error 2320 (AllowHotKey)

    Error: "Citrix online plug-in Configuration Manager: No value could be found for (AllowHotKey) that satisfies all lockdown requirements. The lockdown requirements in force may be conflicting"

    The solution was a bit tricky, I tried several fixes from Citrix forums and articles, but I ended just deleting the Citrix key under the user part of the registry on the clients (HKEY_Current_user\software\Citrix). After deleting everything worked like a charm.

    Thursday, June 21, 2012

    Microsoft App-V

    Microsoft Application Virtualizationalso known as App-V formerly Microsoft SoftGrid ) is an application virtualization and application streaming solution from Microsoft.


    Microsoft Application Virtualization (MS App-V) platform allows applications to be deployed in real-time to any client from a virtual application server. It removes the need for local installation of the applications. Instead, only the App-V client needs to be installed on the client machines. All application data is permanently stored on the virtual application server. Whichever software is needed is either streamed or locally cached from the application server on demand and run locally. App-V applications are also sandboxed from each other, so that different versions of the same application can be run under App-V concurrently


    MS App-V thus allows centralized installation and management of deployed applications. It supports policy based access control; administrators can define and restrict access to the applications by certain users by defining policies governing the usage. The App-V client presents the user with a list of applications, to which the user has access. The user can then launch a virtualized instance of the application. Depending on the configuration, the systems administrator can be either notified of the action via email or it can require an explicit confirmation from the administrator for the application to start streaming and initialize or it can just simply check the Active Directory for the user's rights and stream the application to the user if it is authorized to run the application. The App-V client can also install local shortcuts that bootstrap the process of launching individual virtualized software instances.



    Architecture

    lthough App-V is best known for being deployed using the dedicated App-V Management infrastructure, these days Microsoft offers three deployment options. These three options are significantly different from an architectural standpoint: Dedicated App-V Management Server, Shared System Center Configuration Manager Architecture, and "Stand-alone" Mode wherein the application may be delivered manually.

    App-V Application Virtualization is composed mainly of two components – SystemGuard and App-V Sequencer. SystemGuard tracks and analysis configuration repositories and resources used by the application and intercepts the use of these resources, redirecting them to the virtualized instances of the resources. Virtualized resources include virtualized data such as user profile information and data; virtualized system services, such as COM controls, windows services and copy/paste abilities; and virtualized configuration repositories like registry hives and INI files

    App-V sequencer is the component which packages an application for virtualization and streaming. It also packages specific DLL files that it might require at the client side. It then packs all the application code and data into App-V's proprietary format that makes it more suitable for streaming

    At the client, when a streaming request is made to an App-V server, portions of the entire sequencer package are transferred to the client, who unpacks and initializes the SystemGuard environment and hosts the application inside it (with System Center Configuration Manager and the stand-alone client, the entire package contents are transferred). Each package is cached by the client for the duration of the application session. User settings are stored in the local system itself.
    Virtualized application packages can also locally reside at the client computer, thus eliminating the need of application server and streaming. Microsoft Systems Management Server can be used to push these packages to the client computer in the absence of a virtual application server. In this scenario, the App-V SMS Connector can be used to locally manage the application packages.

    Limitations

    • Microsoft Office plug-ins: Although one can sequence Microsoft Office plug-ins, it is not advised to sequence them due to many technical & usage issues. For example, in a situation where there are more than two plug-ins used by a user, if they are sequenced separately, then the user does not have control over which plug-in sequence starts when he opens a document. The only work around to resolve the issue is by creating a single suite or dynamic suite of all the plug-ins.
    • Application Size: If the maximum client cache size is set to at least 4 GB (The max can be 64 GB), then the maximum size of application (sft file) which can be streamed on that machine is 4 GB. All applications that have an installed footprint greater than or equal to the max client size, set by the client, should not be sequenced. The maximum application size Softgrid can handle is 4GB, due to the use of the FAT32 file-system.[5]
    • Device Driver: App-V presently does not support sequencing of kernel-mode device drivers; thus any application that installs a device driver cannot be sequenced. The only exception to this is when the device driver can be pre-installed locally; in this case, the application is sequenced without the device driver.
      • Auto Update: Applications with automatic updates should not be sequenced if their update mechanism cannot be disabled. Sequenced applications usually fail to update. In addition, allowing auto-update leads to non compliance of application version.
      • Services: Services can be started when an application starts and shuts down or when an application main executable terminates. Only user-mode services are suitable candidates for sequencing.
      • COM+: Some applications which use COM+ might not work properly in a virtual environment.
      • Internet Explorer & Service Packs: Microsoft does not support sequencing of any version of Internet Explorer.
      • Roaming Profiles: The default local cache location is %APPDATA%, this resides inside a folder that travels with roaming profiles, and will cause applications to fail often as files fail to sync using current best practices for roaming profiles in Windows Vista and Windows 7. Users will have to exclude the Softgrid Client folder from their syncing rules, or use an alternative location.

    Friday, June 8, 2012

    Citrix Services


    Here is an excerpt from the tech article:
    Service Name
    Executable
    Description
    Citrix ADF Installer Service (ADF Installer Service)
    AgentSVC.exe
    Used by Installation Manager in Enterprise and Platinum versions to install packages onto Presentation Servers
    Citrix Client Network (Client Network)
    cdmsvc.exe
    Handles the mapping of client drives and peripherals within ICA sessions
    Citrix CPU Utilization Mgmt/Resource Mgmt
    ctxcpusched.exe
    Used in Enterprise and Platinum versions to manage resource consumption
    Citrix CPU Utilization Mgmt/User-Session Sync (4.0 only)
    ctxcpuusync.exe
    Used in Enterprise version to synchronize user IDs of processes with their respective owner
    Citrix Diagnostic Facility COM Server (Diagnostic Facility COM Server)
    CdfSvc.exe
    Manages Diagnostic Facility tracing when used to diagnose problems with the Citrix Server
    Citrix Encryption Service (Encryption Service)
    encsvc.exe
    Handles encryption between the client device and the Citrix Server
    Citrix Health Monitoring and Recovery (4.5 only)
    HCAService.exe
    Provides health monitoring and recovery services in the event problems occur
    Citrix Independent Management Architecture
    (Independent Management Architecture)
    ImaSrv.exe
    Provides management services within the Citrix farm
    Citrix License Management Console
    (License server only)
    tomcat.exe
    Provides the web-based interface for licensing administration
    Citrix Licensing WMI (License server only)
    Citrix_GTLicensingProv.exe
    Provides information and notification regarding licensing events on the license server
    Citrix MFCOM Service (MetaFrame COM Server)
    mfcom.exe
    Provides COM services which allow remote connections of the management consoles
    Citrix Print Manager Service
    CpSvc.exe
    Handles the creation of printers and driver usage within Citrix sessions
    Citrix Resource Manager Mail (Resource Manager Mail)
    MailService.exe
    Used in Enterprise and Platinum versions to send email alerts when thresholds in the server farm have been exceeded
    Citrix Services Manager (4.5 only)
    IMAAdvanceSrv.exe
    Allows the components of Presentation Server to interface with the operating system
    Citrix SMA Service
    SmaService.exe
    Monitors the event log and Citrix WMI to raise alerts in the Access Suite Console (4.0) or Access Management Console (4.5)
    Citrix Streaming Service (4.5 only)
    RadeSvc.exe
    Used in Enterprise and Platinum versions to manage the Citrix Streaming Client when streaming applications
    Citrix Virtual Memory Optimization
    CTXSFOSvc.exe
    Used in Enterprise and Platinum versions to rebase .dlls in order to free up server memory
    Citrix WMI Service
    ctxwmisvc.exe
    Used to provide the Citrix WMI classes for information and management purposes
    Citrix XTE Server
    XTE.exe
    Handles SSL Relay and Session Reliability functionality
    CitrixLicensing
    (License server only)
    lmgrd.exe
    Handles allocation of licenses on the license server

    Monday, May 14, 2012

    Session Sharing in Xenapp


    Xenapp 6.5 NEW Disconnected Session Sharing:

    1.)  With XA 6.5 session sharing has been improved with disconnected session sharing
    2.)  When users start seamless application the session is created and tagged with unique ID instead of initial application name
    3.)  This makes the user possible to close the initial application and open a second application in a disconnected session. Also note that session will not terminate on closing the initial application because it does not depend on initial launched app since it has a Unique ID..

    Requirements for Disconnected Session Sharing:
    1.)  Session must belong to the user
    2.)  Session must be seamless
    3.)  Session must be on the server that hosts the desired application
    4.)   It must match the color depth & Other settings

    How does it work:
    1.)  The IMA first look for disconnected sessions already running the app requested
    2.)  If that’s not the case IMA next look for Users’s other disconnected sessions
    3.)  If more than one session is presented user must choose a session from the list
    4.)  Only if no eligible sessions --à a new session is created.

    FAST RECONNECT:
    1.)  This is designed for Roaming users no configuration and its inbuilt.
    2.)  It requires Latest Plugin and supports only few authentication methods(Single SIGN- ON, Passthrough, Prompt).

    How does it work:
    1.)  Client queries for ticket
    2.)  User Credentials are replaced with random ID and saved in ticket
    3.)  Client delivers the ticket with just ID
    4.)  Server matches the ID to user credentials and reconnects user to session

    Wednesday, May 2, 2012

    EDGESIGHT


    Edgesight
    Is a Application performance monitoring technology used to monitor real time user experience.
    With ES we can manage environment by direct line of sight across networks, servers, database & desktops. We can see what’s going on in any part of the infrastructure and more importantly we can see what’s going wrong .
    We can see the performance of the published applications, keep an eye on the Health of the devices (Servers, desktops /laptops). We can pull reports of what happened in past by Historical Trend analysis.


    Left Pane: Categories of Reports
    Right Pane: Reports
    Be default all reports shown are for last 7 days but you can modify to get by mentioning the time period.
    Edgesight Version History:
    Edgesight was first developed by a company called REFLECTANT later acquired by CITRIX.
    Edgesight 4.2 – Nashoba – no longer in support by Citrix
    Edgesight 4.5 – Wildcat
    Edgesight 5.0 – Okema ( comes with complete changes and overall console change)
    SP1 – No code name
    SP2 – Bromley  launched in early 2009 (ability to monitor Virtual desktops as well)
    Edgesight 5.5 – Killington is going to be the next release but version no is not confirmed.

    Licensing for Server:

    Licensing for Endpoint Devices:




    ES Infrastructure
    Edgesight Agent:  Collects data, Stores data in a local DB(Firebird DB), Uploads data to server according to schedule, Periodically checks for configuration changes.
    Edgesight Server Infrastructure:  Single or Multi-server Infrastructure. Primary components include

    i)                    Web Server : ES is basically a Web Server (includes Web Console)
    ii)                  SQL Reporting Services: To create reports from the DB
    iii)                Database Server : We need SQL 2000/2005/2008
    iv)                 License Server.


     

    i)     Web Component with the Reporting Services component (RS) installed in it
    ii)    SQL Server Database
    iii)   SMTP Server: When something goes wrong with the upload we can subscribe to send  mail  automatically & we can also have alerts triggering emails to be sent to specific account
    iv)    Endpoint device : Desktops & Laptops and Xenapp Servers both upload data to ES server
    v)                   From any machine if you would like to connect to ES console you can connect using port 80/443
    vi)                 Also feature called Remoting into Endpoints --- here you can connect to device directly and pull the data from local database. Port used 9035
    EDGESIGHT AGENT:  The main component is Agent service(rscorsrv.exe) and is responsible for collecting data, uploading data to server, checking for configuration changes and downloading those.
    Firebird Service (fbserver.exe) : Local DB. It communicates with Agent service via IPC (inter-process communication) similar to LHC in Xenapp servers.
    Kernel Mode Driver: Initially we uses this to collect to process data when the process runs & when it crashes
    WORKERS:
                        Are essentially VB Scripts. They perform DB maintenance, data collections , uploading the data to server and other functions. Some of the workers reside on the agent & some are sent to agent by the server to run and reside in memory. Most of the workers have LOG file.



    EDGESIGHT SERVER:  Backbone of ES Architecture. Collects, processes and stores uploaded data, responds to alert conditions, manages configuration, Grooms database.
    SERVER-SIDE COMPONENTS:
    i)                    Web Server: Web Component is basically is a website  hosted on IIS. You connect to Webpage and you can view reports, Alerts coming in, change any of the configurations.
                SCRIPT HOST (RSSH)  : This is the interface between web page and SQL server. The incharge of this is taking the payloads and putting into the SQL DB. Also incharge of grooming DB for on regular basis

    ii)                  Database Server: DB Component is the SQL Server Central Storage contains Configuration data and Agent uploads.
    iii)                Report Server:  is used to create Reports. This is basically a Web server. Used to display the reports in Edgesight . Uses MS SQL Reporting Services.            

    Active application monitoring:
    Here we configure an ultimate user that will periodically check your Xenapp environment & see how well its performing. So we create scripts and tell ultimate user to do something with published apps For Eg: logon to Pubs WORD and type something and save it to a N/W share. Then Ultimated user will run transactions based upon schedule & perform the actions mentioned in scripts.
    If any action mentioned in script does not work it triggers an alert and this show up in the console. For this AAM components needs to installed separately. Here installed LAUNCHERS(AAM Component) run transactions on Xenapp Servers.


    ICA CHANNEL MONITORING:
    Keep an eye on the all of the below virtual channels within the ICA protocol. Metrics are captured via Perfmon counters.
    Printer, Drive & Video; Session Compression; Session Line speed; I/O Audio; I/O speedscreen Data Channel; I/O Drive Bandwidth.
    END USER EXPERIENCE MONITORING:
    It gives us very detailed information on ICA sessions.
    i)                    Logon sequence & session performance
    ii)                  Client side & Server side ICA details.
    ICA Client launches and metrics are recorded & it is sent to Presentation server through “UserMonitoring ” virtual channel which will send it to EUEM service & stored in memory. The EUEM service will provide these details to ES Agent & stored in Firebird database along with other metrics.