Chinaunix首页 | 论坛 | 博客
  • 博客访问: 4030835
  • 博文数量: 272
  • 博客积分: 7846
  • 博客等级: 少将
  • 技术积分: 6476
  • 用 户 组: 普通用户
  • 注册时间: 2009-08-25 16:27
文章分类

全部博文(272)

分类: LINUX

2010-08-24 16:03:19

一、确定CentOS已经安装,并且所需服务也已成功装好
    我在192.168.1.250的一台服务器上安装了CentOS5.4版本,安装了Apache+MySQL+Samba+FTP+DNS+DHCP+SQUID等。从inittab中修改启动级别为3。重启后离开机房,使用办公室里192.168.1.188的电脑远程SSH到服务器。

二、下载WebMin的最新版本,并安装
    进入,点击左侧download区域中的RPM,复制链接的下载地址,回到pietty终端中:

[lk@hd ~]$ --2010-08-24 15:30:03--  %3A%2F%2F%2F
正在解析主机 downloads.sourceforge.net... 216.34.181.59
Connecting to downloads.sourceforge.net|216.34.181.59|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 302 Found
位置: [跟随至新的 URL]
--2010-08-24 15:30:05-- 
正在解析主机 cdnetworks-kr-2.dl.sourceforge.net... 211.39.135.163
Connecting to cdnetworks-kr-2.dl.sourceforge.net|211.39.135.163|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:15995394 (15M) [application/x-rpm]
Saving to: `webmin-1.510-1.noarch.rpm'

100%[======================================>] 15,995,394  58.6K/s   in 6m 29s

2010-08-24 15:36:37 (40.2 KB/s) - `webmin-1.510-1.noarch.rpm' saved [15995394/15995394]


[1]-  Done                    wget %3A%2F%2F%2F
[2]+  Done                    ts=1282634860
[lk@hd ~]$ ls
webmin-1.510-1.noarch.rpm
[lk@hd ~]$ rpm -ivh webmin-1.510-1.noarch.rpm
warning: webmin-1.510-1.noarch.rpm: Header V3 DSA signature: NOKEY, key ID 11f63c51
error: can't create transaction lock on /var/lib/rpm/__db.000

出现错误,换用tar.gz包,再做一次:

[lk@hd ~]$ wget %3A%2F%2F%2F&ts=1282635512&mirror=cdnetworks-kr-1
[1] 18084
[2] 18085
[lk@hd ~]$ --2010-08-24 15:40:35--  %3A%2F%2F%2F
正在解析主机 downloads.sourceforge.net... 216.34.181.59
Connecting to downloads.sourceforge.net|216.34.181.59|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 302 Found
位置: [跟随至新的 URL]
--2010-08-24 15:40:37-- 
正在解析主机 cdnetworks-kr-2.dl.sourceforge.net... 211.39.135.163
Connecting to cdnetworks-kr-2.dl.sourceforge.net|211.39.135.163|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:14841163 (14M) [application/x-gzip]
Saving to: `webmin-1.510.tar.gz'

100%[======================================>] 14,841,163  45.6K/s   in 6m 49s

2010-08-24 15:47:26 (35.4 KB/s) - `webmin-1.510.tar.gz' saved [14841163/14841163]


[1]-  Done                    wget %3A%2F%2F%2F
[2]+  Done                    ts=1282635512

解压缩,并进入文件夹,开始安装:
[lk@hd ~]$ tar zxvf webmin-1.510.tar.gz
[lk@hd ~]$ ls
webmin-1.510  webmin-1.510-1.noarch.rpm  webmin-1.510.tar.gz
[lk@hd ~]$ cd webmin-1.510
[lk@hd webmin-1.510]$ ./setup.sh
***********************************************************************
*            Welcome to the Webmin setup script, version 1.510        *
***********************************************************************
Webmin is a web-based interface that allows Unix-like operating
systems and common Unix services to be easily administered.

ERROR: The Webmin install script must be run as root

[lk@hd webmin-1.510]$
需要使用root身份。
[lk@hd webmin-1.510]$ su
口令:
[root@hd webmin-1.510]# ./setup.sh
***********************************************************************
*            Welcome to the Webmin setup script, version 1.510        *
***********************************************************************
Webmin is a web-based interface that allows Unix-like operating
systems and common Unix services to be easily administered.

Installing Webmin in /home/lk/webmin-1.510 ...

***********************************************************************
Webmin uses separate directories for configuration files and log files.
Unless you want to run multiple versions of Webmin at the same time
you can just accept the defaults.

Config file directory [/etc/webmin]:
Log file directory [/var/webmin]:

***********************************************************************
Webmin is written entirely in Perl. Please enter the full path to the
Perl 5 interpreter on your system.

Full path to perl (default /usr/bin/perl):

Testing Perl ...
Perl seems to be installed ok

***********************************************************************
Operating system name:    CentOS Linux
Operating system version: 5.4

***********************************************************************
Webmin uses its own password protected web server to provide access
to the administration programs. The setup script needs to know :
 - What port to run the web server on. There must not be another
   web server already using this port.
 - The login name required to access the web server.
 - The password required to access the web server.
 - If the webserver should use SSL (if your system supports it).
 - Whether to start webmin at boot time.

Web server port (default 10000):
Login name (default admin):
Login password:
Password again:
Use SSL (y/n): y
Start Webmin at boot time (y/n): y
***********************************************************************
Creating web server config files..
..done

Creating access control file..
..done

Inserting path to perl into scripts..
..done

Creating start and stop scripts..
..done

Copying config files..
..done

Configuring Webmin to start at boot time..
Created init script /etc/rc.d/init.d/webmin
..done

Creating uninstall script /etc/webmin/uninstall.sh ..
..done

Changing ownership and permissions ..
..done

Running postinstall scripts ..
..done

Attempting to start Webmin mini web server..
Starting Webmin server in /home/lk/webmin-1.510
Pre-loaded WebminCore
..done

***********************************************************************
Webmin has been installed and started successfully. Use your web
browser to go to

 

and login with the name and password you entered previously.

Because Webmin uses SSL for encryption only, the certificate
it uses is not signed by one of the recognized CAs such as
Verisign. When you first connect to the Webmin server, your
browser will ask you if you want to accept the certificate
presented, as it does not recognize the CA. Say yes.

[root@hd webmin-1.510]#

ok,安装成功。
现在再思考刚才RPM没能安装成功的原因,很可能是非root身份导致的。
今天重新安装系统,又重新试了一遍rpm包,安装成功,注意身份必须是root:
[root@lk lk]# wget
--2010-08-27 09:37:56-- 
正在解析主机 prdownloads.sourceforge.net... 216.34.181.59
Connecting to prdownloads.sourceforge.net|216.34.181.59|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 301 Moved Permanently
位置: [跟随至新的 URL]
--2010-08-27 09:37:57-- 
正在解析主机 downloads.sourceforge.net... 216.34.181.59
Reusing existing connection to prdownloads.sourceforge.net:80.
已发出 HTTP 请求,正在等待回应... 302 Found
位置: [跟随至新的 URL]
--2010-08-27 09:37:58-- 
正在解析主机 cdnetworks-kr-2.dl.sourceforge.net... 211.39.135.163
Connecting to cdnetworks-kr-2.dl.sourceforge.net|211.39.135.163|:80... 已连接。
已发出 HTTP 请求,正在等待回应... 200 OK
长度:15995394 (15M) [application/x-rpm]
Saving to: `webmin-1.510-1.noarch.rpm'

100%[======================================>] 15,995,394   593K/s   in 44s

2010-08-27 09:38:42 (354 KB/s) - `webmin-1.510-1.noarch.rpm' saved [15995394/15995394]

[root@lk lk]# rpm -ivh webmin-1.510-1.noarch.rpm
warning: webmin-1.510-1.noarch.rpm: Header V3 DSA signature: NOKEY, key ID 11f63c51
Preparing...                ########################################### [100%]
Operating system is CentOS Linux
   1:webmin                 ########################################### [100%]
^[[B
Webmin install complete. You can now login to
as root with your root password.

阅读(2554) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~