Solaris下之Top安装

a)首先在windows下下载top,下载地址: ftp://ftp.sunfreeware.com/pub/freeware/sparc/9/top-3.6-sol9-sparc-local.gz

b) 用cuteftp上传到我的服务器上,注意如果上传不成功,并提示目录不可写,这通常是因为当前目录权限设置的原因,而不是因为FTP权限设置原因。

#mkdir /export/home/upload

#ls –l /export/home

drwxrwxrwx   2 root     other        512 Apr 27 10:27 upload

上传后,就可以在上述目录中看到文件top-3.6-sol9-sparc-local.gz.

c) 解压缩,注意用gunzip,而不是tar.

#gunzip top-3.6-sol9-sparc-local.gz

#ls –l

top-3.6-sol9-sparc-local

# pkgtrans top-3.6-sol9-sparc-local .        

The following packages are available:
  1  SMCtop     top
                (sparc) 3.6

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]:
Transferring package instance

上述命令转换安装包的格式,注意最后.是不可以少的,表示当前目录

#ls –l

# pkgadd -d ./   

The following packages are available:
  1  SMCtop     top
                (sparc) 3.6

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]:

Processing package instance from
top
(sparc) 3.6
LeFebvre et al

The selected base directory > must exist before
installation is attempted.
Do you want this directory created now [y,n,?,q] y

Using as the package base directory.
## Processing package information.
## Processing system information.
## Verifying disk space requirements.
## Checking for conflicts with packages already installed.
## Checking for setuid/setgid programs.

Installing top as
## Installing part 1 of 1.
/usr/local/bin/sparcv7/top
/usr/local/bin/sparcv9/top
/usr/local/bin/top
/usr/local/doc/top/Changes
/usr/local/doc/top/FAQ
/usr/local/doc/top/INSTALL
/usr/local/doc/top/LICENSE
/usr/local/doc/top/README
/usr/local/doc/top/Y2K
/usr/local/man/man1/top.1
[ verifying class ]

Installation of was successful.

The following packages are available:
  1  SMCtop     top
                (sparc) 3.6

Select package(s) you wish to process (or 'all' to process
all packages). (default: all) [?,??,q]: q

#/usr/local/bin/top

安装成功,最后设置一下路径,这样直接输入top就可以了:

#env

#vi /export/home/user1/.profile

PATH=/usr/sbin:/usr/bin:/sbin:/usr/local/bin:/usr/ccs/bin:/usr/local/sbin
export PATH

#echo $PATH

#top

……

设置成功.

【但是对于root用户,不知道如何设置path】搜索得知,Solaris下的root的$HOME为:/目录。

#vi /.profile

……


本文来自CSDN博客,转载请标明出处:http://blog.csdn.net/bennyfun79/archive/2009/04/27/4128123.aspx

你可能感兴趣的:(Solaris)