Connection Failed User Has Valid Session But Rdsh Is Unhealthy

%3CLINGO-SUB%20id%3D%22lingo-sub-1243226%22%20slang%3D%22en-US%22%3EConnection%20Failed%20User%20Has%20Valid%20Session%20But%20Rdsh%20Is%20Unhealthy%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1243226%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20tried%20to%20auto%20shutdown%20some%20host%20VMs%20during%20off-hours.%20But%20we%20found%20that%20user%20will%20still%3CSTRONG%3E%20keep%20in%20the%20same%20session%20host%20VM%20which%20has%20been%20shutdown%3C%2FSTRONG%3E%20and%20he%20cannot%20connect%20to%20WVD%20anymore.%20(There%20is%20another%20VM%20still%20running%20that%20he%20can%20connect%20to%20it)%20And%20the%20error%20log%20as%20below%EF%BC%9A%3C%2FP%3E%0A%3CUL%3E%0A%3CLI%3EError%20Code%EF%BC%9A-21462338088%3C%2FLI%3E%0A%3CLI%3EError%20Code%20Symbolic%EF%BC%9A%26nbsp%3BConnection%20Failed%20User%20Has%20Valid%20Session%20But%20Rdsh%20Is%20Unhealthy%3C%2FLI%3E%0A%3CLI%3EError%20Operation%EF%BC%9A%20Lookup%20Session%20Host%20Pool%3C%2FLI%3E%0A%3CLI%3EError%20Message%EF%BC%9ASessionHost%20%3D%20%E2%89%A4WvdHost-14.XXX.com%E2%89%A5%20is%20not%20healthy.%3C%2FLI%3E%0A%3C%2FUL%3E%0A%3CP%3EIt%20seems%20that%20session%20will%20still%20keep%20when%20host%20VM%20has%20been%20shutdown.%3C%2FP%3E%0A%3CP%3E%3CFONT%20color%3D%22%23ff0000%22%3E%3CSTRONG%3E1.%20How%20t%3CFONT%20color%3D%22%23ff0000%22%3Eo%20automatically%20%3C%2FFONT%3Eremove%20all%20the%20user%20sessions%20when%20VM%20has%20been%20shutdown%3F%26nbsp%3B%3C%2FSTRONG%3EInstead%20of%20using%20PowerShell%20to%20remove%20individual%20session%20by%20%3CSTRONG%3EInvoke-RdsUserSessionLogoff.%3C%2FSTRONG%3E%3C%2FFONT%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fpowershell%2Fmodule%2Fwindowsvirtualdesktop%2FInvoke-RdsUserSessionLogoff%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fpowershell%2Fmodule%2Fwindowsvirtualdesktop%2FInvoke-RdsUserSessionLogoff%20%3C%2FA%3E%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CP%3E%3CSTRONG%3E2.%20Or%20how%20to%20set%20the%20idle%20time-out%20in%20WVD%3F%26nbsp%3B%3C%2FSTRONG%3E%3C%2FP%3E%0A%3CDIV%20id%3D%22tinyMceEditorJuliaWu_0%22%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%26nbsp%3B%3C%2FDIV%3E%0A%3CDIV%20id%3D%22tinyMceEditorJuliaWu_1%22%20class%3D%22mceNonEditable%20lia-copypaste-placeholder%22%3E%26nbsp%3B%3C%2FDIV%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-1617984%22%20slang%3D%22en-US%22%3ERe%3A%20Connection%20Failed%20User%20Has%20Valid%20Session%20But%20Rdsh%20Is%20Unhealthy%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1617984%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F544032%22%20target%3D%22_blank%22%3E%40JuliaWu%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20got%20the%20same%20issue%20and%20behind%20my%20WVD%20in%20Azure%20is%20VMSS%20environment.%26nbsp%3B%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ERegards%2C%26nbsp%3B%3C%2FP%3E%3CP%3EIliya%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Microsoft

We tried to auto shutdown some host VMs during off-hours. But we found that user will still keep in the same session host VM which has been shutdown and he cannot connect to WVD anymore. (There is another VM still running that he can connect to it) And the error log as below:

  • Error Code:-21462338088
  • Error Code Symbolic: Connection Failed User Has Valid Session But Rdsh Is Unhealthy
  • Error Operation: Lookup Session Host Pool
  • Error Message:SessionHost = ≤WvdHost-14.XXX.com≥ is not healthy.

It seems that session will still keep when host VM has been shutdown.

1. How to automatically remove all the user sessions when VM has been shutdown? Instead of using PowerShell to remove individual session by Invoke-RdsUserSessionLogoff.

https://docs.microsoft.com/en-us/powershell/module/windowsvirtualdesktop/Invoke-RdsUserSessionLogoff...

2. Or how to set the idle time-out in WVD? 

 
 
1 Reply
Highlighted

@JuliaWu 

 

I got the same issue and behind my WVD in Azure is VMSS environment. 

 

Regards, 

Iliya