1 / 30

WIN314: Windows .NET 服务器的新技术 -- Part 1

WIN314: Windows .NET 服务器的新技术 -- Part 1. 严治庆 项目经理 Windows .Net Server Microsoft Corporation. 议程. 今天我们已经有了出色的平台! 把我们的平台做得更出色 — ASP.NET on Internet Information Server (IIS) 6 使您的运用程序更安全 使您的运用程序更可靠 更快,更缩放 有了更新的管理功能 UDDI 与 ASP.NET 资源 谈论. 今天出色的平台! ASP .NET on Windows ® 2000/IIS5.

enoch
Download Presentation

WIN314: Windows .NET 服务器的新技术 -- Part 1

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. WIN314: Windows .NET 服务器的新技术--Part 1 严治庆 项目经理 Windows .Net Server Microsoft Corporation

  2. 议程 • 今天我们已经有了出色的平台! • 把我们的平台做得更出色—ASP.NET on Internet Information Server (IIS) 6 • 使您的运用程序更安全 • 使您的运用程序更可靠 • 更快,更缩放 • 有了更新的管理功能 • UDDI 与 ASP.NET • 资源 • 谈论

  3. 今天出色的平台!ASP .NET on Windows® 2000/IIS5 • 支持分层的身份验证(authN)/授权(authZ) • 支持 running with least privilege • Built using .NET Framework 安全 可靠 • 热更新(Hot update) of running 应用程序 • 故障, 内存泄漏 (memoryleak), 死锁查测 • Proactive and reactive 进程循环 (process cycling) • 运用程序城 (Application domains) • 运行时的性能 (Performanceruntime) • Web园 模式 • 支持 Web场 会话状态 缩放 • XML 配置 • XCOPY 部属 管理

  4. 演示 把一个 ASP .NET 应用程序从 IIS5 迁移到 IIS6

  5. 把我们的平台做得跟出色ASP .NET 在 IIS 6上! • 锁定默认 • 约束的, 委派的身分验证 • 配置工作进程 ID 安全 • 新的进程模型 • 应用程序池 • 回收 • 运行状况 检测 (Health Detection) 可靠 • Web园 • 每一个服务器能容纳更多个 .NET 应用程序 • 请求开始与空闲超时 • 运用核心缓存来存储响应 缩放 • XML Metabase • WMI 提供程序 • 支持 Command Line Tools 管理

  6. 使您的运用程序更安全锁定默认值 • IIS 在从头安装时不被安装 • IIS 默认时serves 静态文件 • 404s--禁用应用程序的扩展 • ASP .NET, FPSE, 与 FTP 不被默认安装 • ASP .NET 被安装后便启用 • 运用新安全控制台来启用应用程序的扩展 • 单个 ISAPI 扩展与 CGI’s • 运用 Visual Studio® .NET启用 FPSE 与 ASP .NET • 或者启用 ASP .NET来允许操纵ASP .NE应用程序

  7. 1 3 Kerberos ticket 2 4 NAS 后端服务器 Kerberos ticket 使您的运用程序更安全委派验证与授权 • 客户于前段 web 服务器验证 • Web 服务器从AD 服务器来请求 Kerberos 票证验证用户 • Kerberos 票证被还到 Web 服务器 • Web 服务器把Kerberos 票证传到remote server 用来做为ACL的授权。 internet Web 客户机 www.site1.com (user: site1_user) www.site2.com (user: site2_user) www.site3.com (user: site3_user) … www.site101.com (user: site101_user) www.site102.com (user: site102_user) www.site103.com (user: site103_user) … 前段 Web 服务器 \\SitesDir1 \site1 \site2 \site3 … Site1_User Site2_User Site3_User mydomain

  8. 使您的运用程序更安全可配置的工作进程标识 • 工作进程可以开始为 • Network Service (default) • Local System • Local Service • Configured ID • IIS_WPG • 新用户组 • IIS资源 ACL’d 到这个组

  9. 演示 可配置的工作进程标识

  10. 使您的运用程序更安全推荐 • 只需要取消锁定需要的ASP .NET 应用程序组件 • ASP .NET • FPSE (发布时) • 锁定 (disable) 其他不需要的 ISAPI 扩展,像 ASP, CGI 等 • 运用工作进程 as Network Service 或者其他 low-privileged account

  11. W3WP.exe W3WP.exe W3WP.exe WAS web app web app web app web app HTTP.SYS kernel 使您的运用程序更可靠为 IIS6做的新体系结构 • 目标: 启用完整的 app isolation from other Web apps and core Web Server • Web Service 在 INETINFO中 split out to do this • HTTP.SYS: 核心模式侦听着与请求路由器 • WAS: 配置与进程管理 • W3WP.exe: Web 应用程序在这儿进程 • 多个 W3WP.exe’s

  12. 使您的运用程序更可靠应用程序池 • 能够创建一个或者几个应用程序池 • 应用程序池 • 一个或几个 W3WP.exes 为每一个程序池服务 • 每个 W3WP.exe 提供一个池 • Web 请求用 http.sys 路由到应用程序池 • 隔离应用程序 based on • 站点/顾客(Site/Customer) • 功能 (Functionality) • 可靠性(Reliability)

  13. 应用程序池 W3WP.exe ASP.NET App Domain App Domain App Domain App Domain App Domain App Domain App Domain App Domain 使您的应用程序更可靠.NET 应用程序域与应用程序池 • 应用程序域(app domain) • 轻量的 CLR unit of isolation • 每一个IIS应用程序有一个应用程序域 • 与 W3WP.exe合并来 得到更高的可伸索性与隔离级别性 • ASP.NET 独立管理应用程序域 • 在一个进程中回收 (recycling within a single process) • 可以有专用组件,会话变量等。(Can have private components, session variables , etc.) App pool App pool WAS W3WP.exe W3WP.exe ASP .NET ASP .NET HTTP.SYS

  14. 使您的运用程序更可靠周期的进程回收 • 这是什么? • 在周期重新启动的基础上 • 正常运用时间 (Uptime) • 需求数量 (# of requests) • 调度时间 (Scheduled time) • 内存消耗 (Memory consumption) • 按需 (On-demand) • 为什么要用呢? • 刷新应用程序来保证可用性 • 防备以坏的应用程序来占领整个系统

  15. 使您的运用程序更可靠Machine.Config 与 Metabase.XML 的设置 Machine.Config <processModel requestLimit=“500” memoryLimit=“60” … /> Metabase.XML <IIsApplicationPool Loc=“…” PeriodicRestartReqs=“500” PeriodicRestartMemory=“20” PeriodicRestartSchedule=“” PeriodicRestartTime=“0” • Machine.config <processModel…> section is ignored when running on IIS 6

  16. 使您的运用程序更可靠Web 场会话状态 • 会话状态可以存储在外部进程中 • ASPState Service • SQL Server™ 2000 • 可靠性 • 会话状态 survives 故障/重新启动 • 启用 Web 场部署 • 会话状态 can now be shared across a Web farm of ASP .NET Servers • Applications no longer tied to one machine • Design your apps to be recycled!

  17. 演示 从回收中保持会话状态

  18. 使您的运用程序更可靠Pinging A W3WP.exe • 这是什么? • 为检测 W3WP.exe 线程死锁而设计 • Will engage if there are no threads in worker process available to respond in time • 怎么使用? • WAS “ping” 每一个 W3WP.exe • 配置进程—在一段时间内一定要有回应 • 如果 (在确定的一段时间内没有回应) • 默认: 去处进程, 发布事件, 启动新的进程 • 或者: Can be configured to take a configured action on process => “Orphaning” • ASP .NET 运用 Ping 来请求一个回收如果他不健康

  19. 更快,更缩放在HTTP.SYS中缓存响应 • ASP .NET 把以完成的响应缓存在HTTP.SYS中 • 响应被标记为 Location=“Server” • HTTP.SYS 直接提供在缓存中的响应 • 从核心中提供以响应是非常快的 – 没有用户模式中的转换 • 应用程序不会看到 web 请求如果缓存中已有响应 • Invalidation of cached complete responses (Server) same as in IIS5 <%@ OutputCache Location=“Server” … %>

  20. Worker process Worker process Worker process Worker process ISAPI Extension ISAPI Extension ISAPI Extension ASP .NET ISAPI filter ISAPI filter ISAPI filter ISAPI filter 更快,更缩放IIS 6 Web园与进程关系 • Web 园 • 应用程序池有 > 1 工作进程 • Connection-based 路由 w/in web 园 • 处理器亲合力 • 把一个或更多的CPU 绑定在应用程序池进程中 • Mask-based config Web 园 应用程序池 WAS HTTP.SYS

  21. 更快,更缩放空闲超时与请求开始 • 空闲超时 • 超时和关闭闲置进程如果进程闲置着一段时间 • 为活动者的应用程序解脱资源 • 应用程序还是可用的,虽然工作进程是空闲的而已经被关闭了! • 请求开始 • 如果需要应用程序池的时候,再开始工作进程 • 应用程序考虑 • 运用空闲超时来为被重用的应用程序解脱资源 • 考虑禁用空闲超时如果应用程序需要很长的时间启动

  22. Metabase.xml MBSchema.xml 更新的管理功能Metabase 更新 • XML Metabase • 用 XML 来 存储 Metabase • 自动版本控制: 就像是自动备份 • 运行时的编辑 • 在 IIS 运行时,可以直接更改 metabase.xml • 各种各样的编辑器都可以用 – Notepad.NET, PERL, etc. UI ADSI Admin Base Objects

  23. UI ADSI Admin Base Objects Metabase.xml MBSchema.xml 更新的管理功能Metabase 改进 – 导入/导出 • 导入或导出 metabase config • 选项包括有 • 导入或导继承的属性 • 只倒入或导出接点(或者整个子树) • 密码加密到处的文件 • 运用 ASP .NET XCOPY 部署apps • 为 .net app 导出 IIS6 metabase config • 存储在 .NET app 目录中 • 在 XCOPY 后,导入 app metabase config 文件

  24. 演示 运行时的编辑

  25. 更新管理功能WMI 提供者与新的 Command Line Tools • IIS WMI 提供者 • 支持查询 • 关联 • 可支持脚本语言 • 新的 Command Line Tools • Task-based 方法 • 支持的工具 – 在 %windir%\system32中 • Based on WMI Provider • Example: 运用 IISCNFG.vbs 作为 .NET 应用程序迁移战略 的一部分 Command Line Tools UI WMI ADSI Admin Base Objects Metabase.xml MBSchema.xml

  26. 总结 • Internet Information Server (IIS) 5 上的ASP.NET 是一个出色的平台 • 把 IIS 6 做得更出色—使 .NET应用程序更 • 安全 • 可靠 • 缩放 • 管理

  27. 资源 • 文档 • 在 TechNet 上的 IIS 6 Overview http://www.microsoft.com/technet/treeview/default.asp?url=/TechNet/prodtechnol/iis/evaluate/iis6ovw.asp • 其他 IIS 课程 • Sec 307: 确保 Internet Information Services 5.0及6.0的运行安全性 • WIN 315: 在IIS 6.0基础之上构建高性能的Web应用程序

  28. 如果您有任何问题,请上微软中文新闻组继续讨论如果您有任何问题,请上微软中文新闻组继续讨论 加入微软中文新闻组 http://www.microsoft.com/china/community

  29. © 2002 Microsoft Corporation. All rights reserved. This presentation is for informational purposes only. Microsoft makes no warranties, express or implied, in this summary.

More Related