soalris 命令以及sa239考点集锦( 二 )


cd2 of 2 中放了Developer, Entire Distribution, and Entire Distribution Plus OEM Support software groups.

(20),
安装软件包从光盘到系统中:
# pkgadd -d . SUNWns6m
(21),
查看软件安装状况:
# pkgchk SUNWcarx

加-v 参数可查看软件包安装在那些目录下放置了文件:
# pkgchk -v SUNWcarx

查看文件状态:
#pkgchk -p /etc/passwd
查看passwd文件什么时候软件包创建,最一次修改时间以及原始文件大小,及现在大小;
#pkgchk -l -p /etc/group
查看此文件被那个软件包创建,以及一些相关信息;

提示:必须使用绝对路径,否则不显示信息;

(22), 删除软件包:

# pkgrm SUNWapchr 删除软件包SUNWapchr

(23),
增加一个软件包spool 路径:
默认情况下,spool路径放在/var/spool/pkg ,
增加方法如下:
# pkgadd -d /cdrom/cdrom0/s0/Solaris_9/Product -s spool SUNWensqr.u

如果想删除spool路径:
# pkgrm -s spool SUNWensqr.u

如果想增加一个spool中径到一个自己指定的目录/export/pkg下,则如下操作:

# pkgadd -d /cdrom/cdrom0/s0/Solaris_9/Product -s /export/pkg SUNWensqr.u
# pkgrm -s /export/pkg SUNWensqr.u


------------------------------------------------------------------------------
(24),

安装:
# patchadd 105050-01

# patchrm 105050-01


安装patch cluster:

patch cluster由推荐补丁,安全补丁以及Y2K patch组成;安装时必须在/ /var /usr /opt有至少10M的空间,会把patch存在/var/sadm/pkg目录,也可-nosave,将不能对个别patch进行恢复删除,


# cd patch_cluster_directory
# ./install_cluster


-------------------------------------------------------------------------------------------

(25),To display revsion of OpenBoot PROM :
#/usr/platform/"uname -m"/sbin/prtdiag -v

---------------------------------------------------------------------
(26), NVRAM "s noneditable area :

The Ethernet address, such as 8:0:20:5d:6f:9e
The HostID value ,such as 805d6f83
(27),stopD
stopN
StopA 三个命令的作用

(28),停止在系统运行时stop A的作用:
/etc/default/kbd
删除KEYBOARD ABORT=disable的注册符;

--------------------------------------------------------------------
(29),Boot PROM command: (必考)

banner---- displays the power-on banner(also list Ethernet address,HostID,model name , boot PROM version,the amount of memory.)
boot ---- boots the system(-s boot the system to single-usermode;
-a boot the system interactively;
-v boots the system displaying more detailed info;
-r Performs a reconfigration boot.)
help ---- Lists the main help categorIEs
Words ---- displays the FORTH words in the dictionary
sifting text ----- Displays the FORTH commands contianing text
Printenv ---- Dislplays all paramenter"s current and default values.
setenv ---- set the specified NVRAM parameter to some value.
reset-all ---- Resets the entire system; similar to a power cycle.
set-defaults ---- Resets all paramter values to the factory defualts.
probe-ide
probe-scsi
probe-fcal-all
probe-scsi-all
probe-ide
probe-pci-slot
test ---- Runs self-test on specified devices;
.version ---- Displays the version and the date of the boot PROM;
.enet-addr ---- Displays the Ethernet address;
.idprom ---- Displays the IP PROM contents.
.speed ---- Displays the speed oft processor and of the buses attached to the sytem;
.registers ----- Displays the contents of the registers;

show-devs ---- view the entire device tree;
devalias ---- To identify the current boot device alias for the system;
nvalias ---- Creat a new device alias name;
nvunalias ---- Remove a custom device alias name;


--------------------------------------------------------------------------------
(30),Identifying RUN level (必考)

0 and S and 1 , this three level differ;

推荐阅读