pogoplugをlinuxからmountする方法

'Linuxサーバ化'の話題が豊富すぎて埋もれ気味なのでひっそりと書いておく。
・・・がしかしうまくいかないときもある

必要なもの

  • fuse
  • pogoplugのアカウント
  • クライアントアプリケーション


やったこと

#cd /tmp
#yum install libfuse.so.2
#wget http://download.pogoplug.com/install/linux/pogopluginstall.tar.gz
#tar xvf pogopluginstall.tar.gz
#./pogoplugfs --user hoge@hoge.info --passowrd "hogehogeplug" --mountpoint /mnt/pdrive


エラった

[111112.059][416010][CEFSAP][08] **********************************************
[111112.060][416010][CEFSAP][08] **********************************************
[111112.060][416010][CEFSAP][08] **********************************************
[111112.060][416010][CEFSAP][08] Application Started [VERSION 'LINUX GENERIC - 1.0.0.6' 'GENERIC - 0.80']
[111112.060][416010][CEFSAP][08] Property mode:
[111112.060][416010][CEFSAP][08]   SVCURL:      http://service.pogoplug.com/svc/api
[111112.060][416010][CEFSAP][08]   SVCFILEURL:  http://service.pogoplug.com/svc/files
[111112.060][416010][BRHTTP][02] RECONNECTING 0x947c500
[111112.673][416010][BRHTTP][08] Verifying SSL certificate of peer...
[111112.673][416010][BRHTTP][08] Error with certificate at depth: 3
[111112.673][416010][BRHTTP][08]     subject: /L=ValiCert Validation Network/O=ValiCert, Inc./OU=ValiCert Class 2 Policy Validation Authority/CN=http://www.valicert.com//emailAddress=info@valicert.com
[111112.673][416010][BRHTTP][08]     issuer:  /L=ValiCert Validation Network/O=ValiCert, Inc./OU=ValiCert Class 2 Policy Validation Authority/CN=http://www.valicert.com//emailAddress=info@valicert.com
[111112.673][416010][BRHTTP][08]     error:   19:self signed certificate in certificate chain
[111112.674][416010][BRHTTP][08] Verifying SSL certificate of peer...
[111112.674][416010][BRHTTP][08] Verifying SSL certificate of peer...
[111112.674][416010][BRHTTP][08] Verifying SSL certificate of peer...
[111112.675][416010][BRHTTP][08] Verifying SSL certificate of peer...
[111112.876][416010][BRHTTP][08] SSL Connection complete using cipher: AES256-SHA
[111112.876][416010][BRHTTP][08] SSL Server certificate:
[111112.876][416010][BRHTTP][08]     subject: /O=*.pogoplug.com/OU=Domain Control Validated/CN=*.pogoplug.com
[111112.876][416010][BRHTTP][08]     issuer:  /C=US/ST=Arizona/L=Scottsdale/O=GoDaddy.com, Inc./OU=http://certificates.godaddy.com/repository/CN=Go Daddy Secure Certification Authority/serialNumber=xxxxxxxx
ERROR: Failed to connect to server: -15!
[111113.313][416010][CEFSAP][08] Application Gracefully exiting...
[111113.313][416010][CEFSAP][08] **********************************************
[111113.313][416010][CEFSAP][08] **********************************************
[111113.313][416010][CEFSAP][08]
[111113.313][416010][CEFSAP][08]


もう一回

#./pogoplugfs --user hoge@hoge.info --passowrd "hogehogeplug" --mountpoint /mnt/pdrive

今度はとまったぞ・・・・

[112511.484][415963][BRHTTP][08] Verifying SSL certificate of peer...
[112511.484][415963][BRHTTP][08] Verifying SSL certificate of peer...
[112511.682][415963][BRHTTP][08] SSL Connection complete using cipher: AES256-SHA
[112511.682][415963][BRHTTP][08] SSL Server certificate:
[112511.682][415963][BRHTTP][08]     subject: /O=*.pogoplug.com/OU=Domain Control Validated/CN=*.pogoplug.com
[112511.682][415963][BRHTTP][08]     issuer:  /C=US/ST=Arizona/L=Scottsdale/O=GoDaddy.com, Inc./OU=http://certificates.godaddy.com/repository/CN=Go Daddy Secure Certification Authority/serialNumber=0x9xx9xxx
[112512.115][415963][CEFSAP][08] Logged in as 'hoge@hoge.info' -> 'xxxnnxnxnnxxxxxxxxxx'


と思ったら、なんかいる!

[root@kvm ~]# df
Filesystem           1K-ブロック    使用   使用可 使用% マウント位置
/dev/mapper/VolGroup00-LogVol00
                     147503388  20918888 118970856  15% /
/dev/sda1               101086     26289     69578  28% /boot
tmpfs                  5029240         0   5029240   0% /dev/shm
/dev/mapper/VolGroup00--2T-LogVol00
                     1888259128 1637740324 153053668  92% /WD2T
/dev/fuse            4294967296 2147483648 2147483648  50% /mnt/pdrive

./pogoplugfsは戻ってきていないが、マウントはできた模様。
Ctlr+Cで終了するとumountされてしまうようだ。

というわけで、私は

#./pogoplugfs --user hoge@hoge.info --passowrd "hogehogeplug" --mountpoint /mnt/pdrive
& 

として使っている。

認証情報を引数で渡しているとパスワードその他がもろバレ

 ps -ef |grep pogo
root      3921  3712  0 11:32 pts/0    00:00:00 ./pogoplugfs --user hoge@hoge.info --passowrd "hogehogeplug" --mountpoint /mnt/pdrive
root      3933  3887  0 11:33 pts/1    00:00:00 grep pogo
& 

なので、ファイルに保存するほうがよい。

[root@kvm tmp]# ./pogoplugfs --help

helpによると

Additionally, options can be read from a configruation file that is in
one of the following locations:
   /pogoplugfs.conf
   ~/.pogoplugfs.conf
   /etc/pogoplugfs.conf
Configuration files are of the form:
   =
And keys supported include:
   svcuser         User to authenticate as if not specified on command line
   svcpassword     User password to authenticate with if not specified
   logseverity     Maximum log level that will be output to the log (integer>

とのことなので、(/tmpでやるのは論外だが・・・)テストのために

[root@kvm tmp]# echo 'svcuser=hoge@hoge.info' >>pogoplugfs.conf
[root@kvm tmp]# echo 'svcpassword=hogehogeplug' >>pogoplugfs.conf
[root@kvm tmp]# ./pogoplugfs --mountpoint /mnt/pdrive&
[root@kvm ~]# ps -ef |grep pogo
root      3965  3712  0 11:40 pts/0    00:00:00 ./pogoplugfs --mountpoint /mnt/pdrive
root      3974  3887  0 11:41 pts/1    00:00:00 grep pogo

いい感じだ。



ところで速度はどうなの?と思って1Gbitで接続した状態のLANから軽くテスト
まあ・・・こんなもんだよね

[root@kvm tmp]# pwd
/mnt/pdrive/I-O DATA HDCR-U/tmp
[root@kvm tmp]# dd if=/dev/zero of=./ddtest bs=1MB count=100
100+0 records in
100+0 records out
100000000 bytes (100 MB) copied, 13.407 seconds, 7.5 MB/s

[root@kvm tmp]# dd if=/dev/zero of=./ddtest bs=1MB count=1000
1000+0 records in
1000+0 records out
1000000000 bytes (1.0 GB) copied, 121.135 seconds, 8.3 MB/s

[root@kvm tmp]# dd of=/dev/zero if=./ddtest bs=1MB count=1000
1000+0 records in
1000+0 records out
1000000000 bytes (1.0 GB) copied, 59.3981 seconds, 16.8 MB/s