npressfetimg-2869.png

How to Start a Horizon Session from a Linux Command Line – Virtualization Review

The biggest Method To start out a Horizon Session from a Linux Command Line

That is the third and final article in a collection on starting the Horizon Shopper from the command line. Inside The primary article, I walked by way of how to launch the Horizon Shopper to a Horizon deskprime using a .bat file. Inside the second article, I confirmed how I added a .bat file to the taskbar And start menu which might mechanically log me in to a Horizon streaming software. Being that I used to be already down this rabbit hole, I decided It Could be worthwright hereas to go one step further; On This textual content material, I am going to go over how to start a Horizon session from the Linux command line, even In case You are not on the GUI.

Do You’d like to aren’t acquainted using the vmware-view command, I extremely advocate first studying the articles talked about above.

On a Linux system, the executable file for the Horizon Shopper is located at /usr/bin/vmware-view. Getting into VMware-view -h reveals that it has A lot of The identical options As a Outcome of it does on a House windows system. However, A pair of of the switches are barely completely different and the arguments to the switches are prefaced with a double dash with an equal signal connecting them, as proven right here:.

[Click on on picture for huger view.]

To look at connecting to a Horizon deskprime from a Linux deskprime, I entered The subsequent:

/usr/bin/vmware-view  --deskprimeName=Hrz8ICPA [e-mail protected] --password=nope --deskprimeSize=huge --serverURL=10.0.0.61 --screens=1 --nonInterlively --unauthenticatioedAcccessEnabled=TRUE &

After entering the command, I used to be related to a Horizon deskprime. The “&” On The prime of the command ran The tactic in the background so I might run completely different instructions from the command line.

To kill the job, I entered: kill %%.

Subsequent, I needed To have The power to start the session from an distant connection that I SSH’ed to the machine. To Do this, I entered xhost + on the command line on the GUI, then I appfinished –current=:0.0 to it to have it start on graphics current. The complete command is:

/usr/bin/vmware-view  --deskprimeName=Hrz8ICPA [e-mail protected] --password=nope --deskprimeSize=huge --serverURL=10.0.0.61 --screens=1 --nonInterlively --unauthenticatioedAccessEnabled=TRUE --current=:0.0 &

The complete level of me doing this was to show the monitoring Computer software I needed So as to have an lively deskprime On A daily basis working. To imitate a consumer logging off and reconnecting, I created The subsequent Bash script:

#!/bin/bash
## This script will run a horizon deskprime indefinitely 
## Whether or not It is run distantly xhost + Have to be run on the GUI
wright hereas true
do
        ## Start a Horizon session in the background 
        /usr/bin/vmware-view  --deskprimeName=Hrz8ICPA [e-mail protected] 
        --password=nope --deskprimeSize=huge --serverURL=10.0.0.61 --screens=1 
        --nonInterlively --unauthenticatioedAccessEnabled=TRUE --current=:0.0 &
        ## restart the session every 4 hours
        sleep 14400
        pkill -u root vmware-view
        sleep 60
carried out

Whether or not You use the vmware-view command in a .bat file on a House windows machine to instantiate a connection to a Horizon deskprime or software with a single click, or use it in a Linux Bash script, I am constructive You uncover this to be A useful gizmo.

Regarding the Author


Tom Fenton has a wealth of palms-on IT expertise gained over the previous 25 years in Pretty a Little bit of utilized sciences, with the previous 15 years Specializing in virtualization and storage. He presently works as a Technical Advertising Supervisor for ControlUp. He beforehand labored at VMware as a Senior Course Developer, Options Engineer, and in the Aggressive Advertising group. He has furtherly labored as a Senior Validation Engineer with The Taneja Group, wright here he headed the Validation Service Lab and was instrumental in Beginning its vSpright here Digital Volumes apply. He is on Twitter @vDoppler.

Source: https://virtualizationreview.com/articles/2021/11/05/horizon-linux.aspx

Related Posts