HP UNIX 系统管理 入门.doc

上传人:飞****2 文档编号:60196818 上传时间:2022-11-15 格式:DOC 页数:7 大小:59KB
返回 下载 相关 举报
HP UNIX 系统管理 入门.doc_第1页
第1页 / 共7页
HP UNIX 系统管理 入门.doc_第2页
第2页 / 共7页
点击查看更多>>
资源描述

《HP UNIX 系统管理 入门.doc》由会员分享,可在线阅读,更多相关《HP UNIX 系统管理 入门.doc(7页珍藏版)》请在得力文库 - 分享文档赚钱的网站上搜索。

1、HP UNIX系统管理笔记Important WebsiteHPs product website 进入后选择大型企业服务器按系统分类或按处理器分类找技术资料HPs IT Resource Center 可进入在线问答,英语(HP-UX);下载补丁HPs documentation website HPs software download website HP Education Services Unix系统基础Unix系统原理概述、SAM和SMH的介绍和使用1、 Launching the SAM GUI登录进入图形化界面(use SAM/SMH)只有系统管理员可以登录,用户名root#

2、echo SDISPLAN 开启虚拟终端#sam &打开SAM(5134课程3章CDE环境)并将进程切换至后台(14章)如直接输入SAM在字符界面用键盘选择操作2、V3版本中图形化系统管理Step1: #smhstartconfig a on b off 修改配置,-a on表示开启atuostart urls mode现用现调;-b off表示关闭start on boot modeStep2: #firefox :2301/ 调用浏览器或 #smhstartconfig a off b on#firefox https:/sername:23812381为加密端口,而2301为不加密端口3

3、、SMH可以自定义起始菜单,从tools里选取添加或卸载(在setting里add或remove)System Log Viewer: 查看过去登录的用户名last 查看过去登录但没成功的用户名last b用户组管理(RBAC):存在Administrator, Operator, User等不同的用户对象,分别拥有不同权限。4、SMH and SIM Integration Possibilities 集成化管理软件,SIM用WEB方式进行管理。User and Group Contet:每个用户至少要属于一个组,每个用户有且只有一个主要的组(主组);可以有多个属组及附属组。5、创建和管理用

4、户账户、文件系统高级原理1、用户账户What defines a user Account (with三个重要文件):1) PSWD:在/etc/passwd中,记录用户信息1 2 3 4 5 6 7Root: qmA8s.,8a3e: 0: 3: : /: /sbin/sh分配给系统自动调用的User1: adok60AazRgXU: 1001: 1001: 111-1111: /home/user1: /usr/bin/shUsername:Password: UID GID Comments Home Director Shell 用户ID组ID注释登录主目录 用户登录后的第一个执行程序

5、ROOT的UID为0(0100都是由系统自动分配的,管理员只能从101开始分配)Use /usr/sbin/wipw to edit /etc /passwdUse /usr/sbin/pwck to check the /etc/passwd file syntax核对语法,但是重复的UID查不出来2) /etc/shadow (optional可选的:strongly recommended to enable)r-只读User1: AdOK60XU: 12269:70: 140: 70: 35: : Encrypted Password Last Changed min days max

6、 day warn day Inactive day unused 最后一次更改时间,距1970-1-1有多少天Install the shadowPassword product (only necessary in 11i.V1)Use /usr/sbin/pwck to verify your current /etc/passwd file syntax核实语法Use /usr/sbin/pwconv to move passwords from /etc/passwd to /etc/shadow 更改至shadowUse /usr/sbin/pwunconv to move pas

7、swords back to /etc/password回改至etc的passwd3) /etc/group 默认只记录附属组Other: : 1: root,daemon,uucp,syncGroup GID MembersUse /usr/bin/vi to edit /etc/groupUse /usr/sbin/grpck to check the /etc/group file syntax2、 添加用户Step1:#useradd -o #allow a duplicate UID(不推荐,允许重复UID)-u 101 #define the UID(不推荐,定义用户ID为101)

8、-g users #define the primary group-G class,training #define secondary groups-c “student user” #define the comment field(添加注释信息)-m d /home/user1 #make a home directory for the user(自动添加登录主目录)-d /home/user1 表示自己指定主目录,可不用User-s /usr/bin/sh #define the default shell(定义)-e 1/2/09 #define an account expir

9、ation date(设置账号的生存日期)-p fnnmD.DGyptLU #specify an encrypted password(写在一个文件中)-t /etc/default/useradd #define the username(把一定的信息写进useradd模板,直接调用)User1;Step2:设置口令#passwd user1 #interactively specify a password or #passwd d user1 #set a null password(不推荐)#passwd f user1 #force a password change at fir

10、st login(强制首次登录改口令)口令设置三原则:用户口令不少于6位,至少包含2个英文字符,至少包含1个非英文字符(注意:password不加用户名是修改系统管理员的口令)实例:添加用户test01、test02Useradd m s /usr/bin/sh test01Passwd test01回车后输入口令Useradd g abc G users m s /usr/bin/sh test02 设置用户的主组与附属组3、 更改用户信息#usermod l user01 user1 #change the users username#usermod o u g G c m d s e

11、p #passwd user1更改用户密码4、阻止用户登录1)#passwd l user deactivate a user account锁定用户口令,用户永远不能再登录#passwd user1 reactivate a user account解锁2)#rm rf /home/user1 删除用户登录主目录3)#find / -user user1 type f exec rm i + 把所有属于user1(-user user1)的普通文件(type f)通篇搜出(find /)执行(exec +)删除(rm i) #find / -user user1 type d exec rm

12、dir + 把目录通篇删除4)#find / -user user1 exec chown user2 +把属于user1的文件全给user25、删除用户#userdel user1 Delete a user account but leave the users file untouched#userdel r user1 Delete a user account and remove the users home directory#find / -user user1 .#find / -nouser exec ll d + Find 无组无用户的文件ll为ls l全部列出list#

13、find / -nogroup exec ll d +6、Configuring Password Aging#passwd n 7 x 70 w 14 user1 #enable passwd aging for a user,数据必须是7的倍数(最小天等)-n最小时间x最大时间w警告时间#passwd s user1#check a users password status核实用户的时间设置#passwd sa #check the status of all users当把用户的min day设置得比max day还大时,为固化口令#vi /etc/default/security 设

14、置用户密码时间模板MIN_PASSWORD-LENGTH7、Managing Groups#goupadd g 200 accts 创建组#groupmod n accounts accts修改组#groupdel accounts删除组#usermod g users user1更改用户主组#usermod G class,training user1更改用户附组#groups user1查看用户user1都属于哪些组HPUNIX硬件HPUNIX硬件概述及架构原理、设备文件的配置和管理1、 Introducing the file System ParadigmStatic FilesExe

15、cutaties OS静态系统ApplicationLibrariesOSApplicationSystem strartupDynamic FilesConfigurationOS动态系统ApplicationTemporaryOSApplicationUser/root/opt默认安装软件目录,存储第三方应用,动态/app1、/app2静态/usr大概占到2/3,静态/sbin系统的启动脚本,静态/home根下的动态子目录,动态/etc根下,存储绝大部分配置文件,动态/stand存在操作系统的内核(可打补丁等),动态/tmp所有用户默认的临时文件,动态/dev存在设备文件,把ASCII码转

16、化为二进制信息,动态/mnt挂载软驱和光驱,用处不大,mount的意思,动态/varImportant,存在log, mail, news等大量动态内容,空间需求非常大,动态StaticDynamic/opt/etc/opt/应用程序的配置Bin, lib,share,newconfig/var/opt/ 更新日志2、 Commands to help you navigatefindsearches the file hierarchy查询文件层级whereisLocates source binaries and man pages 按环境变量path查看whichLocates an e

17、xecutable in you path显示执行命令所在路径fileDetermines file type查看文件的类型stringsDisplays ASCII characters in binary file用得少但重要,查看有乱码的文件实例:echo$path 查询所有的路径whereis ls查询路径中含有ls的命令返回ls:/usr/bin/lswhich ls返回/usr/bin/lsfile /etc/lvmtab由于存在ASCII字符,会显示乱码strings /etc/lvmtab整齐排列3、Hardware Components4、分驱nPars:Node Parti

18、tions(HP独有,以Cell板为单位划分,每个nPars是一个单独的系统,硬件分驱,可安装不同的系统)vPars:Virtual Partition(以CPU个数为单位划分,每个vPars是一个单独的系统,只装一个操作系统,只能隔绝软件错误,不能隔绝硬件错误)VMs:Integrity Virtual Machines(虚拟机) 云计算实现的趋势Secure Resource Partitions:给各种操作系统分配最高的百分资源FeaturenParsvParsVMsSecure Resource PartitionsCPU GranularityCellCPUSub-CPUCPU %a

19、geI/O GranularityI/O chassisLBASub-LBABandwidth %ageHW Fault IsolationYesNoNoNoOS Fault IsolationYesYesYesNoResource IsolationYesYesYesYesHW SupportCell-Based IA/PA ServersCell-Based IA/PA ServersAll IA ServersAll IA/PA ServersOS SupportHPUXWindows 2003LinuxOpen VMSHPUXHPUXWindows 2003LinuxOpen VMSH

20、PUX5、系统类型PA-RISC:HP9000 Superdoom系列hp9000 rp?4*ServersIPF:Integrity Superdome系列Integrity rx?6 *ServersIntegrity BL *c Blades刀片系列,未来趋势,方便管理磁盘设备管理硬件地址Agile View Hardware Addresses1、Legacy HBA Hardware Addresses 传统硬件地址总线级别:HBA hardware address 1/0/0/2/0高端机型 1 Cell / 0 SBA 系统总线/ 0 LBA本地总线 /2 device/func

21、tion /0PCI插槽编号2、Legacy Parallel SCSI Hardware Addresses 传统并行SCSI硬件地址1/0/0/2/0.1.01/0/0/2/0 HBA hardware address .1 Target端口(如有8个端口可接7个外设).0 LUN ID 磁盘阵列号3、 Legacy FC Hardware Addresses1/0/2/1/0.6.1.0.0.0.11/0/2/1/0 HBA hardware address 6.1.0. SAN domain/area/part光纤交换机0.0.1Array LAN ID逻辑端口号4、查看硬件地址(HP

22、专用)#ioscanshort listing of all devices#ioscan ffull listing of all devices主要查看硬件信息和软硬件的绑定信息#ioscan kffull listing, using cached information,立刻显示信息,从已扫描信息中输出#ioscan kfH 0/0/0/3/0full listing of all devices below 0/0/0/3/0#ioscan kfc diskfull listing of “disk” class devices实例:ioscan fClassIH/W PathDri

23、verS/W StateH/W TypeDescriptionRoot0RootClaimedBUS_NEXUS5、Viewing LUN Hardware Paths via Agile View查看虚拟灵活地址#ioscan kfNC disk查看disk类型的磁盘6、Viewing a LUNs LUnpaths via Agile View(V3版本列出虚拟灵活地址及真实地址)#ioscan m hwpath H 64000/Oxfa00/ox47、Viewing LUN Health via Agile View 看各个设备的运行状态#ioscan P health8、Viewing

24、 LUN Attributes via Agile View查看硬件信息、设置硬件状态信息(新加命令)#scsimgr get_attr a wwid H 64000/oxfa00/ox4 查看wwid在指定的地址中信息#scsimgr f disable 强制force关闭设备-H 真实灵活地址9、Viewing Slot Addresses 查看插槽地址#olrad q(V3)#mad q(1)10、EFI(PC的Bios) Address (安腾独有)#ioscan -e进入EFIboot manager调用EFI shell 可以查看EFI SCSI hardware address

25、address format格式:ACPI(vendor,cxx)/PCI(d|f)PCI设备号和功能/SCSI(PUNt,LUN1)硬件设置号和逻辑单元号/HD(Partp,id)硬盘号SCSI设备Fibre光纤阵列模拟出来的一块区域重点:传统地址灵活地址(真实灵活地址和灵活地址)EFI地址替换可热插拔及不可热插拔地址DSF设备文件 Device Special File#ll /dev/*disk/disk* 显示设备文件与普通文件区别:文件类型为bc block块设备文件,放在/dev/disk文件夹里 快;character字符设备文件,放在/dev/sdisk文件夹 慢一些多了Maj

26、or#主号一项定义设备所要调用的驱动程序的号多了Minor#一顼6位的16进制信息,定义逻辑设备的物理地址无size项11iV1,V2传统设备文件11iV3持久设备文件,路径无关性Legacy DSF Names#ioscan kf/dev/dsk/c#t#d#optionsPeristent DSF Names#ioscan kfNh/dev/disk/disk30options每一个路径代表一个设备只要是同一块盘,设备文件不变Partition Table1 System Partition (Partition)系统空间2 OS Partition 装操作系统3 Service Part

27、ition 工具存储空间4 Partition TableTape(8+4种)、terminal、modern、and Printer DSF names#ioscan n看传统设备文件#ioscan n N看持久设备文件(-N为看灵活地址)Correlating Persistent DSFs,WWIDs,and lunpaths#scsimgr lun_map D /dev/rdisk/disk30利用设备文件反查硬件地址详细信息Managing Device Files#insf创建设备文件,扫描所有设备,自动创建v1,v2#mksf少用到,创建#mknod常用,创建卷组的设备文件#mknod /dev/vg01/group c 64 0x 主号64、次号0x分配#rmsf v /dev/disk/disk1 (-a删所有,-L删所有传统设备文件)

展开阅读全文
相关资源
相关搜索

当前位置:首页 > 教育专区 > 教案示例

本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知得利文库网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

工信部备案号:黑ICP备15003705号-8 |  经营许可证:黑B2-20190332号 |   黑公网安备:91230400333293403D

© 2020-2023 www.deliwenku.com 得利文库. All Rights Reserved 黑龙江转换宝科技有限公司 

黑龙江省互联网违法和不良信息举报
举报电话:0468-3380021 邮箱:hgswwxb@163.com