Troubleshooting the Horizon Agent
In this lab we look at the impact the network might have for communications between the Agent and the Horizon Broker. JMS requires ports 4001 and 4002 to be open for communications to succeed. In high secure environments where for example Micro-segmentation and Identity Firewall rules are enabled this can be a challenge that needs to be overcome. We will consider what the Admin console shows us and also the logs when communications are broken and also what to look for when we have a healthy environment
we will execute a PowerShell script to facilitate a break scenario
- On the ControlCenter.techseals.co server
- on the Desktop
- select the START button
- from the START menu
- select and right-click Windows PowerShell ISE
- from the pop-out
- select More > Run as administrator
- from the pop-out
- select and right-click Windows PowerShell ISE
- from the START menu
- select the START button
- on the Desktop
- In the Windows PowerShell ISE window
- in the Terminal
- enter cd c:\scripts
- to select scripts
- with your keyboard
- press ENTER
- with your keyboard
- to select scripts
- enter cd c:\scripts
- in the Terminal
- In the Windows PowerShell ISE window
-
PS C:\scripts\ line
- enter cd .\
- with your Keyboard
- select the down arrow to
- Seselect lab 2. Horizon Agent Troubleshooting
- press ENTER
- press ENTER
- select the down arrow to
-
PS C:\scripts\ line
- In the Windows PowerShell ISE window
-
PS C:\scripts\lab 1. Troubleshooting Instant Clone line
- enter Set-ExecutionPolicy Unrestricted
- with your Keyboard
- press ENTER
- with your Keyboard
- enter Set-ExecutionPolicy Unrestricted
-
PS C:\scripts\lab 1. Troubleshooting Instant Clone line
- In the Execution Policy Change window
- select Yes to All
- In the Windows PowerShell ISE window
- PS C:\scripts\Lab 2. Horizon Agent Troubleshooting>... line
- enter .\
- with your Keyboard
- select the down arrow
- select disable_firewall_ports.ps1
- press ENTER
- press ENTER
- select disable_firewall_ports.ps1
- select the down arrow
- with your Keyboard
- In the Security Warning window
- select Run once
- In the Windows PowerShell ISE - Input window
- below Enter password for horizon-01a.techseals.co
- enter Pa$$w0rd
- select OK
- enter Pa$$w0rd
- below Enter password for horizon-01a.techseals.co
- In the Windows PowerShell ISE - Input window
- below Enter password for horizon-01b.techseals.co
- enter Pa$$w0rd
- select OK
- enter Pa$$w0rd
- below Enter password for horizon-01b.techseals.co
- In the Windows PowerShell ISE window
- note that the script has executed successfully for both Horizon-01a and Horizon-01b
- On the ControlCenter server
- launch the Chrome Site 1 - Bangalore shortcut
- On the Site 1 - Bangalore browser
- from the Favourites bar
- select the Horizon Site 1 shortcut
- from the Favourites bar
- In the Horizon 8 Admin Console
- enter the following:-
-
username area
- enter Administrator
-
password area
- enter Pa$$w0rd
- select SIGN IN
-
username area
- enter the following:-
- In the Horizon 8 Admin Console
- left menu bar
-
expand Inventory
- select Desktops
-
expand Inventory
- left menu bar
- In the Desktop Pools area
- select W11-INST-BLR
- In the W11-INST-BLR area
- select the Machines tab
- In the W11-INST-BLR area
-
Machines tab
- scroll to the right
- note the Status of Desktops
- "Agent Unreachable"
- note the Status of Desktops
- scroll to the right
-
Machines tab
You might have to wait up to five minutes, to see "Agent Unreachable" on both virtual machines
use the refresh icon if necessary
- In the Horizon 8 Admin Console
- left menu bar
- below Inventory
- select Farms
- below Inventory
- left menu bar
- In the Farms area
- select RDS-Farm-BLR
- In the RDS-Farm-BLR area
- select the RDS Hosts tab
- In the RDS-Farm-BLR area
-
RDS Hosts tab
-
scroll to the right
- note the Status of the Servers is
- "Agent Unreachable"
- note the Status of the Servers is
-
scroll to the right
-
RDS Hosts tab
- On the ControlCenter server
- open the Remote Desktops shortcut
-
In Remote Desktops folder
- open Site1
-
In Remote Desktops folder
- open the Remote Desktops shortcut
- In the Site 1 folder
- select and launch the Horizon-01a.RDP shortcut
note. You should automatically be logged withe Username - administrator and the password - Pa$$w0rd
- In the Horizon Connection server
- from the Taskbar
- select the File Explorer shortcut
- from the Taskbar
- In the File Explorer window
- from the menu bar
- select View
- In the drop menu to the right
- below Options
- select the expand Icon
- select Change folder and search options
- select the expand Icon
- below Options
- from the menu bar
- In the Folder Options window
- select the View tab
- In the Folder Options window
- View tab
- below Advanced settings:
- next to Show hidden files, folders or drives
- select the radio button
- next to hide extensions for know file types
- uncheck the checkbox
- to close the Folder Options window
- select OK
- next to Show hidden files, folders or drives
- In the File Explorer window
-
Quick access bar
- below This PC
- select Local Disk (C:)
- browse to ProgramData > Omnissa > Horizon > logs
-
in the logs folder
-
select the Date Modified column
- the idea is , to have the most up to date log right at the top of the window
-
select the Date Modified column
- below This PC
-
Quick access bar
- In the File Explorer window
- logs folder
- select and right-click the latest debug-2025- xxxx.txt file
- from dropdown select Edit with Notepad++
- select and right-click the latest debug-2025- xxxx.txt file
- logs folder
- In the Notepad++ window
-
scroll down to the bottom of the last log
- in the menu bar,
- select the Search tab
- in the dropdown
- select Find...
- in the menu bar,
-
scroll down to the bottom of the last log
- In the Find window
- next to Find what:
- enter VM Name:W11-INST-1
- next to Backward direction
- select the checkbox
- to the right of the window
- select Find Next
- next to Find what:
- In the Notepad++ window
- Note you have an Error, similar to this....
- " Unable to create a connection to: [[ServerEntry, hostname=horizon-01b.techseals.co, port=4001]]"
- note the debug log line number and the date DEBUG stamp
- Note you have an Error, similar to this....
- In the Notepad++ window
- look below and possibly above the existing entry
- Note that there are similar message of being unable to connect
- note the debug log line numbers and the date DEBUG stamps
- On the ControlCenter server
- from your Site 1 - Bangalore browser
- on the Favourites bar
- select the vcenter-01a shortcut
- on the Favourites bar
- from your Site 1 - Bangalore browser
- On the VMware vSphere login
- in the username area
- enter [email protected]
- in the password area
- enter Pa$$w0rd
- select LOGIN
- in the username area
- In the vCenter admin console
-
Hosts & Clusters inventory
- expand the BLRCapacity Cluster
- select W11-INST-2
-
Hosts & Clusters inventory
- In the vCenter admin console
- select W11-INST-2 area
- select LAUNCH WEB CONSOLE
- select W11-INST-2 area
- On the W11-INST-2 Desktop
- in the top right corner
- select Send Ctrl+Alt+Delete
- In the password area
- enter Pa$$w0rd
- to the right
- select the Submit icon
- in the top right corner
- On the W11-INST-2 Desktop
- from the taskbar
- select the File Explorer shortcut
- from the taskbar
- In the File Explorer window
- in the Menu bar
- next to View
- select the MORE icon
- from the pop-up
- select Options
- next to View
- in the Menu bar
- In the Folder Options window
- select the View tab
- In the Folder Options window
- View tab
- below Advanced settings:
- next to Show hidden files, folders or drives
- select the radio button
- next to Hide extensions for know file types
- uncheck the checkbox
- to close the Folder Options window
- select OK
- next to Show hidden files, folders or drives
- In the File Explorer window
-
Quick access bar
- below This PC
- select Local Disk (C:)
- browse to ProgramData > Omnissa > Horizon > logs
- in the logs folder
- select the Date Modified column
- the idea is , to have the most up to date log right at the top of the window
- select the Date Modified column
- below This PC
-
Quick access bar
- In the File Explorer window
- logs folder
- select and right-click the latest debug-2025- xxxx.txt file
- from dropdown select Edit in Notepad
- select and right-click the latest debug-2025- xxxx.txt file
- logs folder
- In the Notepad window
- scroll down to the bottom of the log
- on the Menu bar
- select Edit
- from the dropdown
- select Find
- from the dropdown
- select Edit
- In the Notepad application
-
Find window
- in the search area
- enter Unable to create a connection
- to the right
- select the UP arrow
- in the search area
-
Find window
- In the Notepad application
- close the FIND window
- note the agent is " Unable to connect to JMS server .
- on the next line, the horizon FQDN and port 4001 are shown as what the agent requires to connect to the Broker
- On the W11-INST-2 desktop
- from the Taskbar
- select and right-click the START button
- in the pop up
- select Shut down or sign out > Sign out
- in the pop up
- select and right-click the START button
- from the Taskbar
we will execute a PowerShell script to facilitate a reverse of the break scenario
- On the ControlCenter.techseals.co server
- on the Desktop
- select the START button
- from the START menu
- select and right-click Windows PowerShell ISE
- from the pop-out
- select More > Run as administrator
- from the pop-out
- select and right-click Windows PowerShell ISE
- from the START menu
- select the START button
- on the Desktop
- In the Windows PowerShell ISE window
- in the Terminal
- enter cd c:\scripts
- to select scripts
- with your keyboard
- press ENTER
- with your keyboard
- to select scripts
- enter cd c:\scripts
- in the Terminal
- In the Windows PowerShell ISE window
-
PS C:\scripts\ line
- enter cd .\
- with your Keyboard
- select the down arrow to
- Seselect lab 2. Horizon Agent Troubleshooting
- press ENTER
- press ENTER
- select the down arrow to
-
PS C:\scripts\ line
- In the Windows PowerShell ISE window.
- PS C:\scripts\Lab 2. Horizon Agent Troubleshooting>... line
- enter .\
- with your Keyboard
- select the down arrow
- select enable_firewall_ports.ps1
- press ENTER
- press ENTER
- select enable_firewall_ports.ps1
- select the down arrow
- with your Keyboard
- In the Security Warning window
- select Run once
- In the Windows PowerShell ISE - Input window
- below Enter password for horizon-01a.techseals.co
- enter Pa$$w0rd
- select OK
- enter Pa$$w0rd
- below Enter password for horizon-01a.techseals.co
- In the Windows PowerShell ISE - Input window
- below Enter password for horizon-01b.techseals.co
- enter Pa$$w0rd
- select OK
- enter Pa$$w0rd
- below Enter password for horizon-01b.techseals.co
- In the Windows PowerShell ISE window
- note that the script has executed successfully for both Horizon-01a and Horizon-01b
- On the ControlCenter server
- launch the Chrome Site 1 - Bangalore shortcut
- On the Site 1 - Bangalore browser
- from the Favourites bar
- select the Horizon Site 1 shortcut
- from the Favourites bar
- In the Horizon 8 Admin Console
- enter the following:-
-
username area
- enter Administrator
-
password area
- enter Pa$$w0rd
- select SIGN IN
-
username area
- enter the following:-
- In the Horizon 8 Admin Console
- left menu bar
-
expand Inventory
- select Desktops
-
expand Inventory
- left menu bar
- In the Desktop Pools area
- select W11-INST-BLR
- In the W11-INST-BLR area
- select the Machines tab
- In the W11-INST-BLR area
-
Machines tab
- under Machine
- notice there is now, a green icon next to your VM
- scroll to the right
- note the Status of Desktops is now
- "Available"
- note the Status of Desktops is now
- under Machine
-
Machines tab
- In the Horizon 8 Admin Console
- left menu bar
- below Inventory
- select Farms
- below Inventory
- left menu bar
- In the Farms area
- select RDS-Farm-BLR
- In the RDS-Farm-BLR area
- select the RDS Hosts tab
- In the RDS-Farm-BLR area
-
RDS Hosts tab
-
scroll to the right
- note the Status of the Servers is now
- "Available"
- note the Status of the Servers is now
-
scroll to the right
-
RDS Hosts tab
- On the ControlCenter server
- switch to the Horizon-01a.RDP session
note. You should still have an RDP session to the Horizon-01a broker established and logged in with the Username - administrator and the password - Pa$$w0rd
- On the Horizon-01a server
- in the Reload window
- select Yes
- in the Reload window
note. You should still have Notepad++ open and the debug log active > If you dont go back to Part 3 and reopen your debug log with Notepad++
- In the Notepad++ window
-
scroll down to the bottom of the last log
- in the menu bar,
- select the Search tab
- in the dropdown
- select Find...
- in the menu bar,
-
scroll down to the bottom of the last log
- In the Find window
- next to Find what:
- enter VM Name:W11-INST-1
- next to Backward direction
- validate that the checkbox is enabled
- select Find Next
- validate that the checkbox is enabled
- next to Find what:
- In the Notepad++ window
- Note you have no new further Errors, similar to this.... you will still have the old entries, but no new entries
- " Unable to create a connection to: [[ServerEntry, hostname=horizon-01b.techseals.co, port=4001]]"
- validate debug log line number and the date DEBUG stamp from before
- Note you have no new further Errors, similar to this.... you will still have the old entries, but no new entries
- In the Notepad++ window
- validate that there are no further DEBUG logs related to the W11-INST-1 virtual machine.
- notice that there are no further DEBUG logs for the RDS servers.
- validate debug log line number and the date DEBUG stamp from before
- In the vCenter admin console
-
Hosts & Clusters inventory
- BLRCapacity Cluster
- select W11-INST-2
- BLRCapacity Cluster
-
Hosts & Clusters inventory
- In the vCenter admin console
- select W11-INST-2 area
- select LAUNCH WEB CONSOLE
- select W11-INST-2 area
- On the W11-INST-2 Desktop
- in the top right corner
- select Send Ctrl+Alt+Delete
- In the password area
- enter Pa$$w0rd
- to the right
- select the Submit icon
- in the top right corner
- On the W11-INST-2 Desktop
- from the taskbar
- select the File Explorer shortcut
- from the taskbar
- In the Site 1 Bangalore Browser
- select and switch to the W11-INST-2
- On the W11-INST-2 Desktop
- from the taskbar
- select the File Explorer shortcut
- from the taskbar
- In the File Explorer window
-
Quick access bar
- below This PC
- select Local Disk (C:)
- browse to ProgramData > Omnissa > Horizon > logs
- in the logs folder
- select the Date modified column
- the idea is , to have the most up to date log right at the top of the window
- select the Date modified column
- below This PC
-
Quick access bar
- In the File Explorer window
- logs folder
- select and right-click the latest debug-2025- xxxx.txt file
- from dropdown select Edit in Notepad
- select and right-click the latest debug-2025- xxxx.txt file
- logs folder
- In the Notepad window
- scroll down to the bottom of the log
- on the Menu bar
- select Edit
- from the dropdown
- select Find
- from the dropdown
- select Edit
- In the Notepad application
-
Find window
- in the search area
- enter Unable to connect to JMS server
- to the right
- select the UP arrow
- in the search area
-
Find window
- In the Notepad application
- close the FIND window
- note the agent is " Unable to connect to JMS server " message
- this was the same message as before
- note its a ReconnectTask-agent
- In the Notepad application
- scroll down and look out for JMS_STATE_PAIRING
- a few lines down, look out for
-
"OK response" for HORIZON-01A
- and
- "OK response" for HORIZON-01B
-
"OK response" for HORIZON-01A
Conclustion
What we have seen in this lab is the effect the network can have on communication between the the Horizon Agent and the Broker. We have identified logs we can use and we have seen the nature of messages we can look out for in both a healthy and broken environment











0 Comments
Add your comment