华强北电脑城 龙岗电子世界 龙华电脑城  凯尔电脑

 找回密码
 立即注册

QQ登录

只需一步,快速开始

查看: 3211|回复: 0

XenApp6.0 XenApp 6.5 服务器Windows 2008 R2优化

[复制链接]
发表于 2013-11-20 01:33:55 | 显示全部楼层 |阅读模式

Windows 2008 R2建议配置

通用的计算机配置

如下是建议部署在XenApp 6和XenApp6.5 的服务器上面的组策略配置项:

项目路径(计算机配置)理由
Error ReportingAdministrative Templates – Windows Components – Windows Error Reporting5 }( Y. g: _3 z& j
Disable Windows Error Reporting: Enabled
除非排查问题,不然禁用
Disable Customer Experience Improvement Program (CEIP)Administrative Templates – System – Internet Communication Management – Internet Communication Settings1 x3 g. Q% G, W/ n0 J) r
Turn off Windows Customer Experience Improvement Program: Enabled
为减小后台资源消耗,退出微软体验报告回馈
Windows UpdateAdministrative Templates – Windows Components – Windows Updates
+ Z) v! L. }& w3 }+ VConfigure Automatic Updates: Disabled
微软更新应该由管理员更新在桌面模板上面
System RestoreAdministrative templates – System – System Restore
4 h' b& b6 E( a9 b7 uTurn off System Restore: Enabled
系统还原这里就没有必要了
RDP Listener – Printer mappingDisable printer mapping for RDP sessions.
% u2 C0 f7 ~4 g8 o, V6 e6 g, v& FAdministrative Templates – Windows Components – Remote Desktop Services – Remote Desktop Session Host – Printer Redirection
6 m( c8 q0 P  D# nDo not allow client printer redirection: Enabled
打开此策略之后,RDP连接会安装映射的打印机,服务器上安装的打印机驱动会变得不统一,且如果出现异常会增加排查问题的难度
+ A$ T" E# I; F& g3 R" g: v  B2 D

如下注册表配置建议部署在XenApp 6.0 /6.5 服务器上:

项目建议/注册表理由
Hide System Hard Error MessagesHKLM\System\CurrentControlSet\Control\Windows/ u% m+ f- U; u9 v/ ]
“ErrorMode”=dword:00000002
当Windows或者应用出现一个硬件的错误,它会弹出一个对话框ok或者Continue;
这些错误对用户来说是可以隐藏的,如果用户已经断开,弹出的错误可能会导致会话挂起;系统可以将这个错误信息写到系统日志中去。
Spooler Warning EventsHKLM\System\CurrentControlSet\Control\Print\Providers8 b! u' v' q) d! Y8 W+ K
“EventLog”=dword:00000001
当ICA 会话开始时,ICA 自动创建打印机成功或失败的信息会由Spooler服务写到系统事件日志中去,这个服务会产生太多此类日志,这里的配置是让这个服务只记录错误日志。
Paging of the ExecutiveHKLM\System\CurrentControlSet\Control\Session Manager\Memory Management! v) c$ d! C1 G" Y; G; \
“DisablePagingExecutive”=dword:00000001
为了提高性能,内核模式驱动程序和其他系统组件可以被配置为只在内存里做分页。
Edit Run and RunOnce Registry keysHKLM\Software\Microsoft\Windows\CurrentVersion\Run$ S! L/ ?6 b( u
HKLM\Software\Microsoft\Windows\CurrentVersion\RunOnce
6 a1 r/ O: v+ @  _. Z, v7 PHKLM\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\Run
0 r' o+ Q( J$ G( t+ W' R' o0 hHKLM\Software\Wow6432Node\Microsoft\Windows\CurrentVersion\RunOnce
优化开机启动项,这个就不用我多说了,一些无用的例如杀毒,软件的自动更新任务等可以从启动项中删除以优化启动时处理器负担。
Windows Power PlansHigh Performance Power Plan不用多说,将电源设置为最佳性能
BIOS Power Schemes[size=12.727272033691406px]尽可能的选择最大性能方案。这个也不用多说了,BIOS中设置为最大性能
Scheduled TasksVerify the scheduled tasks and randomize execution time.7 v& [/ P, T7 c
Typically the following scheduled tasks can be disabled:8 {, Y. j3 m0 G- x2 q

! W/ C# c! \! I! ?4 k
" M4 w; E8 m' a8 ~0 @5 ~
/ O1 r; A6 D  R/ E; T, z$ v
  • Application Experience -> AitAgent
  • Application Experience -> ProgramDataUpdater
  • Autochk -> Proxy
  • Customer Experience Improvement Program -> everything under this node (Consolidator, KernelCeipTask, UsbCeip, ServerCeipAssistant, ServerRoleCollector, ServerRoleUsageCollector)
  • DiskDiagnostic -> Microsoft-Windows-DiskDiagnosticDataCollector
  • Power Efficiency Diagnostics -> AnalyzeSystem
  • Server Manager -> ServerManager
  • Windows Error Reporting -> QueueReporting
    5 w) B$ `( N- L1 ?
将无用的计划任务取消
Disable Logon ScreensaverHKEY_USERS\.DEFAULT\Control Panel\Desktop
1 f, t6 \9 S& c7 G+ i* M"ScreenSaveActive"="0"
关闭屏幕保护程序
Disabled Boot AnimationDisable
0 h3 ?2 Z4 t" @0 gbcdedit /set bootux disabled
0 ?$ c) i) s, T5 _(需要在Windows 命令行中运行)
禁用启动动画,加速启动过程
Disable all application auto-updatesJava and Flash updates can be controlled via the Control Panel.. N4 s: R5 j) t* d# t" i
SAP updates are disabled in the CCS ADM(X) template.
禁用所有应用的自动更新
Defragmentation运行磁盘碎片整理在制作桌面模板之前运行磁盘整理,或者定期运行磁盘整理;运行磁盘整理时确保不在工作时间运行以免影响用户使用
防病毒软件优化见思杰KB CTX127030
Write Cache (Operating System)
Device Manager -> Disk Drive Properties -> Policies tab
% M6 `1 }; {4 |& E) \
5 V1 m1 v0 D6 b7 s6 A# h
; a- [/ v  F9 t$ I( Q6 A8 C
, X$ e& E4 M  t1 w# y7 v
+ n, B& j7 i' h3 b2 Y" }( p6 C/ }
6 f) H' u4 A% i! R

0 Q% |' ]0 p; b0 p( ^) g8 |: x  ^* [4 X3 i3 ?/ ~" L

7 P) J. ]" {. M6 @* Z6 K7 ~: g# N3 y8 R- T$ c- b3 `

6 i# j' p2 F/ \3 v% i# X; {5 ~7 b2 b7 l/ c- Z  G) q" \; r* k% r

  ^8 {! }5 |' @1 w8 U6 H5 A9 o$ _8 P) v' T& R# A+ Q
HKLM\System\CurrentControlSet\Control\Session Manager\Configuration Manager\
# J. O! O& W. B6 t4 b“RegistryLazyFlushInterval”=dword:00000060 (dec)
硬件上写缓存不可用时,可以通过设备管理器上的驱动属性启用Windows回写缓存。如果没有硬件写缓存是可用RegistryLazyFlushInterval也应该配置。
Write Cache (Hardware)硬件驱动控制器可以在缓存中存储读写信息以便于读写速度可以达到一个最优值。当写缓存启用时,有数据读写发生时,控制器立即告诉操作系统,允许它继续正常运行。Citrix Consulting建议配置为基于硬件100%写缓存。
Worker ThreadsHKLM\System\CurrentControlSet\Control\Session Manager\Executive\+ a4 S& C% y( T( H7 p' g
“AdditionalCriticalWorkerThreads”=dword:00000064 (dec)
这个值会影响文件系统缓存预读和延迟写请求的线程数量。增加这个值可以允许在存储子系统有更多I/O,可以改善I/O的性能,特别针对与多处理器系统和强大的存储设备上。
Page File
My Computer properties -> Advanced -> Performance Settings -> Advanced tab -> Change Virtual Memory
页面文件其实就是在磁盘上用来存放虚拟内存的文件。系统可以允许分配更多的虚拟内存。虚拟内存的建议配置可以参考微软KB2021748.
SMB 1.0 Client Optimization Note: Tuning SMB 1.0 is required in mixed (2003 / 2008 R2) environments, where SMB 2.0 cannot be used.
HKLM\SYSTEM\CurrentControlSet\Services\Lanmanworkstation\Parameters1 x' Q1 o9 M7 O0 r0 \7 x
"MaxCmds"=dword:00002048 (dec)- g7 q* w. i" t4 D
HKLM\SYSTEM\CurrentControlSet\Services\MRxSmb\Parameters
, V. T6 l& O5 S"MultiUserEnabled"=dword:000000019 Z. ]" x8 A& D5 e9 O( |4 x
HKLM\SOFTWARE\Microsoft\Windows\
CurrentVersion\Policies\Explorer+ ]5 I3 i# K5 D% r
NoRemoteRecursiveEvents”=dword:00000001
4 j( V! c; y, M0 HHKLM\SYSTEM\CurrentControlSet\Services\ Lanmanserver\Parameters
- b) p. i/ S$ g; o"MaxWorkItems"=dword:00008192 (dec)
) Q9 d" k, e( V"MaxMpxCt"=dword:00002048 (dec)' p6 i9 E9 M7 P9 T& n7 o
"MaxRawWorkItems"=dword:00000512 (dec), m! k5 {; _+ [( D
"MaxFreeConnections"=dword:00000100 (dec)
9 d( W1 B' j( G1 m( l"MinFreeConnections"=dword:00000032 (dec)
微软文件传输协议SMB 1.0的优化
SMB 2.x Client TuningHKLM\System\CurrentControlSet\Services\ LanmanWorkstation\Parameters* z3 x4 \% z( X
“DisableBandwidthThrottling"=dword:00000001" Y/ a% U& x3 g3 |
“DisableLargeMtu”=dword:00000000% z" C3 L5 b: H' g: l4 f
HKLM\SOFTWARE\Microsoft\Windows\ CurrentVersion\Policies\Explorer/ @" j# R2 h$ _* }1 {% [. J7 e
NoRemoteRecursiveEvents”=dword:00000001
SMB2.0优化
0 Q& q% B1 x! q& i% u- M

基于Provisioning Service的XenApp优化项

针对于Provisioning 的XenApp 服务器,由于是需要将XenApp服务器做成标准的vDisk模板,任何更改的设置在重启之后就消失了,所以某些过程就不需要了。这里我们针对这个场景也有如下一些建议的注册表配置:

配置项优化建议/注册表理由
Disable Clear Page File at ShutdownyesHKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management]
% p  O- t  {; {9 Z"ClearPageFileAtShutdown"=dword:00000000
清理页面文件会延长关机时间从而增加了整个系统重启的时间
Disable Offline FilesyesHKLM\SOFTWARE\Microsoft\Windows\ CurrentVersion\NetCache
' ~( q: n6 J) T8 a- X0 N7 K* ]"Enabled"=dword:00000000
在XenApp的场景中不需要离线文件这个功能
Disable Background DefragmentationyesHKLM\SOFTWARE\Microsoft\Dfrg\ BootOptimizeFunction+ V* m' A* n( l( j& u
"Enable"="N"
Provisioning Services vDisks不需要磁盘碎片整理
Disable Background Layout ServiceyesHKLM\SOFTWARE\Microsoft\Windows\ CurrentVersion\OptimalLayout1 c, N6 R2 r. Z3 z$ ~" @% s5 D
"EnableAutoLayout"=dword:00000000
[size=12.727272033691406px]Provisioning Services vDisks不需要重新安排磁盘文件布局
Disable HibernationYesHKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Power "Heuristics"=hex:05,00,00,00,00,01,00,00,00,00,00,00,00,00,00,00,3f,42,0f,00禁用计算机休眠功能
Disable Mach. Acct. Password ChangesYesHKLM\SYSTEM\CurrentControlSet\Services\Netlogon\Parameters2 `2 B# _7 ^/ ^; J6 j
"DisablePasswordChange"=dword:00000001
禁用活动目录计算机密码自动更改
Redirect Event LogsNoHKLM\SYSTEM\CurrentControlSet\Services\Eventlog\Application
3 J9 |! z6 j" Y8 m"File"="D:\EventLogs\Application.evtx"* k) d% c3 F* B: J2 B5 g" I: N
HKLM\SYSTEM\CurrentControlSet\Services\Eventlog\Security1 m- U# o' G  y* t, {
"File"="D:\EventLogs\Security.evtx"
; @: L, s0 Y" e2 S% f8 F/ eHKLM\SYSTEM\CurrentControlSet\Services\Eventlog\System
9 M- o# F+ v. z0 u- j7 h"File"="D:\EventLogs\System.evtx"
由于PVS的计算机重启会恢复原状,所以我们将系统日志重定向到另外的盘,以便于有问题时可以查看到日志
Disable Large Send OffloadNoHKLM\SYSTEM\CurrentControlSet\Services\BNNS\ Parameters* c4 T# c* C; d. \5 ]: X
"EnableOffload"=dword:00000000
在做vDisk Stream的时候需要禁用此选项
Disable TCP/IP OffloadNoHKLM\SYSTEM\CurrentControlSet\Services\Tcpip\ Parameters" g; `- v+ {6 m- r
"DisableTaskOffload"=dword:00000001
同上
Increase Service Startup TimeoutNoHKLM\SYSTEM\CurrentControlSet\Control "ServicesPipeTimeout"=dword:00600000(dec)在某些高负载的环境中,windows 服务可能需要超过30秒的时间才能正常启动;这里我们将此设定设置为10分钟
Scheduled DefragNoDisable the scheduled defragmentation of the hard disks.* @! j4 s, u6 [2 R1 o
Task Scheduler – Defrag -> ScheduledDefrag
由于磁盘碎片整理会增加系统负载,且所做的更改重启就没了,所以没有必要做磁盘碎片整理,可以定期重启,既省时又省力

注意:优化项为Yes选项是在PVS目标设备上XenConvert Optimize Tool中已经有的功能


2 p, m! H' S/ S7 Q6 l4 J' L- D# F

Windows服务优化

Windows Server 2008 R2包括一组服务,其中许多服务是默认启用的。当Windows 服务器作为Citrix XenApp服务器的时候,其中的一些服务几乎没有用且显著增加了操作系统的内存占用量。因此以这些服务建议禁用。

0 M" Y% o6 Y9 F' K$ z' E
服务建议理由
Desktop Windows Manager Session ManagerPotential这个服务主要提供windows 7 Areo的主题,由企业自己决定是否需要支持这个主题
Network List ServiceDisable
XenApp服务器的位置不大可能一直在变,因此网络位置的自动检测也是没有必要的。请注意,一些第三方的软件产品例如Appsense需要这两个服务。
注意:禁用这两个服务可能会导致访问一个Https网站有15秒的延迟
Network Location AwarenessDisable
ThemesPotential允许用户管理主题,包括背景,声音和视觉效果。尽管这个服务会占用资源也会影响到整体的规划,每个企业需要自己去决定是否启用此服务。
Windows DefenderDisabled每个企业应该都有自己的防病毒体系,所以微软自带的这个就没必要留着了。
Windows UpdatePotentialPVS的XenApp服务器没必要启用微软的补丁自动更新

. Y: o' p2 k3 D( q4 Y

用户配置

和计算机配置不一样,用户配置无论XenApp服务器vDisk是私有模式还是标准模式都是应用到每一个用户身上。所有的用户设置在XenConvert Optimizer tools都是没有的。

废话不多说,如下是建议的Windows相关的用户设置:

项目建议理由
Internet Explorer – Force Offscreen CompositionHKEY_CURRENT_USER\Software\Microsoft\ Internet Explorer\Main3 `: ]8 _) [! ~. j7 o, y  _; D
"Force Offscreen Composition"=dword:00000001
这个设置可以解决某些网站有闪屏的现象
注意:只对IE8.0之前的浏览器起作用
Disable Recycle BinUser Configuration – Administrative Templates – Windows Components – Windows Explorer
" B* S4 C3 u0 Q, I( @0 L  L0 p/ RDo not move deleted files to the Recycle Bin: Enabled
由于回收站在Windows 2008 R2中是用户配置文件的一部分,在漫游的用户配置文件需要禁用回收站以防止用户配置文件膨胀
Reduce Menu Show DelayHKEY_CURRENT_USER\Control Panel\Desktop
# V% [6 Q, J% t) A"MenuShowDelay"="150"
减少菜单显示时间,提供更好的用户体验。
Disable all Visual Effects except "Use common tasks in folders" and "Use visual styles on windows and buttons"HKEY_CURRENT_USER\Software\Microsoft\ Windows\CurrentVersion\Explorer\VisualEffects1 o0 b0 C! B7 {' A% p% K% b
"VisualFXSetting"=dword:00000003
7 ~2 Z. j+ w1 |3 c! Q$ e- y8 x+ THKEY_CURRENT_USER\Control Panel\Desktop\WindowMetrics$ Q, }$ l6 Y3 f$ X6 I
"MinAnimate"="0"
! t& Z+ r( T. k- v% SHKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\Advanced" ^( H% R& Y; n9 a5 n
"ListviewAlphaSelect"=dword:00000000 "TaskbarAnimations"=dword:00000000 "ListviewWatermark"=dword:00000000 "ListviewShadow"=dword:00000000
2 F5 S# m6 K/ Y, ]  Z7 d3 ?HKEY_CURRENT_USER\Control Panel\Desktop
  q1 b1 s7 p# l8 r"FontSmoothing"="0" "UserPreferencesMask"=binary:90,12,01,80 ,10,00,00,00
提供更好的用户体验
注意:UserPreferenceMask变化基于设置选定在系统属性-性能选项配置页面。
Disable Screen SaverUser Configuration – Administrative Templates – Control Panel – Personalization
9 Q* S2 H2 n0 R2 L$ L2 \' V4 mEnable Screen Saver: Disable
在服务器端运行屏幕保护程序会消耗一定的资源,也没有必要;最好是在本地客户端上运行屏幕保护程序
Documents HistoryUser Configuration – Administrative Templates – Start Menu and Taskbar/ A- H- b" Z% U* c
Do not keep history of recently opened documents: Enable6 v. ^+ B$ G  G' S. ]% d
Remove Balloon Tips on Start Menu items: Enable
4 I+ k' X& `' Z2 uRemove frequent program list from Start Menu: Enable
减少CPU使用率,改善用户登录时间,增大最大可承载的用户
Auto End TasksHKCU\Control Panel\Desktop1 u& D& A& P+ y/ |- ^# C
“AutoEndTasks”=REG_SZ = “1”
8 V+ t9 c$ ?: E2 y0 J1 I“WaittoKillAppTimeout”=REG_SZ= “20000”
有时候用户关闭应用时应用会挂起或者无响应,然后弹出对话框让用户自己选择“等待”或者“终止程序”;这个设置的作用是会自动为用户选择操作避免这个对话框的出现
Background Spell CheckingDisable using Group Policy后台拼写检查会占用大量的系统资源
Sound SchemeDisable Windows Logon / Logoff notification sounds
# ^* ?# c$ [: |! JHKCU\AppEvents\Schemes\Apps\.Default\ WindowsLogon\.Current6 N' F6 \8 N, G2 ~9 e; T7 ]" h
“(Default)”=REG_SZ=””. U% z  Q8 r9 j" C: ]1 f0 x
HKCU\AppEvents\Schemes\Apps\.Default\ WindowsLogoff\.Current  i* K7 }: P9 C5 B
“(Default)”=REG_SZ=””
每次用户登入、登出都会播放声音;播放声音产生的流量消耗也会增长用户登录登出的时间。
0 X7 P$ e$ R' p  I# K% z- G% `

建议的XenApp用户策略配置

目录(在XenApp 策略里面)设置理由
Desktop UIDesktop Wallpaper: Prohibited
2 F2 {$ z% X1 yMenu animation: Prohibited
" A2 H# j+ ~9 t: m0 w2 I3 n- E3 L; q2 GView window content while dragging: Prohibited
这些设置可以使每用户会话的内存和带宽占用率减少
Visual Display\Moving ImagesProgressive compression level: Low (min. setting)通过这个策略降低每用户的网络带宽使用率
Printing\DriversAutomatic Installation of in-box drivers: Disabled尽管这个设置和性能无关,但是这是我们高度建议的一个策略,这个设置会阻止用户安装不需要的打印机驱动,也会减少排查打印机相关问题的复杂度

5 L% H" v5 u! _. L6 g
* I6 s6 x- ]5 R7 }. \7 _
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

QQ|华强北 电脑城 龙岗电子世界 龙华电脑城 pc4g.com ( 粤ICP备16039863号 )

GMT+8, 2025-6-19 14:46 , Processed in 0.098529 second(s), 17 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表