AWStatsインストール

徐々に以前の環境に戻してはいますが、すんなりとはいきませんねぇ。AWStatsインストールに関して不具合があったので、備忘録として以下簡易メモ。

# wget http://prdownloads.sourceforge.net/awstats/awstats-7.3-1.noarch.rpm
# rpm -ivh awstats-7.3-1.noarch.rpm
エラー: 依存性の欠如:
perl(Digest::MD5) は awstats-7.3-1.noarch に必要とされています
perl(LWP::UserAgent) は awstats-7.3-1.noarch に必要とされています

※↓これでOK
# yum -y install perl-Digest-MD5
# yum -y install perl-libwww-perl

AWStatsの設定を済ませ、perl-CPANを起動するところで再びエラー発生。

“Would you like me to automatically choose some CPAN mirror sites for you? (This means connecting to the Internet) [yes]”

のところで「yes」のまま先に進むと、Perlモジュールがエラーを起こして終了してしまうので「no」にして手動で設定。

# perl -MCPAN -e shell
Sorry, we have to rerun the configuration dialog for CPAN.pm due to
some missing parameters. Configuration will be written to
<</root/.cpan/CPAN/MyConfig.pm>>

CPAN.pm requires configuration, but most of it can be done automatically.
If you answer ‘no’ below, you will enter an interactive dialog for each
configuration option instead.

Would you like to configure as much as possible automatically? [yes]

<install_help>

Warning: You do not have write permission for Perl library directories.

To install modules, you need to configure a local Perl library directory or
escalate your privileges. CPAN can help you by bootstrapping the local::lib
module or by configuring itself to use ‘sudo’ (if available). You may also
resolve this problem manually if you need to customize your setup.

What approach do you want? (Choose ‘local::lib’, ‘sudo’ or ‘manual’)
[local::lib] manual

Autoconfigured everything but ‘urllist’.

Now you need to choose your CPAN mirror sites. You can let me
pick mirrors for you, you can select them from a list or you
can enter them by hand.

Would you like me to automatically choose some CPAN mirror
sites for you? (This means connecting to the Internet) [yes] no

Would you like to pick from the CPAN mirror list? [yes]
Found a cached mirror list as of Tue Nov 11 00:55:06 2014

If you’d like to just use the cached copy, answer ‘yes’, below.
If you’d like an updated copy of the mirror list, answer ‘no’ and
I’ll get a fresh one from the Internet.

Shall I use the cached mirror list? [yes]
First, pick a nearby continent and country by typing in the number(s)
in front of the item(s) you want to select. You can pick several of
each, separated by spaces. Then, you will be presented with a list of
URLs of CPAN mirrors in the countries you selected, along with
previously selected URLs. Select some of those URLs, or just keep the
old list. Finally, you will be prompted for any extra URLs — file:,
ftp:, or http: — that host a CPAN mirror.

You should select more than one (just in case the first isn’t available).

(1) Africa
(2) Asia
(3) Europe
(4) North America
(5) Oceania
(6) South America
Select your continent (or several nearby continents) [] 2
(1) China
(2) India
(3) Indonesia
(4) Iran
(5) Israel
(6) Japan
(7) Kazakhstan
(8) Pakistan
(9) Republic of Korea
(10) Russia
(11) Singapore
(12) Taiwan
(13) Thailand
(14) Turkey
(15) Viet Nam
Select your country (or several nearby countries) [] 6
(1) ftp://ftp.jaist.ac.jp/pub/CPAN/
(2) ftp://ftp.kddilabs.jp/CPAN/
(3) ftp://ftp.nara.wide.ad.jp/pub/CPAN/
(4) ftp://ftp.riken.jp/lang/CPAN/
(5) ftp://ftp.u-aizu.ac.jp/pub/CPAN/
(6) ftp://ftp.yz.yamagata-u.ac.jp/pub/lang/cpan/
(7) ftp://mirror.jre655.com/CPAN/
(8) ftp://mirrors.go-parts.com/cpan/
(9) http://ftp.jaist.ac.jp/pub/CPAN/
(10) http://ftp.nara.wide.ad.jp/pub/CPAN/
(11) http://ftp.riken.jp/lang/CPAN/
(12) http://ftp.yz.yamagata-u.ac.jp/pub/lang/cpan/
(13) http://mirror.jre655.com/CPAN/
(14) http://mirrors.go-parts.com/cpan/
Select as many URLs as you like (by number),
put them on one line, separated by blanks, hyphenated ranges allowed
e.g. ‘1 4 5’ or ‘7 1-4 8’ [] 4
Now you can enter your own CPAN URLs by hand. A local CPAN mirror can be
listed using a ‘file:’ URL like ‘file:///path/to/cpan/’

Enter another URL or ENTER to quit: []
New urllist
ftp://ftp.riken.jp/lang/CPAN/

Autoconfiguration complete.

commit: wrote ‘/root/.cpan/CPAN/MyConfig.pm’

You can re-run configuration any time with ‘o conf init’ in the CPAN shell
Terminal does not support AddHistory.

cpan shell — CPAN exploration and modules installation (v1.9800)
Enter ‘h’ for help.

cpan[1]> install Geo::IPfree
(中略)
cpan[2]> quit

Geo::IPfreeモジュールがインストールできればいいので、もしアクセス元の名前解決を行わなければ上記の手順は不要かも? その代わり、アクセス元がIPアドレスで記録されることになるのでしょうが…。

%d人のブロガーが「いいね」をつけました。