- 目 录 课程说明.............................. 1 课程介绍................................ 1 课程目标................................ 1 相关资料................................ 1 第 1 章 SUN工作站介绍 ....... 2 1.1 SUN工作站上的软件....... 2 1.2 SUN系统硬件.................. 2 1.3 SUN设备的型号.............. 3 1.4 使用注意事项 .................. 3 1.5 小 结........................... 3 1.6 习 题........................... 3 第2 章 Solaris操作系统简介 4 2.1 概述................................. 4 2.2 UNIX流派和标准 ............. 4 2.3 UNIX特点........................ 5 2.4 小 结............................ 6 2.5 习 题............................ 6 第3 章 UNIX的结构 ............. 7 3.1 UNIX的系统结构............. 7 3.2 UNIX的文件系统............. 8 3.3 UNIX文件系统的目录、i-节点和文件................ 9 3.4 UNIX系统的程序........... 10 3.5 小 结.......................... 11 3.6 习 题.......................... 11 第4 章 Solaris系统常用操作 ................................ 12 4.1 SUN工作站系统的启动 . 12 4.2 用户登录........................ 12 4.2.1 用户名和口令..... 13 4.2.2 登录到系统 ......... 13 4.2.3 成功登录之后...... 13 4.2.4 用户的权限......... 14 4.3 命令行的使用 ................ 14 4.3.1 命令行的使用环境 ................................ 14 4.3.2 命令行的用法结构................................ 14 4.4 系统的退出.................... 15 4.5 控制键........................... 16 4.6 系统帮助........................ 16 4.7 异常情况处理 ................ 16 4.8 目录的浏览与控制......... 17 4.8.1 显示当前工作目录——pwd................... 18 4.8.2 切换目录——cd .. 18 4.8.3 创建目录——mkdir ............................... 19 4.8.4 删除目录——rmdir ............................... 19 4.8.5 列出目录内容——ls .............................. 19 4.9 文件维护命令 ................ 21 4.9.1 拷贝文件——cp .. 22 4.9.2 移动文件或重命名文件——mv ............. 22 4.9.3 删除文件——rm . 23 4.9.4 改变文件权限——chmod...................... 23 4.9.5 改变文件的属主——chown ................. 25 4.9.6 改变文件属组——chgrp....................... 26 4.10 文本文件的内容显示命令.............................. 26 4.10.1 回送字符串——echo ......................... 26 4.10.2 分页显示文件——more和pg .............. 27 4.11 系统资源...................... 28 4.11.1 报告磁盘剩余空间——df .................... 29 4.11.2 报告磁盘使用空间——du ................... 29 4.11.3 显示活动进程状态——ps ................... 30 4.11.4 终止进程运行——kill ......................... 31 4.11.5 列出当前用户——who ........................ 32 4.11.6 报告命令位置——whereis ................. 32 4.11.7 报告命令的发现点——which .............. 33 4.11.8 显示、设置主机名——hostname ...... 33 4.11.9 查看本机的IP地址——ifconfig ............ 33 4.11.10 显示操作系统的名字——uname ...... 34 4.11.11 记录屏幕I/O活动——script .............. 34 4.11.12 当前日期和时间——date ................. 36 4.12 小 结........................ 37 4.13 习 题........................ 37 第5 章 认识shell ................ 38 5.1 内置命令........................ 39 5.1.1 sh........................ 39 5.1.2 csh...................... 40 5.2 环境变量........................ 41 5.3 Bourne Shell,sh .......... 45 5.4 C Shell,csh ................. 46 5.5 小 结.......................... 49 5.6 习 题.......................... 49 第6 章 UNIX的特别之处.... 50 6.1 文件的重定向 ................ 50 6.2 其他的特殊命令符号 ..... 52 6.3 匹配符........................... 53 6.4 小 结.......................... 53 6.5 习 题.......................... 53 第7 章 常用工具和实用程序................................. 54 7.1 vi编辑器的最基本用法... 54 7.2 利用find命令查找文件... 55 7.3 grep命令基本用法......... 57 7.4 文件的备份和恢复实用程序............................. 57 7.4.1 tar命令................ 57 7.4.2 cpio命令.............. 58 7.5 文件压缩和解压程序 ..... 60 7.5.1 compress 压缩命令.............................. 60 7.5.2 pack 压缩文件 .... 60 7.5.3 gzip 压缩文件 ..... 61 7.5.4 pkzip压缩文件 .... 61 7.6 小 结.......................... 61 7.7 习 题.......................... 61 第8 章 网络通信................ 62 8.1 TCP/IP协议................... 62 8.2 测试网络连通情况......... 62 8.3 查看网上用户信息......... 63 8.4 在网络上登录和拷贝 ..... 64 8.4.1 telnet................... 65 8.4.2 ftp ....................... 66 8.5 小 结.......................... 69 8.6 习 题.......................... 69 第9 章 用户管理 ................ 70 9.1 用户信息文件 ................ 70 9.2 用户维护命令 ................ 70 9.3 小 结.......................... 71 9.4 习 题.......................... 72 第 10 章 SUN工作站上设备的使用....................... 73 10.1 硬盘知识介绍 .............. 73 10.1.1 硬盘分类........... 73 10.1.2 什么是分区 ....... 74 10.1.3 硬盘设备项 ....... 75 10.2 CD-ROM 的使用......... 76 10.3 磁带机的使用 .............. 76 10.4 软盘的使用.................. 77 10.5 打印机的安装使用....... 78 10.6 小 结........................ 79 10.7 习 题........................ 79 习题答案............................ 804 281浏览会员免费
- Solaris10系统管理,干兴趣的人看下,参考一下5 191浏览会员免费
- Sun SPARC T5140 和 T5240服务器服务手册 PDF 非扫描4 352浏览会员免费
- Solaris 10 系统管理 操作系统管理4 199浏览会员免费
- 这是OpenSolaris的开发者文档,文档为英文,主要是源码树内容的介绍,以及如何编译Solaris内核源码0 117浏览会员免费
- Oracle(R)_Solaris_11_安装手册页 官方文档(中文)4 117浏览会员免费
- 本书介绍Solaris操作系统的内核,提供了内核结构以及该操作系统中使用的主要数据结构和算法的大量信息,主要内容包括:Solaris内核概述、Solaris存储系统线程、进程和IPC、文件和文件系统;本书还讲解了该系统的实际应用,用大量实例阐述了应用方法和技巧;本书对于使用Solaris操作系统的各类技术人员来讲是一本极具参考价值的专著。4 141浏览会员免费
- Solaris Advanced User’s Guide4 89浏览会员免费
- 主要是在T4-2上安装solaris10U10中出现的BUG,及解决办法,EIS打补丁,多路径做法,挂载NAS存储等5 250浏览会员免费
- 比较新的操作系统原版教材,详细介绍操作系统管理员及网络管理员5 137浏览会员免费
- 使用 Virtutech Simics 3.0.29 在 WIN XP(SP3)上安装 solaris 10 的 sparc 版本5 360浏览会员免费
- 2011/07/26 Oracle Solaris 11介绍及动手实践 培训内容6 -- 使用 Dtrace 来了解你的应用程序0 109浏览会员免费
- 2011/07/26 Oracle Solaris 11介绍及动手实践 培训内容2 -- Solaris 11 新特性0 79浏览会员免费
- 2011/07/26 Oracle Solaris 11介绍及动手实践 培训内容5 -- 将应用从 Solaris 10 移植到 Solaris 115 84浏览会员免费
- Sun™ XVR-100 图形加速器 安装指南3 131浏览会员免费
- 2011/07/26 Oracle Solaris 11介绍及动手实践 培训内容1 -- Oracle 硬件战略概要0 145浏览会员免费
- 编写设备驱动程序》提供有关为面向字符的设备、面向块的设备、网络设备、SCSI目标和HBA设备以及USB设备开发SolarisolarisOperatingSystem,SolarisOS)驱动程序的信息。本书讨论了如何为符合SolarisOSDDI/DKI(DeviceDriver Interface/Driver-KernelInterface,设备驱动程序接口/驱动程序内核接口)的所有体系结构开发多线程可重入设备驱动程序。介绍了一种常用的驱动程序编写方法,该方法允许在编写驱动程序时忽略特定于平台的问题,如字节存储顺序(endianness)和数据排序等。 其他主题包括:强化Solaris驱动程序;电源管理;驱动程序自动配置;程控I/O;直接内存访问(DirectMemoryAccess,DMA);设备上下文管理;编译、安装和测试驱动程序;调试驱动程序以及将Solaris驱动程序移植到64位环境。 目录 前言........................................................................................................................................................29 第1部分 针对Solaris平台设计设备驱动程序..............................................................................................35 1 Solaris设备驱动程序概述 ................................................................................................................37 设备驱动程序基础知识.................................................................................................................... 37 什么是设备驱动程序? ............................................................................................................ 37 什么是设备驱动程序入口点? ............................................................................................... 38 设备驱动程序入口点 ........................................................................................................................ 38 通用于所有驱动程序的入口点 ............................................................................................... 39 用于块设备驱动程序的入口点 ............................................................................................... 41 用于字符设备驱动程序的入口点........................................................................................... 42 用于STREAMS设备驱动程序的入口点 ............................................................................... 43 用于内存映射设备的入口点 ................................................................................................... 44 网络设备驱动程序入口点 ........................................................................................................ 45 用于SCSIHBA驱动程序的入口点 ........................................................................................ 45 用于PC卡驱动程序的入口点 ................................................................................................. 46 设备驱动程序设计注意事项 ........................................................................................................... 46 DDI/DKI功能 ............................................................................................................................. 47 驱动程序上下文 ......................................................................................................................... 48 返回错误 ...................................................................................................................................... 49 动态内存分配 .............................................................................................................................. 49 热插拔 ........................................................................................................................................... 50 2 Solaris内核和设备树 .........................................................................................................................51 什么是内核? ..................................................................................................................................... 51 多线程执行环境 ......................................................................................................................... 53 3 虚拟内存 ...................................................................................................................................... 53 作为特殊文件的设备................................................................................................................. 53 DDI/DKI接口 ............................................................................................................................. 53 设备树概述.......................................................................................................................................... 54 设备树组件 .................................................................................................................................. 54 显示设备树 .................................................................................................................................. 56 将驱动程序绑定到设备 ............................................................................................................ 58 3 多线程 ...................................................................................................................................................61 锁定原语 .............................................................................................................................................. 61 驱动程序数据的存储类 ............................................................................................................ 61 互斥锁 ........................................................................................................................................... 62 读取器/写入器锁 ........................................................................................................................ 63 信号 ............................................................................................................................................... 63 线程同步 .............................................................................................................................................. 64 线程同步中的条件变量 ............................................................................................................ 64 cv_wait()和cv_timedwait()函数 ........................................................................................ 65 cv_wait_sig()函数 ................................................................................................................... 66 cv_timedwait_sig()函数 ........................................................................................................ 67 选择锁定方案 ..................................................................................................................................... 67 潜在的锁定缺点 ......................................................................................................................... 68 线程无法接收信号 ..................................................................................................................... 68 4 属性........................................................................................................................................................71 设备属性 .............................................................................................................................................. 71 设备属性名称 .............................................................................................................................. 72 创建和更新属性 ......................................................................................................................... 72 查找属性 ...................................................................................................................................... 72 prop_op()入口点 ....................................................................................................................... 74 5 管理事件和排队任务 .........................................................................................................................77 管理事件 .............................................................................................................................................. 77 事件介绍 ...................................................................................................................................... 77 使用ddi_log_sysevent()记录事件 ...................................................................................... 78 目录 编写设备驱动程序 • 2010年9月 4 定义事件特性 .............................................................................................................................. 80 排队任务 .............................................................................................................................................. 83 任务队列简介 .............................................................................................................................. 83 任务队列接口 .............................................................................................................................. 83 使用任务队列 .............................................................................................................................. 84 观察任务队列 .............................................................................................................................. 84 6 驱动程序自动配置 .............................................................................................................................87 驱动程序的装入和卸载.................................................................................................................... 87 驱动程序必需的数据结构 ............................................................................................................... 88 modlinkage结构 ......................................................................................................................... 88 modldrv结构 ................................................................................................................................ 89 dev_ops结构 ................................................................................................................................ 89 cb_ops结构 .................................................................................................................................. 90 可装入驱动程序接口 ........................................................................................................................ 91 _init()示例 ................................................................................................................................ 92 _fini()示例 ................................................................................................................................ 93 _info()示例 ................................................................................................................................ 93 设备配置概念 ..................................................................................................................................... 94 设备实例和实例编号................................................................................................................. 94 次要节点和次要设备号 ............................................................................................................ 95 probe()入口点 ........................................................................................................................... 95 attach()入口点 ......................................................................................................................... 97 detach()入口点 .......................................................................................................................102 getinfo()入口点 .....................................................................................................................103 使用设备ID ......................................................................................................................................105 注册设备ID ...............................................................................................................................105 注销设备ID ...............................................................................................................................106 7 设备访问:程控I/O..........................................................................................................................107 设备内存 ............................................................................................................................................107 管理设备和主机字节序之间的差别 ....................................................................................108 管理数据排序要求 ...................................................................................................................108 ddi_device_acc_attr结构 ....................................................................................................108 映射设备内存 ............................................................................................................................109 目录 5 映射设置示例 ............................................................................................................................109 设备访问函数 ...................................................................................................................................110 备用设备访问接口 ...................................................................................................................111 8 中断处理程序 ................................................................................................................................... 113 中断处理程序概述 ..........................................................................................................................113 设备中断 ............................................................................................................................................114 高级别中断 ................................................................................................................................114 传统中断 ....................................................................................................................................115 标准消息告知中断和扩展消息告知中断 ...........................................................................115 软件中断 ....................................................................................................................................116 DDI中断函数 ...................................................................................................................................117 中断功能函数 ............................................................................................................................117 中断初始化和销毁函数 ..........................................................................................................117 优先级管理函数 .......................................................................................................................118 软中断函数 ................................................................................................................................118 中断函数示例 ............................................................................................................................118 注册中断 ............................................................................................................................................119 注册传统中断 ............................................................................................................................119 注册MSI中断 ...........................................................................................................................122 中断资源管理 ...................................................................................................................................125 中断资源管理功能 ...................................................................................................................125 回调接口 ....................................................................................................................................126 中断请求接口 ............................................................................................................................128 中断资源管理实现样例 ..........................................................................................................130 中断处理程序功能 ..........................................................................................................................135 处理高级别中断 ...............................................................................................................................137 高级互斥锁 ................................................................................................................................137 高级别中断处理示例...............................................................................................................137 9 直接内存访问(DirectMemoryAccess,DMA) ..............................................................................141 DMA模型 ..........................................................................................................................................141 设备DMA的类型 ............................................................................................................................142 总线主控器DMA .....................................................................................................................142 第三方DMA ..............................................................................................................................142 目录 编写设备驱动程序 • 2010年9月 6 第一方DMA ..............................................................................................................................143 主机平台DMA的类型 ...................................................................................................................143 DMA软件组件:句柄、窗口和Cookie .....................................................................................143 DMA操作 ..........................................................................................................................................144 执行总线主控器DMA传送 ...................................................................................................144 执行第一方DMA传送 ............................................................................................................144 执行第三方DMA传送 ............................................................................................................145 DMA特性 ..................................................................................................................................145 管理DMA资源 ................................................................................................................................148 对象锁定 ....................................................................................................................................148 分配DMA句柄 .........................................................................................................................148 分配DMA资源 .........................................................................................................................149 确定最大突发流量大小 ..........................................................................................................151 分配专用DMA缓冲区 ............................................................................................................152 处理资源分配故障 ...................................................................................................................153 对DMA引擎进行编程 ............................................................................................................154 释放DMA资源 .........................................................................................................................155 释放DMA句柄 .........................................................................................................................156 取消DMA回调 .........................................................................................................................156 同步内存对象 ............................................................................................................................157 DMA窗口 ..........................................................................................................................................159 10 映射设备和内核内存 ...................................................................................................................... 163 内存映射概述 ...................................................................................................................................163 导出映射 ............................................................................................................................................163 segmap(9E)入口点 ....................................................................................................................163 devmap(9E)入口点 ....................................................................................................................165 将设备内存与用户映射相关联 ....................................................................................................166 将内核内存与用户映射相关联 ....................................................................................................168 为用户访问分配内核内存 ......................................................................................................168 将内核内存导出到应用程序 .................................................................................................170 释放为用户访问导出的内核内存.........................................................................................171 11 设备上下文管理 ............................................................................................................................... 173 设备上下文简介 ...............................................................................................................................173 目录 7 什么是设备上下文?...............................................................................................................173 上下文管理模型 .......................................................................................................................173 上下文管理操作 ...............................................................................................................................175 devmap_callback_ctl结构 ....................................................................................................175 用于设备上下文管理的入口点 .............................................................................................176 将用户映射与驱动程序通知关联.........................................................................................183 管理映射访问 ............................................................................................................................184 12 电源管理 ............................................................................................................................................ 187 电源管理框架 ...................................................................................................................................187 设备电源管理 ............................................................................................................................187 系统电源管理 ............................................................................................................................188 设备电源管理模型 ..........................................................................................................................188 电源管理组件 ............................................................................................................................189 电源管理状态 ............................................................................................................................189 电源级别 ....................................................................................................................................189 电源管理相关性 .......................................................................................................................191 设备的自动电源管理...............................................................................................................191 设备电源管理接口 ...................................................................................................................192 power()入口点 .........................................................................................................................193 系统电源管理模型 ..........................................................................................................................195 自动关闭阈值 ............................................................................................................................196 繁忙状态 ....................................................................................................................................196 硬件状态 ....................................................................................................................................196 系统的自动电源管理...............................................................................................................196 系统电源管理使用的入口点 .................................................................................................196 电源管理设备访问示例..................................................................................................................200 电源管理控制流程 ..........................................................................................................................201 电源管理接口的更改 ......................................................................................................................202 13 强化Solaris驱动程序 ......................................................................................................................205 Sun故障管理体系结构I/O故障服务 .........................................................................................205 什么是预测性自我修复? ......................................................................................................206 SolarisFaultManager ................................................................................................................206 错误处理 ....................................................................................................................................209 目录 编写设备驱动程序 • 2010年9月 8 诊断故障 ....................................................................................................................................222 事件注册表 ................................................................................................................................223 词汇表 .........................................................................................................................................223 资源 .............................................................................................................................................224 用于Solaris设备驱动程序的防御性编程方法 ..........................................................................224 使用单独的设备驱动程序实例 .............................................................................................225 独占使用DDI访问句柄 .........................................................................................................225 检测已损坏的数据 ...................................................................................................................225 DMA隔离 ..................................................................................................................................226 处理有问题的中断 ...................................................................................................................227 其他编程注意事项 ...................................................................................................................228 驱动程序强化测试工具..................................................................................................................229 故障注入 ....................................................................................................................................229 设置测试工具 ............................................................................................................................230 测试驱动程序 ............................................................................................................................231 使用脚本自动完成测试过程 .................................................................................................233 14 分层驱动程序接口(LayeredDriverInterface,LDI) ....................................................................237 LDI概述 .............................................................................................................................................237 内核接口 ............................................................................................................................................238 分层标识符-内核设备使用方 .............................................................................................238 分层驱动程序句柄-目标设备 .............................................................................................239 LDI内核接口示例 ....................................................................................................................242 用户接口 ............................................................................................................................................253 设备信息库接口 .......................................................................................................................253 列显系统配置命令接口 ..........................................................................................................254 设备用户命令接口 ...................................................................................................................257 第2部分 设计特定种类的设备驱动程序 .....................................................................................................259 15 字符设备驱动程序 .......................................................................................................................... 261 字符驱动程序结构概述..................................................................................................................261 字符设备自动配置 ..........................................................................................................................263 设备访问(字符驱动程序) .........................................................................................................264 目录 9 open()入口点(字符驱动程序) ........................................................................................264 close()入口点(字符驱动程序) ......................................................................................265 I/O请求处理 .....................................................................................................................................266 用户地址 ....................................................................................................................................266 向量化的I/O .............................................................................................................................266 同步I/O与异步I/O之间的差别 ..........................................................................................268 数据传输方法 ............................................................................................................................268 映射设备内存 ...................................................................................................................................274 对文件描述符执行多路复用I/O操作 ........................................................................................275 其他I/O控制 ....................................................................................................................................277 ioctl()入口点(字符驱动程序) ......................................................................................277 对有64位处理能力的设备驱动程序的I/O控制支持 .....................................................279 处理copyout()溢出 ................................................................................................................281 32位和64位数据结构宏................................................................................................................282 结构宏如何工作? ...................................................................................................................282 何时使用结构宏 .......................................................................................................................283 声明并初始化结构句柄 ..........................................................................................................283 结构句柄的操作 .......................................................................................................................283 其他操作 ....................................................................................................................................284 16 块设备驱动程序 ............................................................................................................................... 285 块驱动程序结构概述 ......................................................................................................................285 文件I/O ..............................................................................................................................................286 块设备自动配置 ...............................................................................................................................287 控制设备访问 ...................................................................................................................................288 open()入口点(块驱动程序) .............................................................................................288 close()入口点(块驱动程序)...........................................................................................290 strategy()入口点 ...................................................................................................................290 buf结构 ......................................................................................................................................291 同步数据传输(块驱动程序) ....................................................................................................292 异步数据传输(块驱动程序) ....................................................................................................296 检查是否有无效的buf请求 ..................................................................................................296 对请求进行排队 .......................................................................................................................296 开始第一个传输 .......................................................................................................................297 处理中断的设备 .......................................................................................................................298 目录 编写设备驱动程序 • 2010年9月 10 dump()和print()入口点 ..............................................................................................................299 dump()入口点(块驱动程序) .............................................................................................300 print()入口点(块驱动程序)...........................................................................................300 磁盘设备驱动程序 ..........................................................................................................................300 磁盘ioctl ..................................................................................................................................301 磁盘性能 ....................................................................................................................................301 17 SCSI目标驱动程序 ...........................................................................................................................303 目标驱动程序介绍 ..........................................................................................................................303 Sun公用SCSI体系结构概述 .........................................................................................................304 常规控制流程 ............................................................................................................................305 SCSA函数 ..................................................................................................................................305 硬件配置文件 ...................................................................................................................................306 声明和数据结构 ...............................................................................................................................307 scsi_device结构 .....................................................................................................................307 scsi_pkt结构(目标驱动程序) ........................................................................................308 SCSI目标驱动程序的自动配置 ....................................................................................................309 probe()入口点(SCSI目标驱动程序) .............................................................................310 attach()入口点(SCSI目标驱动程序) ...........................................................................311 detach()入口点(SCSI目标驱动程序) ...........................................................................314 getinfo()入口点(SCSI目标驱动程序).........................................................................314 资源分配 ............................................................................................................................................315 scsi_init_pkt()函数 .............................................................................................................315 scsi_sync_pkt()函数 .............................................................................................................316 scsi_destroy_pkt()函数 ......................................................................................................316 scsi_alloc_consistent_buf()函数 ...................................................................................316 scsi_free_consistent_buf()函数......................................................................................317 生成和传输命令 ...............................................................................................................................317 生成命令 ....................................................................................................................................317 设置目标功能 ............................................................................................................................318 传输命令 ....................................................................................................................................318 命令完成 ....................................................................................................................................319 重新使用包 ................................................................................................................................320 自动请求检测模式 ...................................................................................................................321 转储处理 ....................................................................................................................................322 目录 11 SCSI选项 ...........................................................................................................................................324 18 SCSI主机总线适配器驱动程序 .....................................................................................................327 主机总线适配器驱动程序介绍 ....................................................................................................327 SCSI接口 ...........................................................................................................................................328 SCSAHBA接口 ................................................................................................................................329 SCSAHBA入口点摘要 ...........................................................................................................329 SCSAHBA数据结构 ................................................................................................................330 按目标实例的数据 ...................................................................................................................335 传输结构克隆 ............................................................................................................................336 SCSAHBA函数 .........................................................................................................................337 HBA驱动程序的相关性和配置问题 ...........................................................................................338 声明和结构 ................................................................................................................................338 模块初始化入口点 ...................................................................................................................339 自动配置入口点 .......................................................................................................................341 SCSAHBA驱动程序入口点 ..........................................................................................................344 目标驱动程序实例初始化 ......................................................................................................345 资源分配 ....................................................................................................................................347 命令传输 ....................................................................................................................................356 功能管理 ....................................................................................................................................362 中止和重置管理 .......................................................................................................................366 动态重新配置 ............................................................................................................................368 SCSIHBA驱动程序特定问题 .......................................................................................................369 安装HBA驱动程序 .................................................................................................................369 HBA配置属性 ...........................................................................................................................370 x86目标驱动程序配置属性 ...................................................................................................371 排队支持 ............................................................................................................................................372 19 网络设备驱动程序 .......................................................................................................................... 373 GLDv3网络设备驱动程序框架 ....................................................................................................373 GLDv3MAC注册 .....................................................................................................................373 GLDv3功能 ...............................................................................................................................377 GLDv3数据路径 .......................................................................................................................380 GLDv3状态更改通知 ..............................................................................................................382 GLDv3网络统计信息 ..............................................................................................................382 目录 编写设备驱动程序 • 2010年9月 12 GLDv3属性 ...............................................................................................................................383 GLDv3接口汇总 .......................................................................................................................384 GLDv2网络设备驱动程序框架 ....................................................................................................386 GLDv2设备支持 .......................................................................................................................387 GLDv2DLPI提供者 .................................................................................................................388 GLDv2DLPI原语 .....................................................................................................................389 GLDv2I/O控制函数 ................................................................................................................390 GLDv2驱动程序需求 ..............................................................................................................391 GLDv2网络统计信息 ..............................................................................................................392 GLDv2声明和数据结构..........................................................................................................395 GLDv2函数参数 .......................................................................................................................399 GLDv2入口点 ...........................................................................................................................400 GLDv2返回值 ...........................................................................................................................403 GLDv2服务例程 .......................................................................................................................403 20 USB驱动程序.....................................................................................................................................407 Solaris环境中的USB .......................................................................................................................407 USBA2.0框架 ............................................................................................................................407 USB客户机驱动程序 ...............................................................................................................408 绑定客户机驱动程序 ......................................................................................................................410 USB设备如何显示在系统中 .................................................................................................410 USB设备和Solaris设备树 ......................................................................................................410 兼容设备名称 ............................................................................................................................410 具有多个接口的设备...............................................................................................................412 检查设备驱动程序绑定 ..........................................................................................................413 基本设备访问 ...................................................................................................................................413 连接客户机驱动程序之前 ......................................................................................................413 描述符树 ....................................................................................................................................413 注册驱动程序以获取设备访问权限 ....................................................................................415 设备通信 ............................................................................................................................................416 USB端点.....................................................................................................................................416 缺省管道 ....................................................................................................................................417 管道状态 ....................................................................................................................................417 打开管道 ....................................................................................................................................417 关闭管道 ....................................................................................................................................418 目录 13 数据传输 ....................................................................................................................................418 刷新管道 ....................................................................................................................................424 设备状态管理 ...................................................................................................................................424 热插拔USB设备.......................................................................................................................425 电源管理 ....................................................................................................................................427 序列化 .........................................................................................................................................431 实用程序函数 ...................................................................................................................................431 设备配置工具 ............................................................................................................................431 其他实用程序函数 ...................................................................................................................433 USB设备驱动程序样例 ..................................................................................................................434 第3部分 生成设备驱动程序 ...........................................................................................................................435 21 编译、装入、打包和测试驱动程序............................................................................................ 437 驱动程序开发摘要 ..........................................................................................................................437 驱动程序代码布局 ..........................................................................................................................438 头文件 .........................................................................................................................................438 源文件 .........................................................................................................................................439 配置文件 ....................................................................................................................................439 准备安装驱动程序 ..........................................................................................................................440 编译和链接驱动程序...............................................................................................................440 模块相关性 ................................................................................................................................441 编写硬件配置文件 ...................................................................................................................442 安装、更新和删除驱动程序 .........................................................................................................442 将驱动程序复制到模块目录 .................................................................................................442 使用add_drv安装驱动程序...................................................................................................443 更新驱动程序信息 ...................................................................................................................444 删除驱动程序 ............................................................................................................................444 装入和卸载驱动程序 ......................................................................................................................444 驱动程序打包 ...................................................................................................................................445 软件包后安装 ............................................................................................................................445 软件包预删除 ............................................................................................................................446 驱动程序测试条件 ..........................................................................................................................447 配置测试 ....................................................................................................................................447 功能测试 ....................................................................................................................................447 目录 编写设备驱动程序 • 2010年9月 14 错误处理 ....................................................................................................................................447 测试装入和卸载 .......................................................................................................................448 压力、性能和互操作性测试 .................................................................................................448 DDI/DKI兼容性测试 ..............................................................................................................449 安装和打包测试 .......................................................................................................................449 测试特定类型驱动程序 ..........................................................................................................449 22 调试、测试和调优设备驱动程序 ................................................................................................ 451 测试驱动程序 ...................................................................................................................................451 启用Deadman功能以避免硬挂起 .......................................................................................451 使用串行连接进行测试 ..........................................................................................................452 设置测试模块 ............................................................................................................................454 避免测试系统中发生数据丢失 .............................................................................................456 恢复设备目录 ............................................................................................................................458 调试工具 ............................................................................................................................................459 事后调试 ....................................................................................................................................460 使用kmdb内核调试程序 .........................................................................................................460 使用mdb模块调试程序 ...........................................................................................................463 使用kmdb和mdb执行的有用调试任务 ...............................................................................464 调优驱动程序 ...................................................................................................................................471 内核统计信息 ............................................................................................................................471 用于动态检测过程的DTrace.................................................................................................476 23 推荐的编码方法 ............................................................................................................................... 477 调试准备方法 ...................................................................................................................................477 使用唯一前缀来避免内核符号冲突 ....................................................................................477 使用cmn_err()记录驱动程序活动......................................................................................478 使用ASSERT()捕捉无效假设 ................................................................................................478 使用mutex_owned()验证和记录锁定要求 .........................................................................478 使用条件编译在开销较大的调试功能之间切换 ..............................................................479 将变量声明为可变变量..................................................................................................................480 可维护性 ............................................................................................................................................481 定期运行状况检查 ...................................................................................................................4813 471浏览会员免费
- 目录 Chapter 1 Installing the Solaris 10 Operating System 1 1.1 Methods to Meet Your Needs 1 1.2 The Basics of Solaris Installation 2 1.2.1 Installing Solaris on a SPARC System 6 1.2.2 Installing Solaris on an x86 System 9 1.3 Solaris JumpStart Installation 13 1.3.1 Setting up a JumpStart Server 13 1.3.2 Creating a Pro?le Server for Networked Systems 14 1.3.3 Performing a Custom JumpStart Installation 22 1.4 Upgrading a Solaris System 25 1.5 Solaris Live Upgrade 26 Chapter 2 Boot, Service Management, and Shutdown 33 2.1 Boot 33 2.1.1 The Bootloader 33 2.1.2 The Kernel 34 2.1.3 User-Mode Programs 34 2.1.4 GRUB Extensions 35 2.1.5 Modifying Boot Behavior 36 2.1.6 Run Levels 37 2.1.7 Troubleshooting 37 2.2 Service Management Facility 39 2.2.1 enabled 40 2.2.2 state, next_state, and state_time 40 2.2.3 logfile 41 2.2.4 dependency 41 2.2.5 How SMF Interacts with Service Implementations 42 2.2.6 The Service Con?guration Facility 44 2.2.7 Health and Troubleshooting 44 2.2.8 Service Manifests 45 2.2.9 Backup and Restore of SCF Data 45 2.3 Shutdown 46 2.3.1 Application-Speci?c Shutdown 46 2.3.2 Application-Independent Shutdown 46 Chapter 3 Software Management: Packages 47 3.1 Managing Software Packages 47 3.2 What Is a Package? 47 3.2.1 SVR4 Package Content 48 3.2.2 Package Naming Conventions 49 3.3 Tools for Managing Software Packages 49 3.4 Installing or Removing a Software Package with the pkgadd or pkgrm Command 50 3.5 Using Package Commands to Manage Software Packages 51 3.5.1 How to Install Packages with the pkgadd Command 51 3.5.2 Adding Frequently Installed Packages to a Spool Directory 54 3.5.3 Removing Software Packages 56 Chapter 4 Software Management: Patches 59 4.1 Managing Software with Patches 59 4.2 What Is a Patch? 59 4.2.1 Patch Content 60 4.2.2 Patch Numbering 61 4.3 Patch Management Best Practices 61 4.3.1 Proactive Patch Management Strategy 62 4.3.2 Reactive Patch Management Strategy 68 4.3.3 Security Patch Management Strategy 70 4.3.4 Proactive Patching When Installing a New System 71 4.3.5 Identifying Patches for Proactive Patching and Accessing Patches 73 4.4 Example of Using Solaris Live Upgrade to Install Patches 75 4.4.1 Overview of Patching with Solaris Live Upgrade 75 4.4.2 Planning for Using Solaris Live Upgrade 77 4.4.3 How to Apply a Patch When Using Solaris Live Upgrade for the Solaris 10 8/07 Release 79 4.5 Patch Automation Tools 86 4.6 Overview of Patch Types 88 4.7 Patch README Special Instructions 93 4.7.1 When to Patch in Single-User Mode 93 4.7.2 When to Reboot After Applying or Removing a Patch 94 4.7.3 Patch Metadata for Non-Global Zones 95 4.8 Patch Dependencies (Interrelationships) 96 4.8.1 SUNW_REQUIRES Field for Patch Dependencies 96 4.8.2 SUNW_OBSOLETES Field for Patch Accumulation and Obsolescence 97 4.8.3 SUNW_INCOMPAT Field for Incompatibility 97 Chapter 5 Solaris File Systems 99 5.1 Solaris File System Overview 99 5.1.1 Mounting File Systems 100 5.1.2 Unmounting File Systems 102 5.1.3 Using the /etc/vfstab File 103 5.1.4 Determining a File System Type 104 5.1.5 Monitoring File Systems 105 5.2 UFS File Systems 105 5.2.1 Creating a UFS File System 106 5.2.2 Backing Up and Restoring UFS File Systems 107 5.2.3 Using Quotas to Manage Disk Space 108 5.2.4 Checking File System Integrity 110 5.2.5 Using Access Control Lists 112 5.2.6 Using UFS Logging 113 5.2.7 Using Extended File Attributes 115 5.2.8 Using Multiterabyte UFS File Systems 115 5.2.9 Creating UFS Snapshots 115 5.3 ZFS File System Administration 117 5.3.1 Using Pools and File Systems 118 5.3.2 Backing Up a ZFS File System 120 5.3.3 Using Mirroring and Striping 121 5.3.4 Using RAID-Z 122 5.3.5 Using Copy-on-Write and Snapshots 122 5.3.6 Using File Compression 124 5.3.7 Measuring Performance 124 5.3.8 Expanding a Pool 125 5.3.9 Checking a Pool 126 5.3.10 Replacing a Disk 127 5.4 NFS File System Administration 127 5.4.1 Finding Available NFS File Systems 128 5.4.2 Mounting an NFS File System 129 5.4.3 Unmounting an NFS File System 129 5.4.4 Con?guring Automatic File System Sharing 130 5.4.5 Automounting File Systems 130 5.5 Removable Media 133 5.5.1 Using the PCFS File System 135 5.5.2 Using the HSFS File System 136 5.6 Pseudo File System Administration 136 5.6.1 Using Swap Space 136 5.6.2 Using the TMPFS File System 138 5.6.3 Using the Loopback File System 139 Chapter 6 Managing System Processes 141 6.1 Overview 141 6.1.1 State of a Process 143 6.1.2 Process Context 143 6.2 Monitoring the Processes 145 6.2.1 Process Status: ps 146 6.2.2 Grepping for Process: pgrep 149 6.2.3 Process Statistics Summary: prstat 149 6.2.4 Reap a Zombie Process: preap 151 6.2.5 Temporarily Stop a Process: pstop 152 6.2.6 Resuming a Suspended Process: prun 152 6.2.7 Wait for Process Completion: pwait 152 6.2.8 Process Working Directory: pwdx 152 6.2.9 Process Arguments: pargs 152 6.2.10 Process File Table: pfiles 153 6.2.11 Process Libraries: pldd 154 6.2.12 Process Tree: ptree 154 6.2.13 Process Stack: pstack 155 6.2.14 Tracing Process: truss 156 6.3 Controlling the Processes 158 6.3.1 The nice and renice Commands 158 6.3.2 Signals 159 6.4 Process Manager 164 6.5 Scheduling Processes 170 6.5.1 cron Utility 171 6.5.2 The at Command 175 Chapter 7 Fault Management 179 7.1 Overview 179 7.2 Fault Noti?cation 181 7.3 Displaying Faults 182 7.4 Repairing Faults 184 7.5 Managing Fault Management Log Files 184 7.5.1 Automatic Log Rotation 185 7.5.2 Manual Log Rotation 186 7.5.3 Log Rotation Failures 187 7.5.4 Examining Historical Log Files 188 7.6 Managing fmd and fmd Modules 188 7.6.1 Loading and Unloading Modules 189 7.6.2 fmd Statistics 191 7.6.3 Con?guration Files 192 7.7 Fault Management Directories 193 7.8 Solaris Fault Management Downloadable Resources 193 7.8.1 Solaris FMA Demo Kit 193 7.8.2 Events Registry 194 Chapter 8 Managing Disks 197 8.1 Hard Disk Drive 197 8.2 Disk Terminology 199 8.3 Disk Device Naming Conventions 200 8.3.1 Specifying the Disk Subdirectory in Commands 202 8.4 Overview of Disk Management 202 8.4.1 Device Driver 202 8.4.2 Disk Labels (VTOC or EFI) 203 8.4.3 Disk Slices 205 8.4.4 Slice Arrangements on Multiple Disks 207 8.4.5 Partition Table 208 8.4.6 format Utility 210 8.4.7 format Menu and Command Descriptions 211 8.4.8 Partition Menu 213 8.4.9 x86: fdisk Menu 214 8.4.10 Analyze Menu 215 8.4.11 Defect Menu 217 8.5 Disk Management Procedures 217 8.5.1 How to Identify the Disks on a System 218 8.5.2 How to Determine If a Disk Is Formatted 218 8.5.3 How to Format a Disk 219 8.5.4 How to Identify a Defective Sector by Performing a Surface Analysis 221 8.5.5 How to Repair a Defective Sector 222 8.5.6 How to Display the Partition Table or Slice Information 223 8.5.7 Creating Disk Slices (Partitioning a Disk) and Labeling a Disk 224 8.5.8 Creating a File System On a Disk 228 8.5.9 Additional Commands to Manage Disks 229 Chapter 9 Managing Devices 235 9.1 Solaris Device Driver Introduction 235 9.2 Analyzing Lack of Device Support 236 9.2.1 Device Does Not Work 236 9.2.2 Obtaining Information About Devices 236 9.2.3 Obtaining Information About Drivers 241 9.2.4 Does the Device Have a Driver? 248 9.2.5 Current Driver Does Not Work 250 9.2.6 Can a Driver for a Similar Device Work? 250 9.3 Installing and Updating Drivers 251 9.3.1 Backing Up Current Functioning Driver Binaries 251 9.3.2 Package Installations 252 9.3.3 Install Time Updates 252 9.3.4 Manual Driver Binary Installation 253 9.3.5 Adding a Device Driver to a Net Installation Image 256 9.3.6 Adding a Device Driver to a CD/DVD Installation Image 262 9.3.7 Swapping Disks 263 9.4 When Drivers Hang or Panic the System 266 9.4.1 Device Driver Causes the System to Hang 266 9.4.2 Device Driver Causes the System to Panic 268 9.4.3 Device Driver Degrades System Performance 269 9.5 Driver Administration Commands and Files 270 9.5.1 Driver Administration Command Summary 270 9.5.2 Driver Administration File Summary 272 Chapter 10 Solaris Networking 275 10.1 Introduction to Network Con?guration 275 10.1.1 Overview of the TCP/IP Networking Stack 275 10.1.2 Con?guring the Network as Superuser 277 10.2 Setting Up a Network 277 10.2.1 Components of the XYZ, Inc. Network 277 10.2.2 Con?guring the Sales Domain 280 10.2.3 Con?guring the Accounting Domain 283 10.2.4 Con?guring the Multihomed Host 288 10.2.5 Setting Up a System for Static Routing 296 10.2.6 Con?guring the Corporate Domain 300 10.2.7 Testing the Network Con?guration 302 10.3 Monitoring Network Performance 304 10.3.1 dladm Command 304 10.3.2 ifconfig Command 305 10.3.3 netstat Command 305 10.3.4 snoop Command 307 10.3.5 traceroute Command 308 Chapter 11 Solaris User Management 309 11.1 Solaris Users, Groups, and Roles 309 11.1.1 File System Object Permissions 310 11.1.2 User Account Components 312 11.1.3 User Management Tools 313 11.1.4 User Management Files 313 11.2 Managing Users and Groups 314 11.2.1 Starting the Solaris Management Console 314 11.2.2 Adding a Group and a User to Local Files 315 11.2.3 Adding a Group and a User to an NIS Domain 317 11.3 Managing Roles 318 11.3.1 Changing root from a User to a Role 318 11.3.2 Viewing the List of Roles 319 11.3.3 Assigning a Role to a Local User 319 Chapter 12 Solaris Zones 321 12.1 Overview 321 12.2 How Zones Work 323 12.3 Branded Zones 324 12.4 Network Interfaces in Zones 324 12.5 Devices in Zones 325 12.6 Packages and Patches in a Zones Environment 325 12.7 Administering Zones 326 12.7.1 Zone Con?guration 327 12.7.2 Viewing a Zone Con?guration 331 12.7.3 Zone Installation and Booting 331 12.7.4 Zone Login Using the zlogin Command 332 12.8 Halting, Uninstalling, Moving, and Cloning Zones 333 12.9 Migrating a Zone to a New System 334 12.10 Deleting a Zone 336 12.11 Listing the Zones on a System 336 12.12 Zones Usage Examples 337 12.12.1 Adding a Dedicated Device to a Non-Global Zone 337 12.12.2 How to Export Home Directories in the Global Zone into a Non-Global Zone 337 12.12.3 Altering Privileges in a Non-Global Zone 337 12.12.4 Checking the Status of SMF Services 338 12.12.5 Modifying CPU, Swap, and Locked Memory Caps in Zones 338 12.12.6 Using the Dtrace Program in a Non-Global Zone 339 Chapter 13 Using Naming Services 341 13.1 Using Naming Services (DNS, NIS, AND LDAP) 341 13.1.1 Naming Service Cache Daemon (nscd) 342 13.1.2 DNS Naming Services 342 13.1.3 NIS Naming Services 342 13.1.4 LDAP Naming Services 343 13.1.5 Organizational Use of Naming Services 343 13.1.6 Network Database Sources 344 13.2 Name Service Switch File 347 13.2.1 Con?guring the Name Service Switch File 347 13.2.2 Database Status and Actions 349 13.3 DNS Setup and Con?guration 350 13.3.1 Resolver Files 350 13.3.2 Steps DNS Clients Use to Resolve Names 350 13.4 NIS Setup and Con?guration 351 13.4.1 Setting Up NIS Clients 351 13.4.2 Working with NIS Maps 352 13.5 LDAP Setup and Con?guration 356 13.5.1 Initializing a Client Using Per-User Credentials 357 13.5.2 Con?guring an LDAP Client 359 13.5.3 Using Pro?les to Initialize an LDAP Client 362 13.5.4 Using Proxy Credentials to Initialize an LDAP Client 362 13.5.5 Initializing an LDAP Client Manually 363 13.5.6 Modifying a Manual LDAP Client Con?guration 363 13.5.7 Troubleshooting LDAP Client Con?guration 364 13.5.8 Uninitializing an LDAP Client 364 13.5.9 Initializing the Native LDAP Client 364 13.5.10 LDAP API Entry Listings 368 13.5.11 Troubleshooting Name Service Information 368 Chapter 14 Solaris Print Administration 369 14.1 Overview of the Solaris Printing Architecture 369 14.2 Key Concepts 370 14.2.1 Printer Categories (Local and Remote Printers) 370 14.2.2 Printer Connections (Directly Attached and Network Attached) 370 14.2.3 Description of a Print Server and a Print Client 371 14.3 Solaris Printing Tools and Services 371 14.3.1 Solaris Print Manager 371 14.3.2 LP Print Service 371 14.3.3 PostScript Printer De?nitions File Manager 372 14.4 Network Protocols 372 14.4.1 Berkeley Software Distribution Protocol 372 14.4.2 Transmission Control Protocol 372 14.4.3 Internet Printing Protocol 373 14.4.4 Server Message Block Protocol 373 14. 5 Planning for Printer Setup 373 14. 5.1 Print Server Requirements 373 14. 5.2 Locating Information About Supported Printers 374 14. 5.3 Locating Information About Available PPD Files 375 14. 5.4 Adding a New PPD File to the System 375 14. 5.5 Adding Printers in a Naming Service 377 14. 5.6 Printer Support in the Naming Service Switch 377 14. 5.7 Enabling Network Listening Services 378 14.6 Setting Up Printers with Solaris Printer Manager 379 14.6.1 Assigning Printer De?nitions 379 14.6.2 Starting Solaris Print Manager 380 14.6.3 Setting Up a New Directly Attached Printer With Solaris Print Manager 381 14.6.4 Setting Up a New Network-Attached Printer with Solaris Print Manager 381 14.7 Setting Up a Printer on a Print Client with Solaris Print Manager 385 14.7.1 Adding Printer Access With Solaris Print Manager 385 14.8 Administering Printers by Using LP Print Commands 385 14.8.1 Frequently Used LP Print Commands 386 14.8.2 Using the lpstat Command 386 14.8.3 Disabling and Enabling Printers 387 14.8.4 Accepting or Rejecting Print Requests 387 14.8.5 Canceling a Print Request 388 14.8.6 Moving Print Requests from One Printer to Another Printer 389 14.8.7 Deleting a Printer 390 14.9 Troubleshooting Printing Problems 392 14.9.1 Troubleshooting No Output (Nothing Prints) 392 14.9.2 Checking That the Print Scheduler Is Running 393 14.9.3 Debugging Printing Problems 393 14.9.4 Checking the Printer Network Connections 394 Index 3955 145浏览会员免费
- Solaris_10系统安装图解,详细!易懂!5 138浏览会员免费
- 对SUN——M5000小机通过XSCF进行详细的配置和管理,有实例教程。4 465浏览会员免费
- Solaris培训 Solaris培训 Solaris培训 Solaris培训 Solaris培训4 105浏览会员免费
- solaris 11介绍,请大家详细阅读!!4 397浏览会员免费
- 不需要Solaris 10 X86的操作系统光盘,图文详细教程,一步一步_带你进入单用户模式,很详细,每步都有截图。0 683浏览会员免费
- 文档 solaris0 614浏览会员免费
- Solaris 基础知识Solaris 基础知识Solaris 基础知识Solaris 基础知识0 78浏览会员免费
- simics + Solaris 构建多核系统仿真,对程序进行优化。5 79浏览会员免费
- Oracle_11g_R2_RAC集群系统在_Solaris10_x86_64_上的安装 欢迎下载5 66浏览会员免费
- solaris安装 Solaris11安装 zfs安装 Solaris安装图解 solaris配置4 113浏览会员免费
- Solaris 10性能调整手册 英文原版 适合有一定经验的系统管理员参考使用0 80浏览会员免费
- solaris系统管理指南(高级管理),还不错!0 65浏览会员免费
- 罗列Solaris命令,经过简单分类,适合Solaris的快速入门5 75浏览会员免费
- veritas多路径软件手册,详细介绍veritas多路径的使用及配置0 120浏览会员免费
- Sun Cluster 概念指南(适用于 Solaris OS)5 74浏览会员免费
- \智能抄表系统现状与发展.pdf )0 108浏览会员免费
- solaris 10的 samba配置网络共享和网络配置0 149浏览会员免费
- Veritas Storage Foundation best pratice for oracle rac0 98浏览会员免费
- Oracle Solaris 开发者 文档 介绍0 90浏览会员免费
- Introduce Oracle Cluster and Geographic edition0 69浏览会员免费
- sun 440 的diagnostics 和troubleshooting,很好的资料5 123浏览会员免费
- Virtual Machine Based Heterogeneous Checkpointing.pdf0 84浏览会员免费
- zfs管理 zfs命令 zfs特性 zfs快照 oracle Solaris zfs 文件系统 oracle Solaris zfs 存储池5 291浏览会员免费
- E26642-01 SPARC T4系列服务器管理指南.pdf E26642-01 SPARC T4系列服务器管理指南.pdf5 152浏览会员免费
- sun solaris10 installation guide0 87浏览会员免费
- 自己找的HPUX硬件系统巡检命令,通过这些命令可以对系统进行全面体检,也可以写成shell脚本自动运行。0 384浏览会员免费
- 经典的UNIX书籍,solaris系统管理员必备,赶快下载!!0 180浏览会员免费
- Sun Cluster 的高可用环境可确保最终用户能够使用关键的应用程序。系统管理员的职责 就是保证Sun Cluster 的稳定性和可操作性。0 113浏览会员免费
- 《Solaris ZFS 管理指南》提供有关设置和管理SolarisTM ZFS 文件系统的信 本指南适用于对设置和管理Solaris ZFS 文件系统感兴趣的任何用户。最好具有使用 Solaris 操作系统(Operating System, OS) 或其他UNIX® 版本的经验0 204浏览会员免费
- 详细的oracle solaris ZFS文件系统管理4 206浏览会员免费
- solaris文件系统,ZFS,设备和文件,管理服务和故障等solaris知识的中文文档0 148浏览会员免费
- 本书的结构 《Solaris Volume Manager 管理指南》包含以下信息: 第1 章提供本书中介绍的概念和任务的详细“汇总信息”。使用本章作为本书内容的导航帮 助。 第2 章向初学此技术的读者介绍一般存储管理概念。 第3 章介绍Solaris Volume Manager。本章介绍与产品相关的基本概念并说明如何访问Solaris Volume Manager 工具。 .............3 75浏览会员免费
- DTrace是一个用于SolarisTM操作系统的全面的动态跟踪框架。DTrace提供一个强大的基础结构,使管理员、开发者和服务人员能简明地回答有关操作系统和用户程序行为的任意问题。《Solaris动态跟踪指南》介绍如何使用DTrace观察、调试和调优系统行为。本书还包含一套完整的关于捆绑的DTrace观察工具和D编程语言的参考资料。 目录 前言........................................................................................................................................................21 1 简介........................................................................................................................................................25 入门 ....................................................................................................................................................... 25 提供器和探测器 ................................................................................................................................. 27 编译和检测过程 ................................................................................................................................. 29 变量和算术表达式 ............................................................................................................................ 30 谓词 ....................................................................................................................................................... 33 输出格式化.......................................................................................................................................... 36 数组 ....................................................................................................................................................... 39 外部符号和类型 ................................................................................................................................. 41 2 类型、运算符和表达式.....................................................................................................................43 标识符名称和关键字 ........................................................................................................................ 43 数据类型和大小 ................................................................................................................................. 44 常量 ....................................................................................................................................................... 46 算术运算符.......................................................................................................................................... 47 关系运算符.......................................................................................................................................... 48 逻辑运算符.......................................................................................................................................... 48 按位运算符.......................................................................................................................................... 49 赋值运算符.......................................................................................................................................... 50 递增和递减运算符 ............................................................................................................................ 51 条件表达式.......................................................................................................................................... 51 类型转换 .............................................................................................................................................. 52 优先级 .................................................................................................................................................. 53 3 3 变量........................................................................................................................................................55 标量变量 .............................................................................................................................................. 55 关联数组 .............................................................................................................................................. 56 线程局部变量 ..................................................................................................................................... 57 子句局部变量 ..................................................................................................................................... 60 内置变量 .............................................................................................................................................. 62 外部变量 .............................................................................................................................................. 64 4 D程序结构 ...........................................................................................................................................67 探测器子句和声明 ............................................................................................................................ 67 探测器说明.......................................................................................................................................... 68 谓词 ....................................................................................................................................................... 69 操作 ....................................................................................................................................................... 69 C预处理程序的用法 ......................................................................................................................... 69 5 指针和数组...........................................................................................................................................71 指针和地址.......................................................................................................................................... 71 指针安全 .............................................................................................................................................. 72 数组声明和存储 ................................................................................................................................. 73 指针和数组关系 ................................................................................................................................. 74 指针运算 .............................................................................................................................................. 75 通用指针 .............................................................................................................................................. 76 多维数组 .............................................................................................................................................. 76 指向DTrace对象的指针 .................................................................................................................. 77 指针和地址空间 ................................................................................................................................. 77 6 字符串 ...................................................................................................................................................79 字符串表示.......................................................................................................................................... 79 字符串常量.......................................................................................................................................... 80 字符串赋值.......................................................................................................................................... 80 字符串转换.......................................................................................................................................... 80 字符串比较.......................................................................................................................................... 81 目录 Solaris动态跟踪指南 • 2008年10月 4 7 结构和联合...........................................................................................................................................83 结构 ....................................................................................................................................................... 83 结构指针 .............................................................................................................................................. 85 联合 ....................................................................................................................................................... 89 成员大小和偏移 ................................................................................................................................. 92 位字段 .................................................................................................................................................. 92 8 类型和常量定义 ..................................................................................................................................95 Typedef ................................................................................................................................................. 95 枚举 ....................................................................................................................................................... 96 内置 ....................................................................................................................................................... 97 类型名称空间 ..................................................................................................................................... 98 9 聚合..................................................................................................................................................... 101 聚合函数 ............................................................................................................................................101 聚合 .....................................................................................................................................................102 列显聚合 ............................................................................................................................................109 数据标准化........................................................................................................................................109 清除聚合 ............................................................................................................................................113 截断聚合 ............................................................................................................................................114 最小化删除........................................................................................................................................115 10 操作和子例程 ................................................................................................................................... 117 操作 .....................................................................................................................................................117 缺省操作 ............................................................................................................................................117 数据记录操作 ...................................................................................................................................118 trace() .......................................................................................................................................118 tracemem() .................................................................................................................................119 printf() .....................................................................................................................................119 printa() .....................................................................................................................................119 stack() .......................................................................................................................................119 ustack() .....................................................................................................................................121 jstack() .....................................................................................................................................125 破坏性操作........................................................................................................................................125 目录 5 处理破坏性操作 .......................................................................................................................125 内核破坏性操作 .......................................................................................................................128 特殊操作 ............................................................................................................................................131 推理操作 ....................................................................................................................................131 exit() .........................................................................................................................................131 子例程 ................................................................................................................................................131 alloca() .....................................................................................................................................131 basename() .................................................................................................................................131 bcopy() .......................................................................................................................................132 cleanpath() ...............................................................................................................................132 copyin() .....................................................................................................................................132 copyinstr() ...............................................................................................................................132 copyinto() .................................................................................................................................133 dirname() ...................................................................................................................................133 msgdsize() .................................................................................................................................133 msgsize() ...................................................................................................................................133 mutex_owned() ...........................................................................................................................133 mutex_owner() ...........................................................................................................................134 mutex_type_adaptive() ..........................................................................................................134 progenyof() ...............................................................................................................................134 rand() .........................................................................................................................................134 rw_iswriter() ...........................................................................................................................135 rw_write_held() ......................................................................................................................135 speculation() ...........................................................................................................................135 strjoin() ...................................................................................................................................135 strlen() .....................................................................................................................................135 11 缓冲区和缓冲 ................................................................................................................................... 137 主体缓冲区........................................................................................................................................137 主体缓冲区策略 ...............................................................................................................................137 switch策略 ................................................................................................................................138 fill策略 ....................................................................................................................................138 ring策略 ....................................................................................................................................139 其他缓冲区........................................................................................................................................140 缓冲区大小........................................................................................................................................140 目录 Solaris动态跟踪指南 • 2008年10月 6 缓冲区调整大小策略 ......................................................................................................................140 12 输出格式化........................................................................................................................................ 143 printf() .............................................................................................................................................143 转换规范 ....................................................................................................................................144 标志说明符 ................................................................................................................................144 宽度和精度说明符 ...................................................................................................................145 大小前缀 ....................................................................................................................................145 转换格式 ....................................................................................................................................146 printa() .............................................................................................................................................147 trace()缺省格式 ............................................................................................................................149 13 推理跟踪 ............................................................................................................................................ 151 推理接口 ............................................................................................................................................151 创建推理 ............................................................................................................................................152 使用推理 ............................................................................................................................................152 提交推理 ............................................................................................................................................153 放弃推理 ............................................................................................................................................153 推理示例 ............................................................................................................................................154 推理选项和调整 ...............................................................................................................................158 14 dtrace(1M)实用程序 .......................................................................................................................161 说明 .....................................................................................................................................................161 选项 .....................................................................................................................................................161 操作数 ................................................................................................................................................166 退出状态 ............................................................................................................................................166 15 脚本..................................................................................................................................................... 167 解释程序文件 ...................................................................................................................................167 宏变量 ................................................................................................................................................168 宏参数 ................................................................................................................................................170 目标进程ID ......................................................................................................................................171 目录 7 16 选项和可调参数 ............................................................................................................................... 173 使用者选项........................................................................................................................................173 修改选项 ............................................................................................................................................175 17 dtrace提供器 ....................................................................................................................................177 BEGIN探测器 .....................................................................................................................................177 END探测器 .........................................................................................................................................178 ERROR探测器 .....................................................................................................................................178 稳定性 ................................................................................................................................................180 18 lockstat提供器................................................................................................................................181 概述 .....................................................................................................................................................181 自适应锁定探测器 ..........................................................................................................................181 旋转锁定探测器 ...............................................................................................................................182 线程锁定 ............................................................................................................................................183 读取器/写入器锁定探测器 ............................................................................................................183 稳定性 ................................................................................................................................................184 19 profile提供器 ..................................................................................................................................185 profile-n探测器 ............................................................................................................................185 tick-n探测器 ...................................................................................................................................188 参数 .....................................................................................................................................................188 计时器分辨率 ...................................................................................................................................188 探测器创建........................................................................................................................................190 稳定性 ................................................................................................................................................190 20 fbt提供器 ..........................................................................................................................................191 探测器 ................................................................................................................................................191 探测器参数........................................................................................................................................192 entry探测器 .............................................................................................................................192 return探测器 ...........................................................................................................................192 示例 .....................................................................................................................................................192 尾部调用优化 ...................................................................................................................................198 汇编函数 ............................................................................................................................................200 目录 Solaris动态跟踪指南 • 2008年10月 8 指令集限制........................................................................................................................................200 x86限制 ......................................................................................................................................200 SPARC限制................................................................................................................................200 断点交互 ............................................................................................................................................200 模块装入 ............................................................................................................................................201 稳定性 ................................................................................................................................................201 21 syscall提供器 ..................................................................................................................................203 探测器 ................................................................................................................................................203 系统调用记时错误 ...................................................................................................................203 子编码的系统调用 ...................................................................................................................203 大文件系统调用 .......................................................................................................................204 专用系统调用 ............................................................................................................................204 参数 .....................................................................................................................................................205 稳定性 ................................................................................................................................................205 22 sdt提供器 ..........................................................................................................................................207 探测器 ................................................................................................................................................207 示例 .....................................................................................................................................................208 创建SDT探测器 ..............................................................................................................................212 声明探测器 ................................................................................................................................212 探测器参数 ................................................................................................................................212 稳定性 ................................................................................................................................................212 23 sysinfo提供器 ..................................................................................................................................215 探测器 ................................................................................................................................................215 参数 .....................................................................................................................................................217 示例 .....................................................................................................................................................219 稳定性 ................................................................................................................................................221 24 vminfo提供器 ....................................................................................................................................223 探测器 ................................................................................................................................................223 参数 .....................................................................................................................................................225 示例 .....................................................................................................................................................225 目录 9 稳定性 ................................................................................................................................................229 25 proc提供器 ........................................................................................................................................231 探测器 ................................................................................................................................................231 参数 .....................................................................................................................................................233 lwpsinfo_t .................................................................................................................................233 psinfo_t .....................................................................................................................................236 示例 .....................................................................................................................................................237 exec..............................................................................................................................................237 start和exit .............................................................................................................................238 lwp-start和lwp-exit ............................................................................................................240 signal-send ...............................................................................................................................242 稳定性 ................................................................................................................................................243 26 sched提供器 ......................................................................................................................................245 探测器 ................................................................................................................................................245 参数 .....................................................................................................................................................247 cpuinfo_t ...................................................................................................................................248 示例 .....................................................................................................................................................248 on-cpu和off-cpu .....................................................................................................................248 enqueue和dequeue ..................................................................................................................256 sleep和wakeup .........................................................................................................................262 preempt、remain-cpu ..............................................................................................................270 change-pri .................................................................................................................................272 tick..............................................................................................................................................274 稳定性 ................................................................................................................................................276 27 io提供器 ............................................................................................................................................277 探测器 ................................................................................................................................................277 参数 .....................................................................................................................................................278 bufinfo_t结构 .........................................................................................................................278 devinfo_t ...................................................................................................................................280 fileinfo_t .................................................................................................................................280 示例 .....................................................................................................................................................281 目录 Solaris动态跟踪指南 • 2008年10月 10 稳定性 ................................................................................................................................................293 28 mib提供器 ..........................................................................................................................................295 探测器 ................................................................................................................................................295 参数 .....................................................................................................................................................307 稳定性 ................................................................................................................................................307 29 fpuinfo提供器 ..................................................................................................................................309 探测器 ................................................................................................................................................309 参数 .....................................................................................................................................................311 稳定性 ................................................................................................................................................311 30 pid提供器 ..........................................................................................................................................313 命名pid探测器 ................................................................................................................................313 函数边界探测器 ...............................................................................................................................314 entry探测器 .............................................................................................................................314 return探测器 ...........................................................................................................................315 函数偏移探测器 ...............................................................................................................................315 稳定性 ................................................................................................................................................315 31 plockstat提供器..............................................................................................................................317 概述 .....................................................................................................................................................317 互斥探测器........................................................................................................................................318 读取器/写入器锁定探测器 ............................................................................................................318 稳定性 ................................................................................................................................................319 32 fasttrap提供器................................................................................................................................321 探测器 ................................................................................................................................................321 稳定性 ................................................................................................................................................321 33 用户进程跟踪 ................................................................................................................................... 323 copyin()和copyinstr()子例程 .................................................................................................323 避免错误 ....................................................................................................................................324 目录 11 消除dtrace(1M)干扰 .....................................................................................................................325 syscall提供器 .................................................................................................................................325 ustack()操作 ...................................................................................................................................326 uregs[]数组 .....................................................................................................................................328 pid提供器 .........................................................................................................................................330 用户函数边界跟踪 ...................................................................................................................330 跟踪任意指令 ............................................................................................................................332 34 为用户应用程序静态定义跟踪 .................................................................................................... 335 选择探测器位置 ...............................................................................................................................335 向应用程序中添加探测器 .............................................................................................................336 定义提供器和探测器...............................................................................................................336 向应用程序代码中添加探测器 .............................................................................................337 生成包含探测器的应用程序 .................................................................................................337 35 安全性 ................................................................................................................................................ 339 权限 .....................................................................................................................................................339 使用DTrace的权限 .........................................................................................................................340 dtrace_proc权限 .............................................................................................................................340 dtrace_user权限 .............................................................................................................................341 dtrace_kernel权限 ........................................................................................................................342 超级用户权限 ...................................................................................................................................342 36 匿名跟踪 ............................................................................................................................................ 343 匿名启用 ............................................................................................................................................343 声明匿名状态 ...................................................................................................................................344 匿名跟踪示例 ...................................................................................................................................344 37 事后跟踪 ............................................................................................................................................ 349 显示DTrace使用者 .........................................................................................................................349 显示跟踪数据 ...................................................................................................................................350 38 性能注意事项 ................................................................................................................................... 353 限制已启用的探测器 ......................................................................................................................353 目录 Solaris动态跟踪指南 • 2008年10月 12 使用聚合 ............................................................................................................................................353 使用可高速缓存的谓词..................................................................................................................354 39 稳定性 ................................................................................................................................................ 357 稳定性级别........................................................................................................................................357 相关性类 ............................................................................................................................................359 接口属性 ............................................................................................................................................360 稳定性计算和报告 ..........................................................................................................................360 稳定性执行........................................................................................................................................362 40 转换器 ................................................................................................................................................ 365 转换器声明........................................................................................................................................365 转换运算符........................................................................................................................................367 进程模型转换器 ...............................................................................................................................368 稳定转换 ............................................................................................................................................368 41 版本控制 ............................................................................................................................................ 369 版本和发行版 ...................................................................................................................................369 版本控制选项 ...................................................................................................................................370 提供器版本控制 ...............................................................................................................................3710 109浏览会员免费
- solaris xscf_user_guide0 95浏览会员免费
- solaris shell编程官方教材,英文版,经典教材0 58浏览会员免费
- solaris操作系统基础培训讲义 第一章 solaris系统管理 第二章 sun cluster介绍 第三章 系统日常管理介绍 solaris系统管理 solaris硬盘管理 solaris文件系统管理 solaris网络配置与管理 solaris系统备份与恢复0 118浏览会员免费
- oracle solaris 11 zone0 125浏览会员免费
- 内容摘要:Solaris 11 即Solaris Express Developer Edition ,SXDE是完全免费的,每个季度发布一个新的版本,适合作为应用程序开发环境。5 287浏览会员免费
- 关于solaris操作系统的一本入门书籍,适合初学者,很不错的哟!0 83浏览会员免费
- solaris11管理员考试文档,想要考solaris11的可以看下这个0 84浏览会员免费
- solaris操作系统卷管理,主要是针对SVM卷组管理,建库,划分磁盘,格式化磁盘。没有原理讲解,属于借鉴的操作记录。。。0 175浏览会员免费
- 介绍了 SPARC架构服务器 的优势何在0 113浏览会员免费