2010/04/20

PowerBook G4 on Leopard

PowerBook G4 に MacOS X Leopard をインストールした事例.


PowerBook G4 12" 867MHzにLeopardをインストールする(直前)
http://d.hatena.ne.jp/riocampos/20080229/1204256679


PowerBook G4 12” 867MHzにLeopardを入れてみた
http://d.hatena.ne.jp/riocampos/20080314/1205510441

2010/04/19

Virtual PC 7 時刻同期機能の無効設定

Virtual PC 7 でCentOSを動かしていると時間がえらく進む.

Virtual PC の旧バージョンでは時刻同期機能を無効に設定できるらしい.

仮想マシンの時刻同期機能を無効にする(Virtual PC編)
http://www.atmarkit.co.jp/fwin2k/win2ktips/639vpcsync/vpcsync.html

Windows7でインストールできる Virtual PC 7 では,時刻同期機能の
設定が最初から設定ファイル *.vmc に書かれている.

変更前



変更後



host_time_sync の boolean を true から false に変更すれば
無効になるのかもしれない.設定して様子見.

2010/04/18

SSH keepalive

OpenSSHクライアント keepaliveオプション

sshで自動切断されないように keepaliveパケットを送る
http://netmark.jp/2008/11/sshkeepalive.html

ssh -o ServerAliveInterval=XX

XX:秒

sshfsとの併用は必須.

Quick Time

http://www.apple.com/jp/quicktime/player/

http://www.apple.com/jp/quicktime/player/specs.html

Quick Time Player の仕様ページに書かれていたけど,
Mac OS だと PDFも読み込めるらしい.

短縮URLサービス

http://p.tl/

http://bit.ly/

2010/04/14

sshfs インストール

http://sourceforge.net/projects/fuse/files/


ダウンロード
% wget "http://downloads.sourceforge.net/project/fuse/fuse-2.X/2.7.6/fuse-2.7.6.tar.gz?use_mirror=jaist"


% tar zxvf fuse-2.7.6.tar.gz
% cd fuse-2.7.6
% ./configure
..
configure:
NOTE: Detected that FUSE is already present in the kernel, so
NOTE: building of kernel module is disabled. To force building
NOTE: of kernel module use the '--enable-kernel-module' option.
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h

% make
# make install

# ln -s /usr/local/lib/libfuse.so.2 /lib/

これをやっておかないとsshfs実行時に以下のエラーが出る.

sshfs: error while loading shared libraries: libfuse.so.2: cannot open shared object file: No such file or directory


sshfs-fuse

% wget "http://downloads.sourceforge.net/project/fuse/sshfs-fuse/2.2/sshfs-fuse-2.2.tar.gz?use_mirror=jaist"


% tar zxvf sshfs-fuse-2.2.tar.gz
% cd sshfs-fuse-2.2
% ./configure
% make
% make install


modprobe fuse

で sshfsが使えるようになる.



# sshfs name@hoge.hoge:/test /test

参考)sshfs インストールログ
http://12158.diarynote.jp/200908042121271913/

Lingua-JA-Summarize-Extract-0.02

# cd Lingua-JA-Summarize-Extract-0.02

# perl Makefile.PL
Cannot determine perl version info from lib/Lingua/JA/Summarize/Extract.pm
*** Module::AutoInstall version 1.03
*** Checking for Perl dependencies...
[Core Features]
- Test::More ...loaded. (0.64)
- Class::Accessor::Fast ...loaded. (0.34)
- UNIVERSAL::require ...missing.
==> Auto-install the 1 mandatory module(s) from CPAN? [y] y
CPAN: File::HomeDir loaded ok (v0.89)
*** Dependencies will be installed the next time you type 'make'.
*** Module::AutoInstall configuration finished.
Warning: prerequisite UNIVERSAL::require 0 not found.
Writing Makefile for Lingua::JA::Summarize::Extract

# make

# make test
/usr/bin/perl "-Iinc" Makefile.PL --config= --installdeps=UNIVERSAL::require,0
Cannot determine perl version info from lib/Lingua/JA/Summarize/Extract.pm
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'inc', 'blib/lib', 'blib/arch')" t/00_compile.t
t/00_compile.t .. ok
All tests successful.
Files=1, Tests=7, 0 wallclock secs ( 0.02 usr 0.00 sys + 0.02 cusr 0.01 csys = 0.05 CPU)
Result: PASS


# make install
/usr/bin/perl "-Iinc" Makefile.PL --config= --installdeps=UNIVERSAL::require,0
Cannot determine perl version info from lib/Lingua/JA/Summarize/Extract.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/ResultSet.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Parser/Trim.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Parser/Ngram.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Parser/NgramSimple.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Sentence/Base.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Sentence/Tiny.pm
Installing /usr/lib/perl5/site_perl/5.8.5/Lingua/JA/Summarize/Extract/Plugin/Scoring/Base.pm
Installing /usr/share/man/man3/Lingua::JA::Summarize::Extract::Plugin::Sentence::Base.3pm
Installing /usr/share/man/man3/Lingua::JA::Summarize::Extract::Plugin::Parser::Ngram.3pm
Installing /usr/share/man/man3/Lingua::JA::Summarize::Extract::Plugin::Parser::Trim.3pm
Installing /usr/share/man/man3/Lingua::JA::Summarize::Extract.3pm
Installing /usr/share/man/man3/Lingua::JA::Summarize::Extract::Plugin::Parser::NgramSimple.3pm
Appending installation info to /usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/perllocal.pod

IBM DB2 参考WEB

kの研究室

http://mklabo.jp/blog/mt/mt-search.cgi?blog_id=2&tag=DB2&limit=20

IBM DB2 入門

DB2入門講座
http://www.ibm.com/developerworks/jp/data/library/dataserver/db2new/


pureXML の歩き方
http://www.ibm.com/developerworks/jp/data/library/dataserver/purexml/

IBM DeveloperWorks Japan Information Management

IBM DeveloperWorks Japan
Information Management

http://www.ibm.com/developerworks/jp/data/

GoogleDevelopersJA (YouTube)

Google DevFest 2010 Japan

http://www.youtube.com/user/GoogleDevelopersJA

2010/04/13

Samba ドメイン参加エラー

Windows7クライアントでドメインに参加する場合のエラー回避方法.





regedit でレジストリ編集.

HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\services\Tcpip\Parameters

NV Domain に任意のドメイン名を設定すればいいらしい.

参考)Windows 7 で Samba ドメインに参加
http://www.natzworks.com/digital/entries/2010/000256.html

Windows7用 PDC for Samba

調べたサイトをとりあえずメモ.

http://ja.528p.com/linux/centos/SP001-samba.html
http://blog.livedoor.jp/brb35350/
http://blog.livedoor.jp/brb35350/archives/51297361.html
http://damedame.monyo.com/?date=20091011
http://shigekun.blog.so-net.ne.jp/2008-04-05
http://o-mita.cocolog-nifty.com/blog/2007/11/samba_6601.html

sshfs アンマウント

sshfs でマウントしたディレクトリをアンマウントする方法.

root では umount でアンマウント可能だが,一般ユーザでは
umount自体が実行できないため,fusermount を使う.

fusermount -u /home/hoge



参考)sshで他マシンのファイルシステムをマウントするには
http://www.atmarkit.co.jp/flinux/rensai/linuxtips/948sshfs.html

sshfs の実行権限

root 以外で sshfs を実行するための設定.

/etc/group の fuse グループにユーザを追加する.

参考)sshで他マシンのファイルシステムをマウントするには
http://www.atmarkit.co.jp/flinux/rensai/linuxtips/948sshfs.html

Mecab

MeCab: Yet Another Part-of-Speech and Morphological Analyzer
http://mecab.sourceforge.net/


MeCabメーリングリスト
http://sourceforge.jp/projects/mecab/


簡単な使い方.
MeCabコマンド単独での実行.
http://mecab.sourceforge.net/#parse




% cd mecab-perl-0.98

% perl Makefile.PL
Checking if your kit is complete...
Looks good
Writing Makefile for MeCab

% make
cp MeCab.pm blib/lib/MeCab.pm
g++ -c -I/usr/local/include -D_REENTRANT -D_GNU_SOURCE -DDEBUGGING -fno-strict-aliasing -pipe -I/usr/local/include -D_LARGEFILE_SOURCE -D_FILE_OFFSET_BITS=64 -I/usr/include/gdbm -O2 -g -pipe -m64 -DVERSION=¥"0.98¥" -DXS_VERSION=¥"0.98¥" -fPIC "-I/usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/CORE" MeCab_wrap.cxx
Running Mkbootstrap for MeCab ()
chmod 644 MeCab.bs
rm -f blib/arch/auto/MeCab/MeCab.so
g++ -shared MeCab_wrap.o -o blib/arch/auto/MeCab/MeCab.so -L/usr/local/lib -lmecab -lstdc++
chmod 755 blib/arch/auto/MeCab/MeCab.so
cp MeCab.bs blib/arch/auto/MeCab/MeCab.bs
chmod 644 blib/arch/auto/MeCab/MeCab.bs


% make test
# make install
Installing /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/MeCab/MeCab.so
Installing /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/MeCab/MeCab.bs
Files found in blib/arch: installing files in blib/lib into architecture dependent library tree
Writing /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/MeCab/.packlist
Appending installation info to /usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/perllocal.pod






参考)MeCab 0.98 のインストール方法
http://www.asahi-net.or.jp/~YW3T-TRNS/namazu/mecab/index.htm


参考)サンプルプログラムなど.
[Perl] MeCab.pm 入ったー!
http://d.hatena.ne.jp/likk/20070428/1177781039

Lingua-JA-Summarize-0.08

Perlモジュール Lingua-JA-Summarize-0.08 のインストール.


必要なPerlモジュールをCPANでインストール.

% perl -MCPAN -e shell

cpan> install Class::Accessor::Fast
cpan> install Class::ErrorHandler
cpan> install Lingua::JA::Summarize


% tar zxvf Lingua-JA-Summarize-0.08
% cd Lingua-JA-Summarize-0.08
% perl Makefile.PL
Checking if your kit is complete...
Looks good
Writing Makefile for Lingua::JA::Summarize


% make
cp lib/Lingua/JA/Summarize.pm blib/lib/Lingua/JA/Summarize.pm
cp lib/Lingua/JA/Summarize/Mecab.pm blib/lib/Lingua/JA/Summarize/Mecab.pm
Manifying blib/man3/Lingua::JA::Summarize.3pm
Manifying blib/man3/Lingua::JA::Summarize::Mecab.3pm


% make test
PERL_DL_NONLAZY=1 /usr/bin/perl "-MExtUtils::Command::MM" "-e" "test_harness(0, 'blib/lib', 'blib/arch')" t/*.t
t/00-util.......ok
t/01-new........ok
t/02-keyword....ok
All tests successful.
Files=3, Tests=41, 3 wallclock secs ( 3.50 cusr + 0.08 csys = 3.58 CPU)


# make install
Writing /usr/lib64/perl5/site_perl/5.8.5/x86_64-linux-thread-multi/auto/Lingua/JA/Summarize/.packlist
Appending installation info to /usr/lib64/perl5/5.8.5/x86_64-linux-thread-multi/perllocal.pod


参考)CPANモジュールのmake testエラー.
http://q.hatena.ne.jp/mobile/1164216751