‘インストール’ タグのついている投稿


WebARENA CLOUD9、解約しようとしたら、3ヶ月無料キャンペーンは、1年契約になるので3ヶ月経過後すぐには解約出来なかった。がーん。
仕方が無いので、あんまり落ちてくれるなよと祈りつつ色々実験機として使うことにした。

クラウドストレージの登場で、外部バックアップがしやすくなった

バックアップデータは曜日単位でバックアップを取るなどすると掛け算で容量が増えるのでストレージを結構圧迫する。また、同一ストレージ上にあるよりは、別ストレージに逃がした方が当然良い。
Dropboxなどクラウドストレージは、上記要件の解として有効なもののひとつだと思う。問題点は、ストレージの速度とセキュリティの問題か。プライベートクラウドなど、今後はより安全で安定なサービスも増えると思うが、今回はwordpressの記事データをバックアップするという単純な用途なので、あまり難しく考えずDropboxにmysqlのダンプを退避してみる。

参考サイト

http://wiki.dropbox.com/TipsAndTricks/TextBasedLinuxInstallを参考にした。
日本語で個人の方が書いている方法もあったが、その当時よりも対応が進んでいて、より簡単に出来た。この記事だって数ヶ月もしたら、もっと簡単な方法に置き換わると思われる。

Pythonのインストール

CentOSにデフォルトでインストールされているPythonは、2.4.3。DropboxのCLIは2.5以上を要求しているので、現時点で2.X系で最新の2.7.1をインストールした。
その際、すでにインストールされているPythonとぶつからないようにした。

#wget http://www.python.org/ftp/python/2.7.1/Python-2.7.1.tgz
#tar -zxvf Python-2.7.1.tgz
#cd Python-2.7.1
#./configure --prefix=/usr/local/bin/Python-2.7.1
#make
#make install
#ln -s /usr/local/bin/Python-2.7.1/bin/python /usr/bin/python2.7.1
#python2.7.1 -V
Python 2.7.1

Dropboxのインストール

dropbox.pyからDropbox本体をインストール出来るので、dropbox.pyを先にダウンロードする。

#wget -O dropbox.py "http://www.dropbox.com/download?dl=packages/dropbox.py"
#python2.7.1 ./dropbox.py start -i
Starting Dropbox...
Dropbox is the easiest way to share and store your files online. Want to learn more? Head to http://www.dropbox.com/

In order to use Dropbox, you must download the proprietary daemon. [y/n] y
Downloading Dropbox... 100%
Unpacking Dropbox... 100%
Done!
#python2.7.1 ./dropbox.py start
To link this computer to a dropbox account, visit the following url:
https://www.dropbox.com/cli_link?host_id=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

表示されたURLにブラウザからアクセスし、すでに持っているアカウントでログインすると同期完了。ホームディレクトリ上にDropboxディレクトリが作成され、同期が開始される。これで設定は終わり。Dropboxは動いている。

シェルでmysqldumpを実行して、Dropboxで同期する

Dropboxを常時デーモンとして動かしても良いのだけど、見たところ200MBくらいメモリを使う。CLOUD9の基本プランではメモリは1GBなので、出来るだけメモリは節約したい。バックアップ目的なので、バックアップ処理時だけDropboxを起動して、処理終了時にはDropboxも終了するようにする。
以下のようなシェルスクリプトで定期実行する。

#!/bin/bash
prog="python2.7.1 Dropboxをインストールしたディレクトリ/dropbox.py"

mysqldump --user=root --all-databases --password=パスワード > ホームディレクトリ/Dropbox/mysqldump/dump
tar czvf ホームディレクトリ/Dropbox/mysqldump/dump`date '+%w'`.tgz ホームディレクトリ/Dropbox/mysqldump/dump
rm -rf ホームディレクトリ/Dropbox/mysqldump/dump
$prog start
status=`$prog status`
while [ "$status" != "Idle" ]
do
status=`$prog status`
echo $status
sleep 3 ← Dropboxの状態を次に確認するまでの秒数
done
$prog stop

mysqldumpのパラメータは、使うデータベースを限定したり、状況に合わせて変更する。稼働中、Dropboxのステータスを表示するようにしたので、どのくらいの時間で同期できたかもざっくりわかる仕組み。
データセンターからのアップなので結構なスピードが出るのかと思ったら100KB/sec以下になることも多い。これはこちらの回線というよりもDropbox側の問題だと思われる。

と、ここでCLOUD9は回線速度のことを書いていないことに気づいた。SuitePROは1Gbpsと書いている。なんというか、全体にこんな印象なんだよね、CLOUD9。説明があるようで無いようである。探せばどこかに書いてあるのだろう。


WebARENA SuitePRO V2で運用しているサーバの、日次バッチで稼動しているyum updateからTransaction Check Errorが出ていたので対処した。

Transaction Check Error の中身

結構どっさり出た。

 file /usr/share/man/man1/c2ph.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/cpan.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/dprofpp.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/enc2xs.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/find2perl.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/h2ph.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/h2xs.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/instmodsh.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/libnetcfg.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl5004delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl5005delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl561delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl56delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl570delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl571delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl572delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl573delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl581delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl582delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl583delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl584delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl585delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl586delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl587delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl588delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perl58delta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlaix.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlamiga.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlapi.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlapio.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlapollo.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlartistic.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlbeos.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlbook.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlboot.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlbot.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlbs2000.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlbug.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcall.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlce.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcheat.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlclib.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcn.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcompile.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlcygwin.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldata.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldbmfilter.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldebguts.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldebtut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldebug.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldelta.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldgux.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldiag.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldos.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perldsc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlebcdic.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlembed.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlepoc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq1.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq2.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq3.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq4.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq5.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq6.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq7.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq8.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfaq9.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfilter.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfork.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlform.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfreebsd.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlfunc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlglossary.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlgpl.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlguts.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlhack.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlhist.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlhpux.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlhurd.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlintern.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlintro.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perliol.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlipc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlirix.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlivp.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perljp.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlko.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perllexwarn.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perllinux.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perllocale.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perllol.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmachten.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmacos.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmacosx.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmint.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmod.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmodinstall.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmodlib.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmodstyle.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlmpeix.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlnetware.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlnewmod.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlnumber.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlobj.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlop.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlopenbsd.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlopentut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlos2.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlos390.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlos400.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlothrtut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlpacktut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlplan9.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlpod.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlpodspec.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlport.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlqnx.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlre.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlref.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlreftut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlrequick.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlreref.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlretut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlrun.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlsec.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlsolaris.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlstyle.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlsub.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlsyn.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlthrtut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltie.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltoc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltodo.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltooc.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltoot.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltrap.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltru64.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perltw.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlunicode.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perluniintro.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlutil.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perluts.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlvar.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlvmesa.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlvms.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlvos.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlwin32.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlxs.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/perlxstut.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/piconv.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pl2pm.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pod2html.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pod2latex.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pod2man.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pod2text.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pod2usage.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/podchecker.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/podselect.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/prove.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/psed.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/pstruct.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/s2p.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/splain.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386
 file /usr/share/man/man1/xsubpp.1.gz from install of perl-5.8.8-32.el5_5.2.x86_64 conflicts with file from package perl-5.8.8-32.el5_5.1.i386

OSとperlのバージョン

どちらもデフォルトで提供されているものをそのまま使用。

# cat /etc/redhat-release
CentOS release 5.5 (Final)

# perl -v

This is perl, v5.8.8 built for x86_64-linux-thread-multi

Copyright 1987-2006, Larry Wall

Perl may be copied only under the terms of either the Artistic License or the
GNU General Public License, which may be found in the Perl 5 source kit.

Complete documentation for Perl, including FAQ lists, should be found on
this system using "man perl" or "perldoc perl".  If you have access to the
Internet, point your browser at http://www.perl.org/, the Perl Home Page.

対処

[SOLVED] Troubles when yum update, “error summary”
http://www.centos.org/modules/newbb/viewtopic.php?topic_id=28412&forum=37

22. I installed the x86_64 version, so why do I have i386 packages, and can I get rid of them?
http://wiki.centos.org/FAQ/General#head-357346ff0bf7c14b0849c3bcce39677aaca528e9

の辺を参考にした。
perlの32bit版は使っていないのでアンインストールした後、手動でyum updateを実行して問題なく更新されることを確認した。

#rpm -e perl.i386
#yum update

Oracle11gをデータベースとして使用するシステムで、sqlrelayをコネクションプーリングのミドルウェアとして使用したので、メモを残してみる。

インストールするOS

データベースがOracleなので、それにあわせてOracle Enterprise Linuxを使用した。

Instant Clientのインストール

Oracleのサイトから、
Instant Client for Linux x86の

をダウンロードし、rpmでインストール。

.bash_profile tnsnames.oraの設定

Oracleと接続する基本設定を実施し、SQL*Plusで接続できることを確認。

sqlrelayのインストール

http://sqlrelay.sourceforge.net/から、バージョン0.39.4 をダウンロード。
(0.40以降では、インストール後、うまくデーモンが立ち上がってくれなかった。)
ソース解凍後、configureの以下の2箇所を編集する。

if ( test -z "$ORACLELIBS" )
then
 for version in `cd /usr/lib/oracle 2> /dev/null; ls -d * 2> /dev/null`
 do
  if ( test -r "/usr/lib/oracle/$version/client/lib/libclntsh.$SOSUFFIX" -a -r "/usr/include/oracle/$version/client/oci.h" )
  then
   ORACLEVERSION="10g" → 11g に変更
   ORACLELIBSPATH="/usr/lib/oracle/$version/client/lib"
   ORACLELIBS="-L/usr/lib/oracle/$version/client/lib -lclntsh -lnnz10" → lnnz11 に変更
   ORACLEINCLUDES="-I/usr/include/oracle/$version/client"
  fi
 done
fi

configureを実行。上記の変更がなされていないと、Oracleを発見できずにconfigureは失敗する。

./configure \
  --disable-mysql \
  --disable-msql \
  --disable-postgresql \
  --disable-sqlite \
  --disable-freetds \
  --disable-sybase \
  --disable-odbc \
  --disable-db2 \
  --disable-interbase \
  --disable-mdbtools \
  --disable-python \
  --disable-zope \
  --disable-ruby \
  --disable-java \
  --disable-php \
  --disable-tcl \
  --disable-gtk \
  --with-oracle-instantclient-prefix=/usr/include/oracle/11.2/client/

configureが成功すれば、その後はmake、make installでインストールを完了。

sqlrelay.confの設定

/usr/local/firstworks/etc/sqlrelay.conf.example に設定ファイルのサンプルがあるので、それを /usr/local/firstworks/etc/sqlrelay.conf にコピーし設定する。
設定内容は、http://sqlrelay.sourceforge.net/sqlrelay/configuring.htmlを参照。

環境変数の設定

PATH に /usr/local/firstworks/bin
LD_LIBRARY_PATH に /usr/local/firstworks/lib
を追加。

デフォルト起動インスタンスIDの設定

sqlrelay.confに設定した内容でデフォルト起動となるインスタンスIDを /etc/sysconfig/sqlrelay に記述。

ここまでで各種設定は完了。
> service sqlrelay start
で、デーモンが開始される。

perlからsqlrelay経由でのOracleへの接続

DBIを使用した以下のようなコードで接続できる。

#!/usr/bin/perl
use DBI;
my $dbh = DBI->connect('DBI:SQLRelay:host=localhost;port=sqlrelay.confで設定したポート;socket=',"接続ID","接続パスワード");
my $sth = $dbh->prepare("select * from emp");
$sth->execute;
while ( my @row = $sth->fetchrow_array ) {
	print "$row[0]\n";
}
$sth->finish;
exit;

接続先がsqlrelayに変わるだけで、その他に関してはDBI経由でOracleとやり取りする部分に違いは無い。