Avengers FP3 Linux VDA 1.1 with CentOS 6.7
Hands-on-Lab Guide
Worldwide Product Readiness
October 2015
Prepared by: Insert Author or Team name here
Authors
The following authors contributed to the creation of this deliverable.
Citrix
Mike Palmer
Phone: (954) 802-1227
email: mike.palmer@citrix.com
Revision History
Revision
Change Description
Updated By
Date
1.0
First Edition
Mike Palmer
10/26/2015
citrix.com
2
Table of Contents
Table of Contents ......................................................................................................... 3
Training Overview ........................................................................................................ 4
Lab Environment Details .............................................................................................. 5
Lab Scenario ................................................................................................................ 6
Lab Preparation ............................................................................................................ 7
Module1: The Linux VDA ............................................................................ 8
Exercise 1: Create and Configure CentOS VM .......................................................... 10
Exercise 2: Preparing the CentOS VM prior to VDA install ........................................ 18
Exercise 3: Install the Linux VDA ............................................................................... 28
Exercise 4: Duplicating a Linux VDA VM.................................................................... 33
Exercise 5: Configure the XD site for the Linux VDA ................................................. 39
Exercise 6: The Hosted Shared Desktop Delivery Model ........................................... 41
Exercise 7: The VDI Dedicated Desktop Delivery Model ............................................ 51
Lab Guide Appendix ................................................................................. 59
Appendix A: Bonus Exercises .................................................................................... 60
Appendix B: Lab Reset............................................................................................... 61
Appendix C: Additional Resources and Information ................................................... 62
citrix.com
3
Training Overview
Objective
This training will provide hands-on experience with the XenDesktop Features Pack 3 Linux VDA, from
creating the initial CentOS 6.7 Linux VM, through installing the pre-requisites, to installing the Linux VDA.
The process of creating duplicates of the fully configured Linux VDA is covered along with creating
XenDesktop Machine Groups and Delivery groups that deploy the Linux VDA.
Required Prerequisites
The user needs limited familiarity with the Linux vi text editor.
Optional Prerequisites
n/a
Audience
Target
Citrix Internal Sales Engineers
Citrix Internal Consultants
Citrix Internal Technical Support
Citrix Partners
Citrix Customers
Lab Guide Conventions
Indicator Purpose
This symbol indicates particular attention must be paid to this step
Special note to offer advice or background information
Reboot
Text the student enters or an item they select is printed like this
Start
Bold text indicates reference to a button or object
Focuses attention on a particular part of the screen (R:255 G:20 B:147)
Shows where to click or select an item on a screenshot (R:255 G:102 B:0)
citrix.com
4
Lab Environment Details
Each student has a dedicated XenServer which hosts all VMs in this lab. The VMs share a common
192.168.10.xxx internal network. The student accesses the environment via ICA to the Student Desktop.
Virtual Machines
VM Name
IP Address
Description
AD.training.lab
192.168.10.11
Domain Controller, DNS, DHCP, Certificate Services
DC1
192.168.10.21
XenDesktop Delivery Controller 7.6
SQL1
192.168.10.12
Microsoft SQL 2014
SF1
192.168.10.31
Citrix StoreFront 2.6
Studio
DHCP
Citrix Studio
Win7
DHCP
Windows 7 VDA
Win81
DHCP
Windows 81 VDA
centos-master
DHCP
Centos 6.7 VDA
centos-vda01
DHCP
Centos 6.7 VDA
centos-vda02
DHCP
Centos 6.7 VDA
Credentials
User Name
Password
Description
Training\Administrator
Citrix123
Windows training.lab Domain Administrator
Training\User1
Citrix123
Standard User
Training\User2
Citrix123
Standard User
Training\HelpDesk1
Citrix123
Helpdesk Administrator
root
Citrix123
Linux VM Login
citrix.com
5
Lab Scenario
You have a XenDesktop site already built and wish to integrate the new Linux VDA into the site to allow
users the option of running Linux CentOS Desktops. You will evaluate running the desktops as Shared
Server Hosted Desktops and as dedicated Virtual Desktops (VDI).
citrix.com
6
Lab Preparation
XenCenter is a graphical user interface application used for managing one or more XenServers.
You will be using XenCenter to manage the XenServer needed for the lab. After launching the
lab, the following steps show you how to attach to your XenServer.
Step
1.
Action
Citrix XenCenter should launch automatically on the Student Desktop. If not, launch
using the desktop shortcut.
2.
Click Add Server to add your XenServer to XenCenter.
3.
Enter the parameters shown below:
IP Address
Username
Password
192.168.10.5
hypervisoradmin
Password1!
You can ignore the user
credentials presented when
you launched the lab.
Click Add.
4.
Your XenServer name
will be different.
XenCenter will attach to your XenServer. You will see your running VMs.
citrix.com
7
Module1: The Linux VDA
citrix.com
8
Module Overview
Citrix has been a pioneer over the last 25 years, leading the Windows App and Desktop delivery
with XenApp and XenDesktop. In the current era of app proliferation, the need for secure,
mobile, and high-performance delivery of Linux apps and desktop has become ever more so
important. Customers consider Citrix as a natural choice for supporting virtualization of Linux
apps and desktop in their IT strategy. For some, Linux Virtual Desktop is a natural extension of
their XenApp and XenDesktop infrastructure to include Linux, and for others it is their first step
towards virtualization.
Many of the requirements around Linux applications relate to mission-critical research and
development work that includes chip design, high-performance computing projects, numerical
computation done in financial and scientific modeling, big data analysis and engineering tools.
In addition, Citrix customers are asking for virtual desktop support for specialized applications
built exclusively for Linux, particularly in the oil and gas industry, manufacturing, digital media,
and entertainment industries. These customers need to offer secure, global access to
employees using a wide variety of mobile and desktop devices, while maintain centralized
control of business-critical intellectual property.
In this module you will create a CentOS Linux VM, install the prerequisites necessary to run the
Linux VDA and configure them ready to have the Linux VDA installed. You will then install the
Linux VDA to create a master template. This template will then be cloned to create two Linux
VDAs, one used as a Server OS and another configured as a VDI. You will then build two
XenDesktop Machine Catalogs and two Delivery Groups and show how the Linux VDAs are
accessed.
citrix.com
Exercise 1: Create and Configure CentOS VM
Overview
The Linux VDA installs on either a Suse, RedHat or CentOS VM. (Note: CentOS is not officially
supported by Citrix, but is a free option and works fine for the lab.)
You will install and configure a CentOS 6.7 VM that will be used to provide Linux desktops. It
should be noted that it is not necessary to have the Linux VM running with a GUI desktop during
configuration and the install of the Linux VDA. In fact, the only time you will see the GUI
desktop is when launched through XenDesktop.
In this exercise you will:

Create a VM on your physical XenServer.

Install the CentOS 6.7 operating system on to it.

Configure the networking to be operational.
Estimated time to complete this exercise: 15 Minutes
Step by Step Guidance
Step
Action
5.
Using XenCenter, click the New VM button.
6.
Select the Centos 6 (64-bit) template and click Next.
7.
Linux is case sensitive; use all
lower case for the VM name
Enter the name centos-master for the VM and click Next.
citrix.com
Step
Action
8.
Using the selector choose to install from the “CentOS-6.7-x86_64-bin-DVD1.iso”. This is
the standard CentOS install DVD available from any repository.
Leave the advanced boot parameters and click Next.
9.
Check Don’t assign this VM to a home server.
Click Next.
10.
Leave the following defaults on the next two screens (click Next on each screen):
11.
The virtual network interfaces you see on your XenServer may vary from those shown
above. You only need to keep the “Internal” network which should always be available.
Delete any other networks you see, such as Private bond0 and Private bond1. Click the
networks you want to delete, e.g. Private Bond 0, and click Delete.
12.
Ensure you have just the Internal network and click Next.
citrix.com
Step
Action
13.
Review the summary (your Home Server name will be different) and click Create Now.
14.
In a few seconds the VM is created. Select the Console Tab of the centos-master
node.
15.
Using the keyboard <Tab> key select Skip and press <Enter>.
16.
Wait a few moments for the following screen to appear:
Press <Enter>.
17.
Keep the language selection on English. Use the <Tab> key to select OK and then
press <Enter>.
citrix.com
Step
Action
18.
Use the <Tab> key to select Re-initialize and then press <Enter>.
19.
Keep the time zone on America/NewYork. Use the <Tab> key to select OK and then
press <Enter>.
20.
Enter the root password twice:
Password:
Password (confirm):
Citrix123
Citrix123
Passwords are case sensitive.
Use the <Tab> key to select OK and then press <Enter>.
citrix.com
Step
Action
21.
Use the <Tab> key to select OK and then press <Enter>.
22.
Use the <Tab> key to select Write changes to disk and then press <Enter>.
23.
After about three minutes you should see your base installation is complete.
Press <Enter> to reboot.
24.
After the reboot, you should see the login prompt.
CentOS 6.7 has been installed on the centos-master VM.
25.
Login to the centos-master console using the credentials:
Username
Password
26.
citrix.com
root
Citrix123
User names and passwords are case sensitive.
Using the DVD Drive 1 selector choose xs-tools.iso (its right at the bottom of the list).
Step
27.
Action
The XenServer Tools are software packages for Windows and Linux-based guest
operating systems. The Tools include high-performance disk and network
paravirtualized drivers (PV drivers) for Windows operating systems, and a Guest Agent
for Linux-based operating systems that provides additional information about the VM to
the XenServer host.
To install XenServer tools enter the following commands on the console:
mount -r /dev/xvdd /mnt
/mnt/Linux/install.sh
Answer y to the prompt.
To complete the installation, reboot the VM by entering the following command:
reboot
28.
Wait until the VM is in the process of restarting and then click Eject to remove the
XenServer Tools DVD from the DVD drive. Ejecting a DVD when you no longer need it
is a XenServer best practice.
The DVD drive should say <empty>.
29.
Login to the console using the credentials:
Username
Password
citrix.com
root
Citrix123
Step
30.
Action
The internal network specified when creating the VM is attached to the first NIC of the
VM, which in Linux is referred to as “eth0”.
“eth0” has a configuration file that by default puts the device off-line. You will edit the
configuration file to enable the device on booting. This file is also used to specify if the
device gets a static IP, or in this case an IP allocated by DHCP.
Enter the Command:
vi /etc/sysconfig/network-scripts/ifcfg-eth0
Change the following line:
ONBOOT=no
ONBOOT=yes
After editing, the file should look like this (your HWADDR and UUID values will be
different)
DEVICE=eth0
HWADDR=A6:94:40:5C:10:13
TYPE=Ethernet
UUID=47cceaa0-a95a-4f53-86d1-48fe990f24dd
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=dhcp
~
Save the file and exit the editor by entering <ESC>:wq
31.
The /etc/sysconfig/network file is used to specify information about the desired network
configuration.
Enter the command:
vi /etc/sysconfig/network
Change the hostname
HOSTNAME=centos-master
After editing the file should look like:
NETWORKING=yes
HOSTNAME=centos-master
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Step
32.
Action
The hosts file is a text file that associates IP addresses with hostnames, one line per IP
address.
Enter the command:
vi /etc/hosts
Modify the lines containing loopback addresses so that they list the FQDN, hostname
and ‘localhost’ as shown below.
127.0.0.1
::1
centos-master.training.lab centos-master localhost
centos-master.training.lab centos-master localhost
Save the file and exit the editor by entering <ESC>:wq
33.
Set the current hostname and then restart the network service:
hostname centos-master
service network restart
34.
Verify the FQDN is reported correctly and the network is operational.
hostname -f
ping -c2 google.com
Key Takeaways
The default CentOS 6 XenServer template is a Command Line install and the network is not
automatically configured. The network configuration must be done manually by the admin.
citrix.com
Exercise 2: Preparing the CentOS VM prior to VDA install
Overview
The Linux VDA install requires several pre-requisites (pre-installed software), and configuration
of the host VM, including installing (but not running) a desktop environment. These are
accomplished in this exercise.
In this exercise you will:

Update the Linux VM to the latest version of the software

Install the tools and packages needed for the VDA install

Install a desktop environment on the VM

Configure the VM to authenticate users to the domain Active Directory
Estimated time to complete this exercise: 20 Minutes
Step by Step Guidance
Step
1.
Action
If necessary, login to the centos-master VM console using the credentials:
Username
Password
2.
root
Citrix123
You must now ensure the VM is running the latest versions of all software.
Enter the command:
yum -y update
The process takes approximately two minutes.
The updates applied may
change over time due to the
addition of new updates.
citrix.com
Step
3.
Action
You now will install the tools needed to complete the Linux VDA install. Enter the
command (this is all one command over 8 lines):
yum -y install lokkit \
ntp \
cifs-utils \
samba-winbind \
krb5-workstation \
authconfig \
pam_krb5 \
oddjob-mkhomedir
The process takes only a few seconds.
Take care when entering long commands. You may wish to copy / paste the command into
the console (right-click/paste) to improve accuracy.
4.
When using the Linux VDA, PostgreSQL takes the place of the Windows registry to
store settings. You will install PostgreSQL now.
Enter the command:
yum -y install java-1.7.0-openjdk \
postgresql \
postgresql-server \
postgresql-jdbc
The process takes approximately 30 seconds.
citrix.com
Step
5.
Action
Initialize and start the postgresql database service by entering the following commands:
service postgresql initdb
service postgresql start
chkconfig --level 35 postgresql on
Check you output matches that above.
6.
You can confirm that PostgreSQL database initialized successfully by querying the data
directory. Enter the command:
sudo -u postgres psql -c 'show data_directory'
Ignore the “could not change directory” error; what is important is the data directory is
shown.
7.
Finally, we need to install a desktop environment on the VM since the CentOS and
RHEL 6 templates in XenServer are designed as lightweight servers and do not come
with a desktop by default.
Enter the command:
yum -y groupinstall "Desktop" \
"Desktop Platform" \
"Fonts" \
"General Purpose Desktop" \
"X Window System" \
"Internet Browser"
The process takes approximately five minutes.
8.
Reboot the VM by entering the command:
reboot
citrix.com
Step
Action
9.
After reboot you will be asked to choose a configuration tool. You don’t need one, so
use the keyboard <TAB> key to select Quit and press <Enter>.
The boot process continues.
10.
Login to the console using the credentials:
Username
Password
11.
root
Citrix123
Enable the firewall using the following command:
lokkit --enabled
12.
Network Time Protocol (NTP) is a networking protocol for clock synchronization
between computer systems over packet-switched, variable-latency data networks.
You now need to configure NTP. An NTP server is already setup on the Domain
Controller AD.training.lab.
Edit the NTP configuration file using the following command:
vi /etc/ntp.conf
Change the lines:
server
server
server
server
0.centos.pool.ntp.org
1.centos.pool.ntp.org
2.centos.pool.ntp.org
3.centos.pool.ntp.org
iburst
iburst
iburst
iburst
To
Delete three lines and change
the remaining line.
server ad.training.lab iburst
# Use public servers from the pool.ntp.org project.
# Please consider joining the pool (http://www.pool.ntp.org/join.html).
server ad.training.lab iburst
#broadcast 192.168.1.255 autokey# broadcast server
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Step
13.
Action
Start the NTP service and set it to start on boot with the following commands:
service ntpd start
chkconfig ntpd on
14.
The VM needs to be joined to the domain. Execute the following single command that
will take care of the majority of the configuration steps needed to authenticate domain
users via Winbind (it doesn’t actually do the domain join, that comes later):
authconfig \
--disablecache \
--enablewinbind \
--enablewinbindauth \
--smbsecurity=ads \
--smbworkgroup=TRAINING \
--smbrealm=TRAINING.LAB \
--winbindtemplatehomedir=/home/%D/%U \
--winbindtemplateshell=/bin/bash \
--enablekrb5 \
--krb5realm=TRAINING.LAB \
--krb5kdc=ad.training.lab \
--krb5adminserver=ad.training.lab \
--enablekrb5kdcdns \
--enablekrb5realmdns \
--enablelocauthorize \
--enablemkhomedir \
--enablepamaccess \
--updateall
This is one single command spread across many lines on the console. It is important to
enter this command accurately and therefore it’s highly recommended to copy and paste
the command into the console (right-click/paste).
citrix.com
Step
15.
Action
Winbind is a component of the Samba suite of programs that solves the unified logon
problem. Winbind uses a UNIX implementation of Microsoft RPC calls, Pluggable
Authentication Modules (PAMs), and the name service switch (NSS) to allow Windows
NT domain users to appear and operate as UNIX users on a UNIX machine.
By default, Winbind will not create the system keytab file, which Kerberos tools will need
to authenticate the machine account.
Edit the samba configuration file with the following command:
vi /etc/samba/smb.conf
Scroll down to the end of the [Global] section and insert the following two lines after the
“#--authconfig--end-line--“ line:
kerberos method = secrets and keytab
winbind refresh tickets = true
global]
#--authconfig--start-line-# Generated by authconfig on 2015/10/21 10:16:19
# DO NOT EDIT THIS SECTION (delimited by --start-line--/--end-line--)
# Any modification may be deleted or altered by authconfig in future
workgroup = TRAINING
realm = TRAINING.LAB
security = ads
idmap config * : range = 16777216-33554431
template homedir = /home/%D/%U
template shell = /bin/bash
winbind use default domain = false
winbind offline logon = false
#--authconfig--end-line-kerberos method = secrets and keytab
winbind refresh tickets = true
# ----------------------- Network Related Options -------------------------
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Step
16.
Action
Linux Pluggable Authentication Modules (PAM) provide dynamic authentication support
for applications and services in a Linux system. PAM needs to be configured to enable
Kerberos ticket caching and creation of home directories for Winbind.
Enter the command:
vi /etc/security/pam_winbind.conf
Modify the three lines below, making sure to uncomment them (remove any leading
semicolons) in the process:
krb5_auth = yes
krb5_ccache_type = FILE
mkhomedir = yes
# authenticate using kerberos
krb5_auth = yes
# when using kerberos, request a "FILE" krb5 credential cache type
# (leave empty to just do krb5 authentication but not have a ticket
# afterwards)
krb5_ccache_type = FILE
# make successful authentication dependend on membership of one SID
# (can also take a name)
;require_membership_of =
# password expiry warning period in days
;warn_pwd_expire = 14
# omit pam conversations
;silent = no
# create homedirectory on the fly
mkhomedir = yes
Save the file and exit the editor by entering <ESC>:wq
17.
You are ready to join the domain by entering the following command:
net ads join -w training.lab -S ad.training.lab -U Administrator
Enter the Administrators password:
Password
Citrix123
Verify you have successfully joined the training.lab domain.
citrix.com
Step
18.
Action
Confirm centos-master has joined the training domain in AD.
Double-click the AD RDP shortcut and log on if necessary using the following
credentials:
Username
Password
Training\administrator
Citrix123
Answer No to a network search question.
Click the Windows Start Icon
and click Administrative Tools
, then
Double-Click Active Directory Users and Computers.
Notice the centos-master is now shown in the list of AD computers. You can now close
the AD VM window.
19.
Start Winbind and make sure it is set to start on boot:
service winbind start
chkconfig winbind on
citrix.com
Step
20.
Action
The most common issues encountered from this point onwards are all related to domain
authentication, so it is important to verify that the previous steps were successful before
moving on.
It’s worth noting that domain authentication for users and the machine itself work via
different mechanisms, making it possible for one to succeed even while the other is
failing (e.g. domain users may be able to log on to a machine that failed to successfully
join the domain itself.)
Firstly verify that the domain join by entering the following command:
net ads testjoin
Verify the domain join is “OK”.
21.
Verify that the keytab file has been created and contains valid keys by entering the
following command:
klist -ke
Verify you see outout similar to that shown above.
22.
Verify that the machine can authenticate with the domain controller and that a TGT
ticket is being cached by entering the following commands:
kinit -k CENTOS-MASTER\$@TRAINING.LAB
klist
Note all caps for VM
name and domain.
The machine has authenticated and a TGT ticket is being cached (with an expiration
date & time).
citrix.com
Step
23.
Action
Verify that domain users can authenticate with the domain:
wbinfo --krb5auth=training\\user1
Enter the user1 password:
Password
Citrix123
Verify the authentication succeeds.
24.
Finally to test domain user authentication, you will log off and attempt to login as a
domain user. Enter the command:
exit
25.
Log in to the console using the credentials:
Username
Password
training\user2
Citrix123
Ensure you can log in as a domain user.
26.
You will need the IP address of your centos-master server for the next exercise. Enter
the command:
ifconfig
The IP address is shown on the second line. Your address may be different. Make a
note of it for later.
Key Takeaways
Unlike the Windows VDA, the Linux VDA requires a number of prerequisites to be installed
manually and configuration of the CentOS VM prior to install.
When using the Linux VDA, PostgreSQL takes the place of the Windows registry to store
settings.
You have connected the VM to the training.lab domain using the Winbind service.
citrix.com
Exercise 3: Install the Linux VDA
Overview
The Linux VDA is installed as an “rpm” package. It may be downloaded from Citrix.com and
transferred to centos-master using the WinSCP application. For your convenience the correct
package has been placed in the download directory of the student desktop.
In this exercise you will:

Copy the Linux VDA install rpm file to the centos-master VM.

Execute the Linux VDA install on centos-master

Configure the Linux VDA and verify the VDA and HDX and services are running.
Estimated time to complete this exercise: 15 Minutes
Step by Step Guidance
Step
1.
Action
Move to the Student Desktop. You will find the CentOS 6 VDA install package in the
download directory. To transfer it to the centos-master, you will use WinSCP.
Launch WinSCP from the student Desktop.
2.
Enter the following:
Hostname
Username
Password
Click Login.
citrix.com
192.168.10.109
root
Citrix123
Use the IP address obtained at
the end of exercise 2.
Step
Action
3.
If you see the Host Key Mismatch warning, click Update.
4.
Navigate the left-side of WinSCP to c:\Users\localuser\Downloads. Notice the presence
of the Linux VDA install TGZ (Gzipped Tar) file.
5.
Navigate the right-side of WinSCP to /<root>.
6.
With the right-side selected, press F7 on the keyboard to create a new folder. Enter the
name:
New Folder Name
citrix.com
LinuxVDA
Step
Action
7.
Drag and drop the LinuxVDA install TGZ file from the left-side to the LinuxVDA folder on
the right-side.
You can now close the WinSCP window (confirm terminating session).
8.
Move back to the centos-master console on XenCenter. If you are still logged in as
user2, exit and login using the following credentials:
Username
Password
9.
root
Citrix123
To install the Linux VDA file the Linux VDA file must be decompressed and the files
extracted from the TAR archive. This is accomplished by entering the following
commands:
cd /LinuxVDA
tar -xzvf citrix-linuxvda-rhel6-1.1.0.tgz
10.
The Linux VDA is now ready for install using the following command (this will also pull in
the last few package dependencies):
yum -y install XenDesktopVDA-1.1.0.240-0.x86_64.rpm
11.
The final step is to configure the VDA with the following command:
ctxsetup.sh
citrix.com
Step
Action
Enter the following responses to the questions:
12.
Allow DDC names to be specified via CNAMEs?
Please provide the FQDN of at least one DDC:
Enter the TCP/IP port the Virtual Delivery Agent service
should use to register with the Delivery Controller
Register service so that XDL starts on boot?
Add firewall exceptions to allow incoming XDL
connections?
What AD integration tool does this system use?
1: Winbind
2: Quest
Start XDL service once configuration is complete?
n
dc1.training.lab
80
y
Y
1
y
Once the script is complete the HDX and VDA services will have been configured and
started, confirm the services are running with the following commands:
13.
service ctxhdx status
service ctxvda status
There is a specific Centos/RedHat 6 issue that causes users to receive a popup asking
for the root password after logging on to the desktop. For more information on this issue,
see https://access.redhat.com/solutions/195833.
14.
To resolve this issue enter the following command:
vi /etc/polkit-1/localauthority/30-site.d/20-no-show-proxy-dialog.pkla
You should see an empty file.
15.
A
Insert
the following lines into the file:
[No Show Proxy Dialog]
Identity=unix-user:*
Action=org.freedesktop.packagekit.system-network-proxy-configure
ResultAny=no
ResultInactive=no
ResultActive=no
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Key Takeaways
Once the pre-requisites and configuration were taken care of in the previous exercise, installing and
configuring the Citrix Linux VDA is straightforward
citrix.com
Exercise 4: Duplicating a Linux VDA VM
Overview
Currently the Linux VDA is not compatible with either Citrix Machine Creation Services (MCS) or Citrix
provisioning Services (PVS).
Therefore, creating multiple copies of the VDA VMs must be done manually (though this could be
scripted). This exercise goes through the process of duplicating a CentOS VDA.
In this exercise you will:

Create a master template of the Linux VDA

Create two copies from the master.
Estimated time to complete this exercise: 20 Minutes
Step by Step Guidance
Step
1.
Action
If necessary, log on into the centos-master VM console using the credentials:
Username
Password
2.
root
Citrix123
Copies cannot be made while the VDA is a member of the Windows domain.
Type the following command to leave the training.lab domain:
net ads leave -w training.lab -S ad.training.lab -U Administrator
Enter the Password:
Password
citrix.com
Citrix123
Step
3.
Action
By default the “eth0” network configuration file includes the hardware (MAC) address of
the NIC and UUID of the interface. In copying the VM these lines would need updating
with the new values of the copy VM. Fortunately these parameters are not required for
operation in the lab, so you can safely delete these lines.
Enter the command:
vi /etc/sysconfig/network-scripts/ifcfg-eth0
Delete the lines starting with:
HWADDR
UUID
The file should look like:
DEVICE=eth0
TYPE=Ethernet
ONBOOT=yes
NM_CONTROLLED=yes
BOOTPROTO=dhcp
Save the file and exit the editor by entering <ESC>:wq
4.
You can now create a template out of centos-master.
Right-click the centos-master node in XenCenter and select Shutdown. Click Yes to
confirm the shutdown.
5.
Once the shutdown is complete, right-click the centos-master node again and select
Convert to Template. Click Convert to confirm.
6.
Right-click the new centos-master template just created, and select Quick Create.
citrix.com
Step
Action
7.
Once you see the newly created VM centos-master (1) in XenCenter, right-click the
node and select Properties.
8.
Change the name of the VM to centos-vda01 and click OK. (This has just changed the
name in XenServer.)
9.
Click the Console tab of the centos-vda01 node.
10.
Log on to the centos-vda01 VM console using the credentials:
Username
Password
11.
root
Citrix123
You must now change the hostname of the VM.
Enter the command:
vi /etc/sysconfig/network
Change the hostname to centos-vda01
HOSTNAME=centos-vda01
NETWORKING=yes
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Step
12.
Action
Enter the command:
vi /etc/hosts
Change the two lines to look like:
127.0.0.1
::1
centos-vda01.training.lab centos-vda01 localhost
centos-vda01.training.lab centos-vda01 localhost
Save the file and exit the editor by entering <ESC>:wq
You can use the following vi command to change all hostnames in the file simultaneously:
13.
Enter the command:
reboot
14.
After the reboot, notice the hostname is now centos-vda01.
Log on to the centos-vda01 VM console using the credentials:
Username
Password
15.
root
Citrix123
Type the following command to join the VM to the training.lab domain:
net ads join -w training.lab -S ad.training.lab -U Administrator
Enter the Password:
Password
16.
Citrix123
Start the Winbind service.
service winbind start
citrix.com
Step
17.
Action
Your centos-vda01 is now ready for use. You will now repeat the process to create
another Linux VDA copy.
Right-click the centos-master template and select Quick Create
18.
Right-click the newly created VM centos-master (1) and select Properties.
19.
Change the name of the VM to centos-vda02 and click OK.
20.
Click the Console tab of the centos-vda02 node.
21.
Log on to the centos-vda02 VM console using the credentials:
Username
Password
22.
root
Citrix123
You must now change the hostname of the VM.
Enter the command:
vi /etc/sysconfig/network
Change the hostname to centos-vda02
HOSTNAME=centos-vda02
NETWORKING=yes
Save the file and exit the editor by entering <ESC>:wq
citrix.com
Step
23.
Action
Enter the command:
vi /etc/hosts
Change the two lines to look like:
127.0.0.1
::1
centos-vda02.training.lab centos-vda02 localhost
centos-vda02.training.lab centos-vda02 localhost
Save the file and exit the editor by entering <ESC>:wq
24.
Enter the command:
reboot
25.
Log on to the centos-vda02 VM console using the credentials:
Username
Password
26.
root
Citrix123
Type the following command to join the VM to the training.lab domain:
net ads join -w training.lab -S ad.training.lab -U Administrator
Enter the Password:
Password
27.
Citrix123
Start Winbind.
service winbind start
Key Takeaways
The Linux VDA is not compatible with either Citrix Machine Creation Services (MCS) or Citrix provisioning
Services (PVS). However a Linux VDA can be copied quite easily in a few steps. You now have two
Linux VDAs ready to be used with XenDesktop.
citrix.com
Exercise 5: Configure the XD site for the Linux VDA
Overview
This lab already has a pre-configured XenDesktop 7.6 site that will be used to test the Linux
Desktop publishing.
All Delivery Controllers of the XenDesktop site require an updates to work with the Linux VDA.
A PowerShell script is used to perform the update. Your site only has one Delivery Controller,
DC1.
In this exercise you will:

Use the UpdateBrokerServiceConfig PowerShell script to update the XenDesktop
Delivery Controller (DC1).
Estimated time to complete this exercise: 5 Minutes
Step by Step Guidance
Step
Action
1.
Your Delivery Controller will require a change to the Broker service configuration before
it will be capable of brokering sessions to Linux VDAs.
Using XenCenter, select the console of the DC1 node and click the Switch to Remote
Desktop button (the button may take a few seconds to be active.)
2.
Login to the console using the credentials:
Username
Password
Training\administrator
Citrix123
3.
Click the PowerShell button at the bottom of the desktop.
citrix.com
Step
Action
4.
A PowerShell script named UpdateBrokerServiceConfig.ps1, must be run on each and
every Delivery Controller in the site. The script is obtainable from Citrix.com and to save
time, has already been downloaded for you and placed in the administrator’s downloads
directory of DC1.
To update your DC1 controller to allow the deployment of Linux desktops, enter the
following command:
.\downloads\Update-BrokerServiceConfig.ps1
When prompted answer R
This completes the controller update.
Key Takeaways
Each XenDesktop 7.6 Delivery Controller must be updated to broker the Linux VDA.
citrix.com
Exercise 6: The Hosted Shared Desktop Delivery Model
Overview
With a Hosted Shared Desktop users get a desktop interface, however, that desktop is actually
being shared by every user on the server. In essence there are many users to one desktop.
The Linux VDA is configured for Hosted Shared Desktop delivery model by default. To test the
Linux VDA you will publish the CentOS desktop in your XenDesktop site.
In this exercise you will:

Create a Machine Catalog using the centos-vda01 VM as a template

Create a Delivery Group using the CentOS-VDA Machine Catalog

Connect to Storefront and launch the Linux Desktop
Estimated time to complete this exercise: 20 Minutes
Step by Step Guidance
Step
1.
Action
On the Student Desktop launch the RDP connection to the Citrix Studio VM.
2.
On the Citrix Studio VM desktop, double-click to launch Citrix studio.
3.
On the left side of Studio select the Machine Catalogs node.
citrix.com
Step
Action
4.
Then select Create Machine Catalog on the right.
5.
Select Windows Server OS as the OS for this Machine Catalog (Studio has not yet been
updated to add the Linux OS options) and click Next.
6.
Select Machines that are not power managed and click Next.
7.
Click Add Computers.
citrix.com
Step
Action
8.
Type cent in the object names to select window and click Check Names.
9.
You will see the two VDAs you created from the master. Click centos-vda01 and click
OK.
10.
You should see centos-vda01 selected. Click OK.
11.
The centos-vda01 is added to the Machine Catalog.
Click Next.
citrix.com
Step
12.
Action
Enter the Machine Catalog name:
Machine Catalog name
CentOS Server OS
Click Finish.
13.
The CentOS Server OS machine Catalog is created with one machine. Double-click the
highlighted Machine Group to see the machines in the group.
14.
You should see the centos-vda01 machine has been registered as a Server OS
machine.
15.
On the left side of Studio select the Delivery groups node.
16.
On the right, select Create Delivery Group.
citrix.com
Step
Action
17.
Click Next.
18.
Increment the number of machine’s to use for this delivery group to 1 and click Next.
19.
You will be offering CentOS desktops, so keep Desktops selected and click Next. (The
Linux VDA is unable to deliver Applications.)
citrix.com
Step
Action
20.
Click Add to add authorized users.
21.
Enter Domain Users in the object names to select box and click Check Names.
22.
Domain Users is underlined to show the object has been found. Click OK.
23.
The Domain Users are added as authorized users of the Delivery Group. Click Next.
citrix.com
Step
Action
24.
Leave Receiver configuration on Manual and click Next.
25.
Enter the following names:
Delivery Group Name:
Display Name:
DG Description
Click Finish.
citrix.com
CentOS Server OS Desktop
CentOS Server OS Desktop
Leave Blank
Step
Action
26.
The Delivery Group is added. Click Refresh (on the right hand side Action menu) every
15 seconds or so, until you see “Unregistered 0”, indicating the Delivery Group
configuration is complete. It might take a couple of minutes.
27.
Launch Google Chrome from the Student Desktop (not your laptop).
28.
Enter the following URL:
URL:
http://sf1/Citrix/AcmeWeb
29.
Receiver is already installed, click Log on.
30.
Log on using the following credentials:
User Name:
Password:
Click Log on.
citrix.com
training\user1
Citrix123
Step
Action
31.
As you only have one desktop option in StoreFront, you should see the CentOS Desktop
for user1 automatically open.
32.
Since the CentOS desktop is Server based, multiple desktops can be opened from the
same server.
Launch Microsoft Internet Explorer from the Student Desktop.
33.
Enter the following URL:
URL:
34.
Log on using the following credentials:
User Name:
Password:
Click Log on.
citrix.com
http://sf1/Citrix/AcmeWeb
training\user2
Citrix123
Step
Action
35.
User2’s CentOS desktop opens. Notice User1’s desktop also remains open.
On User2’s desktop click the Mozilla icon as shown above.
36.
Once Mozilla opens, you can explore the CentOS desktop further if you wish. Once
finished, close the two CentOS desktops and Receivers.
Key Takeaways
Creating a Machine Group and Delivery Group using the Server OS Linux VDA is the same as you would
do for a Windows VDA.
However, the Linux VDA machines cannot currently be power managed and the lack of MCS or PVS
support means each VDA must be created manually.
citrix.com
Exercise 7: The VDI Dedicated Desktop Delivery Model
Overview
With Hosted Virtual Desktops (VDI), each user connects remotely to their own desktop running on its own
Virtual Machine. There is no interaction between the desktops. For instance, a user can install an
application and reboot their own desktop, without affecting other users, whereas this is not possible under
the Hosted Shared desktop model.
The Linux VDA is configured for Hosted Shared desktop delivery model by default, so additional
configuration is required to change this to the VDI dedicated desktop delivery model.
In this exercise you will:

Configure the Linux VDA centos-vda02 to operate in VDI mode.

Create a Machine Group and Delivery Group to deliver a VDI desktop.
Estimated time to complete this exercise: 20 Minutes
Step by Step Guidance
Step
1.
Action
Using XenCenter, access the console of the centos-vda02 node. If necessary, login to
the centos-vda02 VM console using the credentials:
Username
Password
2.
root
Citrix123
To configure the centos-VDA02 VM for the XenDesktop dedicated desktop delivery
model, execute the following command:
sudo /usr/local/bin/ctxreg create \
-k "HKLM/System/CurrentControlSet/Control/Citrix/WinStations/tcp" \
-t "REG_DWORD" \
-v "StackSessionMode" \
-d "0" \
--force
citrix.com
51
Step
3.
Action
To register the change to a VDI type machine, you need to restart Citrix Linux VDA
services by entering the following commands:
service ctxvda stop
service ctxhdx restart
service ctxvda start
4.
Return to Citrix Studio and create a second Machine Catalog by Selecting Machine
Catalogs on the left and then Create Machine Catalog on the right.
This time select Windows Desktop OS.
Click Next.
5.
Select Machines that are not power managed.
Click Next.
citrix.com
52
Step
6.
Action
Leave I want users to connect to the same (static) desktop selected (random
desktops are not supported at this time).
Click Next.
7.
Click Add Computers.
8.
Type cent in the object names to select window and click Check Names.
citrix.com
53
Step
Action
9.
You will see the two VDAs created from the master. Click centos-vda02 and click OK.
10.
You should see centos-vda02 selected. Click OK.
11.
The centos-vda02 is added to the Machine Catalog.
Click Next.
12.
Enter the Machine Catalog name:
Machine Catalog name
CentOS VDI
Click Finish.
13.
The CentOS Machine group is added.
Double-click the VDI group to see the machines in the group.
citrix.com
54
Step
Action
14.
You see centos-vda02 has registered in the group.
15.
Click Delivery Groups on the left side and then click Create Delivery Group on the right
side.
16.
Click Next on the Getting Started window.
17.
Increment the number of machine’s to use for this delivery group to 1 and click Next.
18.
Leave Desktops selected as the delivery type and click Next.
citrix.com
55
Step
Action
19.
Add Domain Users as authorized users and click Next.
20.
Leave Receiver configuration on Manual and click Next.
citrix.com
56
Step
21.
Action
Check the summary and enter the following:
Delivery Group Name
Display Name
CentOS VDI
CentOS VDI
Click Finish.
22.
The Delivery Group is added. Click Refresh (on the right hand side Action menu) every
15 seconds or so, until you see “Unregistered 0”, indicating the Delivery Group
configuration is complete. It might take a couple of minutes.
23.
Return to the Chrome browser on the Student Desktop. It probably has timed out due to
inactivity, in which case, click Logon. If not, logoff from receiver.
Log on using the following credentials:
User Name:
Password:
citrix.com
training\user3
Citrix123
57
Step
Action
24.
Notice user3 now has the choice between two desktops, so neither desktop opens
automatically.
Click on the CentOS VDI icon.
25.
Notice the CentOS desktop looks the same as before, but this is a VDI desktop with all
its inherent advantages.
Key Takeaways
The Linux VDA may be configured as a Server OS (many desktops per single VDA) or VDI (one desktop
per VDA).
citrix.com
58
Lab Guide Appendix
citrix.com
59
Appendix A: Bonus Exercises
There are no bonus exercises.
citrix.com
60
Appendix B: Lab Reset
This lab has a built-in reset capability to allow students to quickly skip to any exercise.
The reset points available are:
M1 – The start of the lab
E2 – Ready for exercise 2
E3 – Ready for exercise 3
E4 – Ready for exercise 4
E5 – Ready for exercise 5
E6 – Ready for exercise 6
To use the lab reset capability, launch the command prompt using the cmd short-cut on the Student
Desktop (it’s in the lower right corner fo the desktop).
Note: All existing VMs will be deleted (including any you have created) and the VMs required for the reset
point will be re-created.
Type the command:
labreset reset xx
where xx is either M1, E2, E3, E4, E5 or E6. For example
labreset reset E6
The reset takes approximately two minutes. Note the reset points are case sensitive.
citrix.com
61
Appendix C: Additional Resources and Information
Citrix Linux VDA blogs are a great resource you may wish to browse:
https://www.citrix.com/blogs/category/linux-vda/
citrix.com
62
Appendix D: 2 minutes to vi
Sad for some, but true, vi is the standard editor for the Linux world. Many other more user
friendly editors are available to be installed, but in a non-GUI environment, you typically must
use vi to setup the network to be able to install the other editors!
If you’re working in the Linux world, vi is here to stay, so you might as well get used to it. But if
you’re just dabbling in Linux you can get away with knowing just a handful of vi commands and
leave the fancy stuff for the experts. You can complete this lab with just the following
commands.
vi operates in two modes – Command and Insert.
Command
Keystrokes perform special functions rather than actually inserting text to the document.
Insert
Everything types appears in the document at the place where the blinking cursor is.
To switch to insert mode, you press one of the following characters:
i
A
Insert before the cursor
Append at the end of the line
To switch to Command mode, you press”<Esc>”
To exit from vi, type
:wq <enter>
To Save the file and exit
:q! <enter>
To exit without saving the file (useful when you screw-up!)
Moving Around
When in command mode you can use the arrow keys to move the cursor up, down, left, right.
Deleting
x
citrix.com
Delete current character
dd
Delete current line
63
Appendix E: 10 minute intro to vi
vi was born in 1976 when computer terminals looked like this.
They had no dedicated cursor keys so the h,j,k,l keys served
double duty as cursor movement keys.
If you’ll be working more extensively with Linux, you might
want to take a short course to come up to speed on vi. Once
you get comfortable with it, you will find it is generally faster to
use vi than any other editor, but that familiarity may take
weeks or months! The following is a summary of some of the
most used commands to get you started along the road of
becoming a vi warrior.
vi operates in two modes – Command and Insert.
Command
Keystrokes perform special functions rather than actually inserting text to the document.
Insert
Everything types appears in the document at the place where the blinking cursor is.
To switch to insert mode, you press one of the following characters:
i
Insert before the cursor
I
Insert before line
a
Append after cursor
A
Append after line
o
Open a new line after current line
r
Replace one character
O
Open a new line before current line
R
Replace many characters
To switch to Command mode, you press”<Esc>”
To exit from vi, type
:wq <enter>
To Save the file and exit
:q! <enter>
To exit without saving the file
:w file2 <enter>
To Save the file to a new filename
Moving Around
When in command mode you can use the arrow keys to move the cursor up, down, left, right. In
addition, these keystrokes will move the cursor:
citrix.com
64
h
Left one character
b
Back one word
^B
Back one page
l
Right one character
f
Forward one word
^F
Forward one page
k
Up one line
{
Up one paragraph
3G
Goto line 3
j
Down one line
}
Down one paragraph
G
Goto last Line
0
To the beginning of line
$
To end of the line
Cutting / Copying / Pasting
x
Delete current character
dd
Delete current line
dw
Delete to end of word
24x
Delete 24 characters
4dd
Delete four lines
D
Delete to end of the line
yy
Copy current line
p
Paste after current line
~
Toggle case
3yy
Copy 3 lines
P
Paste before current line
u
Undo last change
Search for strings
/string
Search forward for string
?string
Search backward for string
n
Search for next instance of string
N
Search for previous instance of string
Replace
:s/pattern/string/flags
Replace pattern with string according to flags
g
Flag - Replace all occurrences of pattern
C
Flag - Confirm replaces
&
Repeat last :s command
citrix.com
65
Corporate Headquarters
Fort Lauderdale, FL, USA
India Development Center
Bangalore, India
Silicon Valley Headquarters
Santa Clara, CA, USA
Online Division Headquarters
Santa Barbara, CA, USA
EMEA Headquarters
Schaffhausen, Switzerland
Pacific Headquarters
Hong Kong, China
Latin America Headquarters
Coral Gables, FL, USA
UK Development Center
Chalfont, United Kingdom
About Citrix
Citrix (NASDAQ:CTXS) is a leader in mobile workspaces, providing virtualization, mobility management, networking and cloud services to
enable new ways to work better. Citrix solutions power business mobility through secure, personal workspaces that provide people with
instant access to apps, desktops, data and communications on any device, over any network and cloud. This year Citrix is celebrating 25
years of innovation, making IT simpler and people more productive. With annual revenue in 2013 of $2.9 billion, Citrix solutions are in use
at more than 330,000 organizations and by over 100 million users globally. Learn more at www.citrix.com.
Copyright © 2014 Citrix Systems, Inc. All rights reserved. [list Citrix trademarks (without ® or ™ symbols!) in document] are trademarks of
Citrix Systems, Inc. and/or one of its subsidiaries, and may be registered in the U.S. and other countries. Other product and company names
mentioned herein may be trademarks of their respective companies.
citrix.com
66