« 七月 2008
星期日星期一星期二星期三星期四星期五星期六
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
  
       
今天

Blog::Navigation

Blog::Editing

Bookmarks::Blogroll

Blog::Referers

Site notes

This page validates as XHTML 1.0, and will look much better in a browser that supports web standards, but it is accessible to any browser or Internet device. It was created using techniques detailed at glish.com/css/.

Powered by Roller Weblogger.
« Sun Device Detection... | Main | 北京OpenSolaris用户组第十四次... »
星期四 三月 13, 2008

Sun Device Detection Tool 之路(2)

在良好开端的鼓励之下,为了方便没有网络连接的用户,也是为了当时新发布的Solaris Express Developer Edition 服务,Sun Device Detection Tool在通过官方网站发布的网络版之外,又派生了一个单机版。该版本被集成到Solaris Express Developer Edition的安装DVD里,提供的也是针对Solaris Express Developer Edition的数据库(数据库和程序一样被集成在DVD里)。用户可以在没有任何网络连接的情况下使用单机版。

此后,开发测试人员继续改善这一工具,使它具有更好的可靠性以及提供更多的功能。在1.0之后,Sun Device Detection Tool 1.1, 1.2, 和2.0版本被相继发布。

在Sun Device Detection Tool 1.1中,提供了针对多个Solaris OS版本的数据库(Solaris 10 11/06 和 Solaris Express Developer Edition 2/07)。从那以后,各版本的Sun Device Detection Tool都保持提供针对最新版的Solaris 10 和Solaris Express Developer Edition的数据库。

在Sun Device Detection Tool 1.2中开发的一个全新功能是HCL提交选项,使用此项功能,用户可以将自己的Solaris正式发行版的系 统信息提交给HCL team,经过HCL的工程师评审后,如果符合HCL规范,则该系统将作为与Solaris OS兼容的系统被列入到HCL中。

鉴于1.0对于系统命令依赖的局限,在Sun Device Detection Tool 2.0中我们开发自己的程序,通过各系统提供的接口直接读取设备数据(具体实现如下)。

OS类型
接口
解决方法
Solaris
libdevinfo 在prom tree中查询PCI节点,并从节点中读取设备数据
Windows
Win32 API 通过Win32 API从注册表中读取设备数据
Linux
/proc/bus/pci 扫描/proc/bus/pci文件,并从中读取设备数据

这样,Sun Device Detection Tool探测用户设备的时候,不再依赖于用户系统的系统命令,使得本工具的可靠性大幅度提高。同时也扩展的Sun Device Detection Tool的支持平台,使得它在所有2.6内核的Linux系统和主要的Windows系统上都可以运行。

当然,之前的通过解析系统命令输出获得设备数据的功能也没有被废弃,而是作为一个全新的导入设备数据文件的功能开放给了用户。这样也方便了那些由于没有网络连接无法使 用Sun Device Detection Tool,或者希望判断远程徐同中设备与Solaris OS兼容性的用户。他们可以先在需要探测的Solaris, Windows或Linux系统上运行相应的命令生成一个保存了其输出的文件。然后把这个文件拷贝到有网络连接的机器上,作为设备数据文件导入给Sun Device Detection Tool,以获得该系统设备的报告。

目前,Sun Device Detection Tool 2.1正在开发过程中,并将于今年四月中下旬发布。2.1在以上诸多功能的基础之上,扩展了设备探测功能,使得它可以在Mac OS X上运行。在最后生成的Solaris驱动可用性报告中,除了 现在已有的项目,用户还可以通过提示工具(ToolTip)直接浏览设备数据信息。另外,用户在WindowsLinux系统上也将可以使用HCL提交选项把他们的系统信息发送给Sun。虽然他们的系统不能直接被列入 HCL,但是他们提供的诸多硬件和系统配置的信息,将为Solaris驱动和系统开发提供指导。

还有一点需要指出的是,早在Sun Device Detection Tool 1.0发布不久,开发工程师就曾经考虑将其作为一个开源项目,发布源代码。现在2.0的源代码已经在OpenSolaris.org上发布。在开源项目 中,表示公司名称的"Sun"被移除,本工具的开源名称为Device Detection Tool,欢迎访问Device Detection Tool开源主页,并参与到该项目中 来。

评论:

发表一条评论:
  • HTML语法: 禁用
Copyright (C) 2003, Sun Device Detection Tool