7.17 Linux腳本程序包及安裝方法詳解(以webmin為例)
腳本程序并不多見,所以在軟件包分類中并沒有把它列為一類。它更加類似于 Windows 下的程序安裝,有一個可執行的安裝程序,只要運行安裝程序,然后進行簡單的功能定制選擇(比如指定安裝目錄等),就可以安裝成功,只不過是在字符界面完成的。
目前常見的腳本程序以各類硬件的驅動居多,我們需要學習一下這類軟件的安裝方式,以備將來不時之需。
我們來看看腳本程序如何安裝和使用。安裝一個叫作 Webmin 的工具軟件,Webmin 是一個基于 Web 的系統管理界面,借助任何支持表格和表單的瀏覽器(和 File Manager 模塊所需要的Java),你就可以設置用戶賬號、apache、DNS、文件共享等。
Webmin 包括一個簡單的 Web 服務器和許多 CGI 程序,這些程序可以直接修改系統文件,比如 /etc/inetd.conf 和 /etc/passwd。Web 服務器和所有的 CGI 程序都是用 Perl 5 編寫的,沒有使用任何非標準 Perl 模塊。也就是說,Webmin 是一個用 Perl 語言寫的、可以通過瀏覽器管理 linux 的軟件。
webmin安裝步驟
首先下載 Webmin 軟件,這里下載的是 webmin-1.610.tar.gz。
接下來解壓縮軟件,命令如下:
[root@localhost ~]# tar -zxvf webmin-1.610.tar.gz
進入解壓目錄,命令如下:
[root@localhost ~]# cd webmin-1.610
執行安裝程序 setup.sh,并指定功能選項,命令如下:
[root@localhost webmin-1.610]# ./setup.sh ************************** \* Welcome to the Webmin setup script,version 1.610 * ************************** Webmin is a web-based interface that allows Unix-like operating systems and common Unix services to be easily administered. Installing Webmin in /root/webmin-1.610... ************************** 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]: \#選擇安裝位置,默認安裝在/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 peri (default /usr/bin/perl): \#指定Perl語言的安裝位置,直接回車,選擇默認位置,Perl默認就安裝這里 Testing Perl... Perl seems to be installed ok ************************** Operating system name: CentOS linux Operating system version: 6.3 ************************** 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): \#指定Webmin監聽的端口,直接回車,默認選定 10000 Login name (default admin):admin #輸入登錄Webmin的用戶名 Login password: Password again: \#輸入登陸密碼 The Perl SSLeay library is not installed.SSL not available. \#apache默認沒有啟動SSl功能,所以SSl沒有被激活 Start Webmin at boot time (y/n):y \#是否在開機的同時啟動Webmin …安裝過程省略… Webmin has been installed and started successfully.Use your web browser to go to http://localhost:10000/ and login with the name and password you entered previously. \#安裝完成
在瀏覽器地址欄中輸入"http://192.168.2.199:10000/ ",然后輸入用戶名和密碼,就可以登錄到 Webmin 界面,如圖 1 所示。
圖 1 Webmin登錄界面
當然,我們并不是要講解 Webmin 管理界面如何使用,而是要講解腳本程如何安裝,所以工作已經完成。這種腳本安裝簡單快速,不過需要軟件開商發布安裝腳本。但是 Linux 中的絕大多數軟件是沒有這種腳本的。
Linux Perl
版權聲明:本文內容由網絡用戶投稿,版權歸原作者所有,本站不擁有其著作權,亦不承擔相應法律責任。如果您發現本站中有涉嫌抄襲或描述失實的內容,請聯系我們jiasou666@gmail.com 處理,核實后本網站將在24小時內刪除侵權內容。
版權聲明:本文內容由網絡用戶投稿,版權歸原作者所有,本站不擁有其著作權,亦不承擔相應法律責任。如果您發現本站中有涉嫌抄襲或描述失實的內容,請聯系我們jiasou666@gmail.com 處理,核實后本網站將在24小時內刪除侵權內容。