Beruflich Dokumente
Kultur Dokumente
Agenda
XenServer Performance Overview
Troubleshooting XenServer Performance
Windows Application Architecture Primer
Troubleshooting Virtual Machine Performance
Citrix Performance VM Demo
Q &A
Performance is
a function of
VM density
XenServer Hardware
Infrastructure, such as network and storage
Workload and sizing demands of the virtual machines
Native XenServer characteristics
App
App
Toolstack
Toolstack
App
App
Guest
Guest OS
OS
netback
netback
netfront
netfront
App
App
App
App
Guest
Guest OS
OS
netfront
netfront
Native
Native
Driver
Driver
Dom0
Dom0
DomU
DomU
Xen
Xen Hypervisor
Hypervisor
Host
Host Machine
Machine (Hardware)
(Hardware)
DomU
DomU
External Factors
Network
Storage
VM Workload and Sizing
6346
352
400
752
MB
xn
328
6 MB
total Dom0
) = memory
DomU
required
+ ( for
= Total
DomU
footprint
for n VMs
for DomU
Total XenServer
for
DomU
Memory
Pool
Dom0 Memory
(ex. 12GB)
752MB allows for about
Pool
60 VMs-per-host
Using XenCenter
# top
Tasks:
Cpu(s):
Mem:
Swap:
68 total,
2 running, 65 sleeping,
0 stopped,
1 zombie
13.0%us, 33.6%sy, 0.0%ni, 1.0%id, 52.5%wa, 0.0%hi, 0.0%si, 0.0%st
417792k total,
302832k used,
114960k free,
68384k buffers
524280k total,
104k used,
524176k free,
80928k cached
PID
12857
4679
5993
1264
4641
4650
12722
USER
65550
root
root
root
root
root
root
PR
15
12
15
16
15
15
15
TIME+
0:00.57
3:47.85
0:24.73
0:24.00
0:01.25
0:00.05
0:00.03
COMMAND
qemu-dm
xapi
stunnel
udevd
xenstored
blktapctrl
top
xentop - 17:24:33
Xen 3.3.1
4 domains: 1 running, 3 blocked, 0 paused, 0 crashed, 0 dying, 0 shutdown
Mem: 12580820k total, 7092880k used, 5487940k free
CPUs: 8 @ 1600MHz
NAME STATE
CPU(sec) CPU(%)
MEM(k) MEM(%) MAXMEM(k) MAXMEM(%) VCPUS NETS ...
Domain-0 -----r
9849
65.5
417792
3.9
no limit
n/a
8
0 ...
Win2K3-01 -----1
1.5
2097020
16.7
2106164
16.7
2
1 ...
Win2K3-02 -----1
4.3
2097020
16.7
2106164
16.7
2
1 ...
Win2K3-03 -----0
9.8
2097020
16.7
2106164
16.7
2
1 ...
Increased the amount of RAM assigned to Dom0 to 2.94GB from the default
752MB; increasing it enabled us to launch more desktop clients.
Increased the Xen-heap setting to take into account the large number of VMs
on this single server host. This was done by adding "xenheap_megabytes=24"
to the Xen command-line in /boot/extlinux.conf which resulted in an increase
from the default of 16MB to 24MB.
Additional Information
# iostat
# hdparm
# dd
# tcpdump
# netstat
# ifconfig
Additional Information
Windows Application
Architecture Primer
Application Basics
An application consists of one or more processes
Each process provides the resources needed to execute a
program
One or more threads run in the context of the process
Each process is started with a single thread, often called the
primary thread, but can create additional threads
Application Basics
A thread is the basic unit to which the operating system
allocates processor time
Threads carry out the work of a process
All threads of a process share its virtual address space and
system resources
Uses stack-based storage for handling data
Application Basics
Thread Stack
Frame 0
Frame 1
Frame 2
Frame 3
Local Variables
Frame Pointer
A closer look
Application Basics
User & Kernel Space
The Windows operating system can be conceptually divided into 2
parts:
User Space (User Mode)
Kernel Space (Kernel Mode)
USER SPACE
USER
USER
USER MODE
APPLICATION
USER
APPLICATION USER
APPLICATION
APPLICATION USER
USER
APPLICATION
USER
APPLICATION USER
APPLICATION
APPLICATION
KERNEL SPACE
rusb2w2k.sys
keyboard.sys
win32k.sys
tcpip.sys
[]
High CPU
Identify offending Thread (s)
Identify the top function call and its module
Capture user memory dump of offending process for
analysis
Engage respective application vendor
ProcessExplorer can be used for live stack-trace viewing!
Looking inside the above testing to see which instructions were being
executed the most during the test was wfica32.exe.
Q&A