Tag: citrix

(65 Scripts)

<< Back to Script Library
This script uses the CUActions available in v8.8 onwards to power on VMs on any supported hypervisor. It can be used as a right-click action or as an automated action by a trigger.
Version: 3.0.10  •   Created: 2023-05-20  •   Modified: 2023-06-22
This script uses the CUActions available in v8.8 onwards to force power off VMs on any supported hypervisor. It can be used as a right-click action or as an automated action by a trigger.
Version: 4.0.31  •   Created: 2023-05-20  •   Modified: 2023-06-22
Run on a Citrix Delivery Controller as a user with at least read only Studio access to site and license data. It will highlight licenses due to expire within the specified number of days, to allow for the renewal process to commence, or where the maximum number of licenses is in use or has been exceeded.
Version: 1.1.5  •   Created: 2023-04-14  •   Modified: 2023-05-25
Check Profile Sizes examines user profiles for all or selected user accounts on the target machine, grouping the results by file type, using the extension.

For each group of files, if the size of the group exceeds a threshold (default 15% of the total profile size) the individual files are listed, sorted by path or by size (descending) and showing the actual file size in bytes.

To keep the output reasonably short, a threshold is set on the number of files shown individually per are listed by path (default 6) - beyond this, files are summarized by folder (order by count of files, descending).

Arguments:
ThresholdPercentToExpand (default: 15) - the threshold percent of the total profile size at which a file-extension group is listed.
SamAccountNameList (default: All) - the list of account names to be reported (comma-separated, any leading or trailing spaces will be trimmed). If set to All, the script will include local user and Active Directory user accounts.
SortBy (default: Size) - must be set to Size (individual files are listed by size, descending) or Path (individual files are listed by full path, ascending).
PreSummarySize (default: 6) - the number of files that will be listed individually (by group, according to the configured sort order) before the script switches to reporting files grouped by folder.
Version: 1.2.17  •   Created: 2023-03-08  •   Modified: 2023-03-23
Check the status and common issues with Citrix VDA registration
Version: 1.0.1  •   Created: 2021-08-19  •   Modified: 2021-08-19
Assign or unassign a tag to one or more Citrix machines, optionally creating the tag if it does not already exist.
Can also be used to show current tag assignments for specified machines and delete a tag entirely after removing it from all machines where it is in use.
Maintenance mode can be enabled/disabled too where the use case is where the tag is used to give details of why the machine has been put in maintenance mode, who by, when, etc
Script must be run on a Citrix delivery controller or a machine where the Citrix PowerShell cmdlets are installed. In the latter case, a delivery controller name must be given in the arguments
Version: 1.1.21  •   Created: 2021-07-27  •   Modified: 2022-07-27
Citrix HDX Optimization can improve the user experience for Teams video/audio use.
The optimization will also significantly reduce the resource consumption on the VDA.

Please report any issues and feedback
Version: 2.9.24  •   Created: 2021-01-04  •   Modified: 2021-03-05
This Script-Based action retrieves the HDX Insight information for a given user session
Version: 3.1.5  •   Created: 2020-11-15  •   Modified: 2024-01-26
Shadows Citrix, VMware, RDSH and WVD sessions
Version: 1.3.13  •   Created: 2020-10-15  •   Modified: 2020-10-20
Performs a test of all the technical requirements for HDX content redirection, which can potentially save bandwidth and CPU. The script's output provides the test results along with recommendations on components that need to be enabled or upgraded for content redirection to work.
Version: 1.4.20  •   Created: 2020-10-07  •   Modified: 2020-10-13
Run on a Delivery Controller or where the CVAD PowerShell snapins are available, e.g. Studio is installed or on a machine with the DaaS Remote PowerShell SDK (for Cloud). User running the script for on-prem must have sufficient permission to change the enabled state of the selected delivery groups. For Cloud, CU stored credentials must have previously been saved for the local user running the script.

To use this script as an automated action where parameters cannot be passed, copy the script and set the $disable parameter in the Param() block at the top of the script to "true" or "false" depending on whether you are disabling or enabling delivery groups respectively.

The Cloud Customer Id or Delivery Controller is an optional argument which can be used when there are more than 1 credential file for the user running the script so that the correct Cloud customer can be chosen. When used on-prem, the parameter is used to tell the script what delivery controller to connect to when the script is not run on a DDC.
Version: 2.1.13  •   Created: 2020-10-06  •   Modified: 2024-01-26
Run on a Delivery Controller or where the CVAD PowerShell snapins are available, e.g. Studio is installed. User running the script must have sufficient permission to chage the enabled state of the selected delivery groups
Version: 1.1.6  •   Created: 2020-10-06  •   Modified: 2020-10-13
Show how recently (in number of days) delivery groups have had sessions launched from them, by checking the last used property for each machine in a delivery group.
Specify the minimum number of days last launched to show only delivery groups which have not had sessions launched within that number of days and optionally disable them. Specify 0 days to show all delivery groups.

Run on a Delivery Controller or where the CVAD PowerShell snapins are available, e.g. Studio is installed.
Version: 2.6.19  •   Created: 2020-10-02  •   Modified: 2020-10-09
Query the selected delivery controller via OData to retrieve connection failure details for a specific user, or all users, within a specified number of days ago
Version: 2.4.10  •   Created: 2020-08-05  •   Modified: 2020-12-01
There are many situations for which a machine (server OS or workstation) will lose domain trust.
If the ControlUp agent is installed on the machine, this script will execute locally and repair the domain trust. Domain credentials with permission to reset the computer account must be provided.
Version: 1.2.7  •   Created: 2020-05-06  •   Modified: 2020-05-07
This Script Action checks if your Citrix ADC appliance is a VPX and if so, changes the cpuyield setting to YES to ensure no High CPU usage is reported on the hypervisor (see https://support.citrix.com/article/CTX229555)

Note: This script only changes the setting on the current ADC and most be performed on both nodes of a HA pair as the setting is node specific and not synchronized.
Version: 1.2.3  •   Created: 2020-01-05  •   Modified: 2020-02-11
this Script Action checks if the suggested mitigation responder policy is configured and globally bound on the Citrix ADC or Citrix Gateway appliance as described in Citrix knowledgebase article CTX267679 (https://support.citrix.com/article/CTX267679).

Note: This Script Action does not perform the suggested mitigation for the management interfaces as it may break administration access.
Version: 2.2.9  •   Created: 2020-01-01  •   Modified: 2020-01-08
Enable or Disable by name, or name pattern, with the option to message any users currently running the apps and/or terminate them after a specified grace period.
Version: 1.0.1  •   Created: 2019-11-04  •   Modified: 2019-11-04
citrix 59
This is a simple script that restarts the BrokerAgent service on a Citrix VDA. This is useful when VDAs become unregistered. It forces them to try to re-register to a Delivery Controller. In some instances a reboot of the VDA may be required, for everything else there's this SBA!
Version: 1.1.8  •   Created: 2019-10-23  •   Modified: 2021-03-18
The script uses udadmin.exe and display the license(s) checked out for the selected username and/or client device. Note that the script is required to run in the Citrix License Server.
WARNING: avoid running the script against multiple sessions simultaneously to prevent significant resource consumption in the Citrix license server.
Version: 1.19.27  •   Created: 2019-10-03  •   Modified: 2019-10-18
citrix 138
This Script Action runs a Citrix ADC, previously known as NetScaler, High Availability (HA) healthcheck to ensure no errors occured for the HA sync and both HA nodes are UP and running.
Version: 2.7.11  •   Created: 2019-07-27  •   Modified: 2019-08-26
This script creates a video of the entire user display area and saves it in a location of choice. This script requires ffmpeg.exe to be downloaded and placed in an accessible location.
Version: 1.3.4  •   Created: 2019-03-13  •   Modified: 2019-03-27
This script gets the dimensions of the users working display area and takes screenshots. The screenshots can be saved as a BMP, JPG or PNG in a location of choice.
Version: 3.2.5  •   Created: 2019-03-13  •   Modified: 2023-03-20
Displays the titles of all visible windows running in the user session
Version: 1.0.1  •   Created: 2019-01-13  •   Modified: 2019-01-13
Finds and optionally deletes local user profiles. The user can provide two arguments - the minimum profile age in days and the minimum profile size. The default operation mode is to display the profiles that fit these criteria. When the "Delete" option is set to "true", the script will delete the profiles it found.
Version: 2.4.20  •   Created: 2018-12-26  •   Modified: 2020-06-10
Show the client device Operating System type form for a specific user session.
Use this script without requesting the display of the Receiver version to get the results grouped by client OS (available only as a ControlUp Script Based Action).

Categorization of the Client OS is accomplished by querying the Citrix VDA or XA65 worker for the ClientPlatformId registry value in the appropriate Citrix ICA hive for that user session and follow the conversion described in this document:
https://www.citrix.com/mobilitysdk/docs/clientdetection.html
Version: 2.8.23  •   Created: 2018-12-08  •   Modified: 2018-12-16
Show details for all PVS target devices which are marked as active
Version: 2.3.11  •   Created: 2018-12-06  •   Modified: 2019-04-04
This script queries and displays the values of performance counters for the Citrix Federated Authentication Service object. It requires the "CitrixFederatedAuthenticationService" service to exist on the target computer.
Version: 1.0.1  •   Created: 2018-11-29  •   Modified: 2018-11-29
citrix FAS 77
Citrix Apps and Desktops (formerly XenApp and XenDesktop) introduced Adaptive transport which automatically chooses between TCP & UDP for the HDX sessions. This script will leverage the ctxsession command to display the current status of the active HDX sessions.
Version: 1.10.23  •   Created: 2018-11-19  •   Modified: 2018-12-20
Show the Citrix Director actions performed in a given time window, optionally filtered on a specific user. Use this SBA to see what actions have been taken which might affect end users such as logging them off.
Arguments:
Start - optional time to show actions from. Can be specified as a date/time or as a number of units of time back from the present such as 7d or 1w where s=second,m=minute,h=hour,d=day,w=week,y=year (default is 7 days)
End - time to stop showing actions after. Can be specified either as a date/time or a number of units of time from the start value specified. (default is the current time)
If date/time values are used, they must be enclosed in double quotes, e.g. "02/02/2018 08:00:00"
Username - optional name of a user to just show changes for
Version: 1.4.6  •   Created: 2018-10-29  •   Modified: 2018-11-26
Show the configuration changes made in Citrix Studio in a given time window, optionally filtered on a specific user. Use this SBA to see if any changes have been made which might be affecting end users.
Arguments:
Start - optional time to show changes from. Can be specified as a date/time or as a number of units of time back from the present such as 7d or 1w where s=second,m=minute,h=hour,d=day,w=week,y=year (default is 7 days)
End - time to stop showing changes after. Can be specified either as a date/time or a number of units of time from the start value specified. (default is the current time)
If date/time values are used, they must be enclosed in double quotes, e.g. "02/02/2018 08:00:00"
Username - optional name of a user to just show changes for
Version: 1.4.14  •   Created: 2018-10-29  •   Modified: 2018-11-26
Recurses AD groups found to show all user accounts with any access to Citrix Studio.
Needs to be run using an account that has at least read-only Studio access.
Use it to see exactly which users have access and what level.
Arguments:
User Name to Query - an optional username or regular expression to restrict the display to

If a name is specified as a parameter then only that account is reported on
Version: 1.6.11  •   Created: 2018-10-24  •   Modified: 2018-11-26
Retrieve Citrix Provisioning Services audit events, if auditing has been enabled although it can be enabled by this SBA if required. Use to see what administrative actions were performed in an optional time window, by whom and what was done. It must be run with the credentials of a user who has been granted PVS access.
Arguments:
Enable Auditing - if auditing is not enabled, specifying true for this parameter will enable auditing if the user running the SBA has sufficient privilege.
Start - optional time to show audit events from. Can be specified as a date/time or as a number of units of time back from the present such as 7d or 1w where s=second,m=minute,h=hour,d=day,w=week,y=year
End - optional time to stop showing audit events after. Can be specified either as a date/time or a number of units of time from the start value specified.
If date/time values are used, they must be enclosed in double quotes, e.g. "02/02/2018 08:00:00"
Version: 1.3.6  •   Created: 2018-10-23  •   Modified: 2018-11-26
Pull all log separate Citrix StoreFront log files into a single time sorted csv file. You may need to change the StoreFront logging levels first which can be done with the "Show or Change StoreFront Logging" SBA. Use to help diagnose StoreFront issues.
Arguments:
Output csv file - full path to a local or remote file to store the log entries in
Start - optional time to start log export from, e.g. just before the problem started or was reproduced. Can be specified as a date/time or as a number of units of time back from the present such as 7d or 1w where s=second,m=minute,h=hour,d=day,w=week,y=year
End - optional time to stop log export at. Can be specified either as a date/time or a number of units of time from the start value specified.
If date/time values are used, they must be enclosed in double quotes, e.g. "02/02/2018 08:00:00"
Version: 2.4.7  •   Created: 2018-10-23  •   Modified: 2024-01-26
Retrieve PVS boot times for a given period from event logs and show them with overall statistics such as fastest, slowest and average boot times. Can help find performance issues. Ensure that each PVS server's stream service has event logging enabled
Arguments:
Last - report on events created in the last x hours/days/weeks, e.g. 7d for last 7 days or 4w for 4 weeks (default is 7 days)
Version: 1.5.7  •   Created: 2018-10-17  •   Modified: 2018-11-26
Query or change the logging levels in Citrix StoreFront.
Enable more verbose logging when troubleshooting potential StoreFront issues but turn the level back to off or error when finished to reduce the impact on CPU and free disk space.
Arguments:
Cluster - ff set to true then all servers in the cluster will be discovered and reported/operated on rather than just the selected computer (default is false)
Trace Level - specify one of: 'Off', 'Error','Warning','Info','Verbose' or leave empty to query rather than change the current settings (default is empty)
Version: 1.4.14  •   Created: 2018-10-17  •   Modified: 2018-11-26
Disconnect or logoff sessions on the selected computer(s) which have been idle in excess of a given period, specified in minutes.
Arguments:
Idle Period - the time in minutes after which a disconnected session will be logged off or disconnected depending on the value for the "Logoff" argument (default is 30 minutes)
Logoff - if true, sessions idle in excess of the idle period will be logged off, otherwise they will be disconnected (default is false so sessions will be disconnected)
Version: 1.5.7  •   Created: 2018-10-13  •   Modified: 2018-11-23
Cancels any "Message and Logoff" SBAs which are still running on the selected computer(s) by finding the associated PowerShell process and terminating it.
Arguments:
Cancellation Message - A message to display to the users so they can be informed that they will not be logged off (default is no mesage)
Version: 1.3.3  •   Created: 2018-10-12  •   Modified: 2018-11-23
Send a message to all connected sessions and then log them all off after a specified amount of time. The message can be repeated at a specified interval if required.
For instance, a delay of 15 minutes can be set and the users messaged every 5 minutes with the text specified in the "Message Text" argument.
When the configured script timeout of 60 seconds is reached, an error will be displayed but the script will keep running. If you need to cancel the logoff once the script has timed out, run the "Cancel Logoffs" SBA for the same computer(s)
Arguments:
Message Text - The text of the message to display to all connected users on the selected computer(s)
Delay Before Logoff - The period in minutes from when the script is invoked to when all users will be automatically logged off by the SBA
Message Every - how often, in minutes, the same message is displayed to the remaining users. Specify zero or a blank value to not repeat the message after the initial display
Version: 1.3.13  •   Created: 2018-10-12  •   Modified: 2018-11-23
Show user name, logon and logoff times of all users who have logged off, or been logged off, the selected computer(s) in the last x hours where x is an argument defaulting to 48. Useful to be able to spot if many users were logged off at a specific time.
Arguments:
Hours back to search - default is 48
User - optional user name to search for otherwise all users will be displayed
Version: 1.5.7  •   Created: 2018-07-18  •   Modified: 2018-11-26
Use quser.exe to find disconnected sessions on the chosen computer and order on the most recently disconnected, showing the user's logon time too.
Arguments:
Hours Back to Check - how far back to look for disconnected sessions so those disconnected before this time will not be included (default is 24 hours)
Version: 1.6.19  •   Created: 2018-07-18  •   Modified: 2018-11-21
Get a detailed overview of the most recent logon process for a specific user. This script queries the event log for every major event that relates to the logon process. Use this action to track down which phase is responsible for delays during the logon process. Uses WMI to retrieve pre-Windows logon phase data from Citrix so does not use OData and therefore does not need credentials
Version: 20.32.178  •   Created: 2018-07-02  •   Modified: 2024-03-24
Reset registry key where WEM registry settings are stored.
Version: 1.2.25  •   Created: 2017-07-11  •   Modified: 2019-05-20
citrix WEM 72
The script runs for 20 seconds and measures (once every 2 seconds) the ICA RTT and network latency of the relevant session.
The output shows the session info (username, device name/IP, session name/ID) and 10 reads (once every 2 seconds) of the session's ICA RTT and network latency in seconds.
Version: 2.2.39  •   Created: 2017-03-20  •   Modified: 2017-04-23
Resets Citrix Receiver in VDA session. Requires cleanup.exe and selfservice.exe. It can take a little over a minute to run.
* Resetting will delete all apps, desktops, accounts, and configurations, and return Receiver to default settings. It will also close all active sessions. Only reset Citrix Receiver to resolve serious problems.
Version: 2.2.6  •   Created: 2016-08-11  •   Modified: 2017-02-26
This script measures the bandwidth of a given active HDX session, and breaks down the bandwidth consumption into the most useable ICA virtual channels. The output shows the bandwidth usage in kbps (kilobits per second) of each virtual channel and the total session. This version shows only the session output (download), and not the upload.
Version: 1.2.27  •   Created: 2016-06-26  •   Modified: 2016-06-27
Use this script based action to pull detailed information on the cache usage on Citrix XenDesktop 7.9 and above.
Version: 1.0.1  •   Created: 2016-05-31  •   Modified: 2016-05-31
Checks the computer registry and displays current ICA Listener binding information - if ICA is enabled, displays the adapters to which ICA is bound
Version: 2.0.3  •   Created: 2016-05-03  •   Modified: 2018-11-05
Gets detailed information on Citrix subcomponents
Version: 1.8.24  •   Created: 2016-04-29  •   Modified: 2017-01-31
citrix 385
The following script runs a report against the PVS farm using the latest PowerShell 7.7 and above PowerShell cmdlets.
Version: 1.0.9  •   Created: 2016-04-13  •   Modified: 2016-04-22
The script runs on the ControlUp Console computer and initiates an HDX connection against one or more XenApp servers in order to check the server's health. The script does not perform any actual login activity to the targeted XenApp server.
Version: 1.12.26  •   Created: 2016-03-13  •   Modified: 2016-03-16
This script will check the target computer to see if Citrix's list of recommended Microsoft patches are installed for Windows Server 2012/2012 R2. This helps with Best Practice baselining.
Version: 3.2.6  •   Created: 2015-10-13  •   Modified: 2019-09-24
Gets the PVS target device retries count via the "Mcli-Get DeviceStatus" PowerShell command. This action should be executed on a PVS server with the MCLI PowerShell snap-in installed.
Version: 1.2.4  •   Created: 2015-08-09  •   Modified: 2015-08-10
citrix PVS 572
Get 'Load Index' summary of any Multi-Session XenDesktop/XenApp server at your site.
You will be prompted to specify a XenDesktop BrokerDDC and user who have
permissions to the site.
Version: 2.4.17  •   Created: 2015-08-03  •   Modified: 2019-02-17
A Script to obtain the Pool Non Paged Bytes which ultimately is an indication of the amount of Cache in Ram used by Citrix Provisioning Services.
This script will output the amount of PVS Ram Cache in use. This is done by enumarating the amount of Pool nonPaged Bytes in use, which is a measure of the RamCache. Action should be taken if this figure is close to the amount allocated within PVS. The script also supports examining the PVS configuration of disk cache only.
Version: 2.12.18  •   Created: 2015-03-29  •   Modified: 2015-04-14
This disables DEP which is recommended by Citrix.
Version: 1.0.1  •   Created: 2014-08-27  •   Modified: 2014-08-27
This will create a new XenApp published desktop. Please specify which domain account or group will have access to the desktop.
Version: 1.0.2  •   Created: 2014-04-10  •   Modified: 2014-04-10
Adds the selected XenApp server(s) to a Worker Group
Version: 3.2.13  •   Created: 2013-12-30  •   Modified: 2014-02-18
Disable XenDesktop maintenance mode for the selected computer(s)
Version: 9.10.32  •   Created: 2013-11-24  •   Modified: 2023-02-23
Enable XenDesktop maintenance mode for the selected computer(s). Highlight the target VMs, but run it on the broker for the VMs.
Version: 8.0.11  •   Created: 2013-11-24  •   Modified: 2023-02-23
Remove selected server(s) from the list of servers on which a selected application is published
Version: 2.0.2  •   Created: 2013-11-24  •   Modified: 2014-02-20
Enable XenApp Logon to the selected server
Version: 2.0.2  •   Created: 2013-11-24  •   Modified: 2014-02-19
Disable XenApp Logon to the selected server. This state only persists until the next reboot.
Version: 2.0.4  •   Created: 2013-11-24  •   Modified: 2014-02-19
Changes the XenApp Logon Mode for the selected server. Please enter one of the following states: AllowLogOns, ProhibitNewLogOnsUntilRestart, ProhibitNewLogOns, ProhibitLogOns
Version: 4.1.7  •   Created: 2013-11-21  •   Modified: 2017-11-14
Removes the selected XenApp server(s) from a Worker Group
Version: 2.0.3  •   Created: 2013-11-21  •   Modified: 2014-02-20