Cloud

ConoHa WingでGoogle cloud SDKを使う

前回の記事でConoha WingでGoogle cloud SDKを使う為に、python2.7のインストールについて書きました。
その続きです。

Google cloud SDKはpython2.7より上のバージョンでは動いてくれないので、先にpython2.7を導入しておいてください。

$ gsutil version
ERROR: Python 3 and later is not compatible with the Google Cloud SDK. Please use Python version 2.7.x.

If you have a compatible Python interpreter installed, you can use it by setting
the CLOUDSDK_PYTHON environment variable to point to it.

続きを読む

ConoHa WingでPython2.7を導入する

清楚可愛いこのはちゃんの最強最速レンサバConoHa Wingでgcloud(Google cloud SKD)が使いたかったんですが、gcloudのやつが相変わらずPython2.7より上のバージョンは対応してくれないのでPython2.7.16をConoHa Wingにインストールすることにしました。

便利なaptなど使えないので仕方なくソースコードをビルドして$HOME/local/にpython2.7を導入します。

なお、Google cloud SDKを導入予定の方は、sqlite3が必要になるので先にビルドしておくのがお勧めです。sqlite3のインストール

続きを読む

[Time4VPS] Storage VPSのUnix Bench

コスパ最強とも言われてる(ような)リトアニアのTime4VPSでStorage VPSを借りたのでとりあえずUnix Bench採ってみました。
初期でインストールされているCentOSではなくDebian Stretchで再インストールしてからUnix Benchを走らせました。
Debianは正義です。

契約したプランは0.5 TB Plan。
CPU: 1 vCPU
RAM: 512MB (Swapなし、作成・追加は不可)
Storage: 512GB
Bandwidth: 4TB

それとWebページからReboot時に出るログを見る感じ、
iolimit: 52Mb/s,
iops: 200 iops
なんですね。

Stopping container ...
Container was stopped
Container is unmounted
Starting container...
Container is mounted
Adding IP address(es): 
Setting CPU limit: 0
Setting CPU units: 512
Setting CPUs: 1
Setting devices
Setting iolimit: 52428800 bytes/sec
Setting iopslimit: 200 iops
Container start in progress...

続きを読む

[Debian] CoderでVS CodeなオンラインLaTeX環境を作る

オンラインでVisual Studio Codeが使用できるCoderが最近、OSS化しました。
そこでCode-serverを用いてVPS上に快適な個人LaTeXエディタの環境を整えることにしました。

備忘録です。

今回のVPSの環境は
・ASW – Lightsail 2GB
・Debian Stretch
です。

Coderの導入に関しては、正直バイナリファイルを落としてくるだけなので簡単です。
LaTeXの導入に若干の時間がかかります。

ただ問題点が、
・PDFのプレビューが見れない
・拡張機能のインストールと使用に若干の難がある
の2つがあります。
今後のアップデートに期待です。

続きを読む

[AWS – Lightsail] SSHのセキュア設定

なんか謎にGCEのf1-microが課金されだしたので、去年の夏頃に半額になりすごくお得感のあるAWSのLightsailに乗り換えました。

一番安いプランで$3.5! 素晴らしい。
加えて一番安いプランは一ヶ月無料なんですね!

3.50 USD にて Lightsail プランを 1 か月間 (750 時間まで) 無料で ご利用いただけます。Microsoft Windows Server をご利用の場合は、8 USD のプランを 1 か月間無料でご利用いただけます。また、マネージドデータベースプランをご利用の場合には、15 USD のプランを 1 か月無料でご利用いただけます。最初の Lightsail サーバーを起動する際に適切なプランを選択すると、お客様のアカウントに 1 か月間無料のクレジットが付与されます。*
https://aws.amazon.com/jp/lightsail/pricing/

Lightsailは実質T2インスタンスのCPUクレジットを絞ったバージョンと聞いたので、CPUをよく使う用途には向いてませんが個人のブログとかでは十分でしょう。


今回は大好きなDebian Stretchを使用しています。UbuntuでもSSHの設定はほぼ変わらないです。CentOSは知らないです(´・ω・`)

続きを読む

GCE f1-microで課金?

2019/03/29追記

いつの間にか若干Always freeの内容が変わっていてf1-microが無料で使えるリージョンが3箇所のみになってました。
us-west1 (Oregon), us-central1(Iowa), us-east1(South Carolina)です。

1 non-preemptible f1-micro VM instance per month in one of the following US regions:
Oregon: us-west1
Iowa: us-central1
South Carolina: us-east1
https://cloud.google.com/free/docs/gcp-free-tier

これのせいですね。


VPSに極力お金を使いたくない人の強い味方のGoogle Cloud PlatformのCompute Engine, f1-microさん。
f1-microはAlways free((Always Free, which provides limited access to many common GCP resources, free of charge.
https://cloud.google.com/free/docs/gcp-free-tier
))に毎月1ヶ月分無料の枠があります。
1つのインスタンスはただで使えるわけですね。嬉しいです!

おさらいですが、GCEのAlways freeは

1 f1-micro instance per month (US regions only – Excluding Northern Virginia [us-east4])

30 GB-months HDD, 5 GB-months snapshot

1 GB network egress from North America to all region destinations per month (excluding China and Australia)
https://cloud.google.com/free/

となっています。

しかし、久しぶりに「料金の履歴」を見てみると…

Compute Engine Micro Instance with burstable CPU running in Los Angeles: 151.138 時間 [通貨換算: USD から JPY(レート 109.43 を使用)]

はて、これは一体…?今までなかったぞ…(´・ω・`)

f1-microはus-east4のヴァージニアを除いた米国リージョンで無料のはずなんですが…
f1-microのインスタンスは一つしか立ってないし無料時間分を超えたとも思えない…

構成は、
us-west2, HDD 30GB, debian
と無料枠に収まっています。

不思議ですねえ。

一応Always freeの利用資格「Program eligibility」に
Have an account in good standing.
なんて文言があるので、もしかしたら何かに引っかかったんでしょうか。

しばらく様子見です。

ConoHa WINGにさくっとNextCloudを導入

The Web Installer is the easiest way to install Nextcloud on a web space. It checks the dependencies, downloads Nextcloud from the official server, unpacks it with the right permissions and the right user account. Finally, you will be redirected to the Nextcloud installer.

Right-click here and save the file to your computer
Upload setup-nextcloud.php to your web space
Point your web browser to setup-nextcloud.php on your webspace
Follow the instructions and configure Nextcloud
Login to your newly created Nextcloud instance!
You can find further instructions in the Nextcloud Admin Manual.

Note that the installer uses the same Nextcloud version as available for the built in updater in Nextcloud. After a major release it can take up to a month before it becomes available through the web installer and the updater. This is done to spread the deployment of new major releases out over time.

https://nextcloud.com/install/#instructions-server

1.setup-nextcloud.phpの設置
NexeCloudがsetup-nextcloud.phpという便利なものを用意してくれているのでサクっと使ってしまいましょう。
ssh使うか、ブラウザでsetup-nextcloud.phpをダウンロードしてConoHaのファイルマネージャーからpublic_html/domainフォルダにアップロードします。

$ cd publich_html/xxxxxx
$ wget https://download.nextcloud.com/server/installer/setup-nextcloud.php

2.setup-nextcloud.phpにアクセスして指示に従う。
setup-nextcloud.phpの設置後に設置場所にアクセスします。https://domain.xxx/setup-nextcloud.phpのような感じで。
MySQLのデータベースはConoHa WINGの管理画面から作成出来るものを使っておけば問題ないでしょう。
 

 
 
非常に簡単ですね!!
やり方次第ではSSHを用いらずに導入できるので、CLIアレルギーの方も安心!
200GBの容量を何とか活用できそうです。

[GCP] Cloud Shellのベンチマーク

Google Cloud Platformに関する作業などがブラウザから簡単に行うことができるCloud Shell
外出先等でちょっと用事があるときに非常に便利ですよね。
今回はこのCloud ShellのベンチマークをUnixBenchで採ってみました。
ところで、Cloud ShellはGCEのg1-smallらしいです。(ブースト時はn1-standard-1)
前はg1-smallではなくf1-microだった気がするんですけど、気のせいですかね?

特徴

・Compute Engine での一時的な仮想マシン インスタンス
・ウェブブラウザからインスタンスへのコマンドライン アクセス
・組み込みのコードエディタ ベータ版
・5 GB の永続ディスク ストレージ
・プレインストールされた Google Cloud SDK とその他のツール
・Java、Go、Python、Node.js、PHP、Ruby、.NET への言語対応
・ウェブ プレビュー機能
・GCP Console のプロジェクトとリソースに対するアクセスのビルトイン承認
https://cloud.google.com/shell/docs/features

通常はCloud Shellを開いた時、g1-smallがプロビジョニングされます。
ブーストモードを有効にした場合はn1-standard-1としてプロビジョニングされます。

また、実は週単位で使用できる時間に制限があるようです。

サーバースペック

g1-small

0.5 基の仮想 CPU と 1.70 GB のメモリを備え、共有物理コアを基盤とした共有コア マシンタイプ。
https://cloud.google.com/compute/docs/machine-types

:~$ free -m
              total        used        free      shared  buff/cache   available
Mem:           1695         362         463           0         869        1180
Swap:             0           0           0

:~$ df -Th
Filesystem     Type     Size  Used Avail Use% Mounted on
overlay        overlay   31G   22G  8.4G  73% /
tmpfs          tmpfs    848M     0  848M   0% /dev
tmpfs          tmpfs    848M     0  848M   0% /sys/fs/cgroup
/dev/sda1      ext4      31G   22G  8.4G  73% /root
/dev/sdb1      ext4     4.8G   12M  4.6G   1% /home
overlayfs      overlay  1.0M  108K  916K  11% /etc/ssh/keys
tmpfs          tmpfs    848M  720K  847M   1% /run/metrics
shm            tmpfs     64M     0   64M   0% /dev/shm
overlayfs      overlay  1.0M  108K  916K  11% /etc/ssh/ssh_host_dsa_key
tmpfs          tmpfs    848M     0  848M   0% /run/google/devshell

n1-standard-1

1 基の仮想 CPU と 3.75 GB のメモリを備えた標準マシンタイプ。
https://cloud.google.com/compute/docs/machine-types

~$ free -m
              total        used        free      shared  buff/cache   available
Mem:           3698         352        2171           0        1175        3119
Swap:             0           0           0

:~$ df -Th
Filesystem     Type     Size  Used Avail Use% Mounted on
overlay        overlay   31G   23G  8.3G  73% /
tmpfs          tmpfs    1.9G     0  1.9G   0% /dev
tmpfs          tmpfs    1.9G     0  1.9G   0% /sys/fs/cgroup
/dev/sda1      ext4      31G   23G  8.3G  73% /root
/dev/sdb1      ext4     4.8G   12M  4.6G   1% /home
overlayfs      overlay  1.0M  108K  916K  11% /etc/ssh/keys
tmpfs          tmpfs    1.9G  676K  1.9G   1% /run/metrics
shm            tmpfs     64M     0   64M   0% /dev/shm
overlayfs      overlay  1.0M  108K  916K  11% /etc/ssh/ssh_host_rsa_key
tmpfs          tmpfs    1.9G     0  1.9G   0% /run/google/devshell

$ cat /proc/cpuinfo
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 62
model name      : Intel(R) Xeon(R) CPU @ 2.50GHz
stepping        : 4
microcode       : 0x1
cpu MHz         : 2500.000
cache size      : 30720 KB
physical id     : 0
siblings        : 1
core id         : 0
cpu cores       : 1
apicid          : 0
initial apicid  : 0
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc cpuid pni pclmulqdq ssse3 cx16 sse4_1 sse4_2 x2apic popcnt aes xsave avx f16c rdrand hypervisor lahf_lm pti fsgsbase tsc_adjust smep erms xsaveopt
bugs            : cpu_meltdown spectre_v1 spectre_v2 l1tf
bogomips        : 5000.00
clflush size    : 64
cache_alignment : 64
address sizes   : 46 bits physical, 48 bits virtual
power management:

UnixBench

通常時

通常時のUnixBench。

========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: cs-6000-devshell-vm-xxxxxx: GNU/Linux
   OS: GNU/Linux -- 4.14.33+ -- #1 SMP Sat Aug 11 08:05:16 PDT 2018
   Machine: x86_64 (unknown)
   Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
   CPU 0: Intel(R) Xeon(R) CPU @ 2.50GHz (5000.0 bogomips)
          Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
   00:35:02 up 15 min,  2 users,  load average: 0.14, 0.33, 0.20; runlevel

------------------------------------------------------------------------
Benchmark Run: Mon Aug 20 2018 00:35:02 - 01:04:05
1 CPU in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       29138732.1 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     2942.8 MWIPS (13.0 s, 7 samples)
Execl Throughput                               1947.3 lps   (29.9 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        200275.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           56955.0 KBps  (30.1 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        538326.0 KBps  (30.0 s, 2 samples)
Pipe Throughput                              310676.5 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  79299.3 lps   (10.0 s, 7 samples)
Process Creation                               5724.0 lps   (30.1 s, 2 samples)
Shell Scripts (1 concurrent)                   3252.4 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    397.4 lpm   (60.2 s, 2 samples)
System Call Overhead                         180235.1 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   29138732.1   2496.9
Double-Precision Whetstone                       55.0       2942.8    535.1
Execl Throughput                                 43.0       1947.3    452.9
File Copy 1024 bufsize 2000 maxblocks          3960.0     200275.9    505.7
File Copy 256 bufsize 500 maxblocks            1655.0      56955.0    344.1
File Copy 4096 bufsize 8000 maxblocks          5800.0     538326.0    928.1
Pipe Throughput                               12440.0     310676.5    249.7
Pipe-based Context Switching                   4000.0      79299.3    198.2
Process Creation                                126.0       5724.0    454.3
Shell Scripts (1 concurrent)                     42.4       3252.4    767.1
Shell Scripts (8 concurrent)                      6.0        397.4    662.3
System Call Overhead                          15000.0     180235.1    120.2
                                                                   ========
System Benchmarks Index Score                                         475.7

ブーストモード

ブーストモードを有効にしたときのUnixBench。

========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: cs-6000-devshell-vm-xxxxx: GNU/Linux
   OS: GNU/Linux -- 4.14.33+ -- #1 SMP Sat Aug 11 08:05:16 PDT 2018
   Machine: x86_64 (unknown)
   Language: en_US.utf8 (charmap="UTF-8", collate="UTF-8")
   CPU 0: Intel(R) Xeon(R) CPU @ 2.50GHz (5000.0 bogomips)
          Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
   01:12:24 up 10:31,  2 users,  load average: 0.26, 0.10, 0.03; runlevel

------------------------------------------------------------------------
Benchmark Run: Mon Aug 20 2018 01:12:24 - 01:40:32
1 CPU in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       30024941.0 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     3797.8 MWIPS (9.8 s, 7 samples)
Execl Throughput                               3630.8 lps   (29.5 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        332742.6 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           90811.0 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        903244.8 KBps  (30.0 s, 2 samples)
Pipe Throughput                              487114.9 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 115958.0 lps   (10.0 s, 7 samples)
Process Creation                              10922.9 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   6742.0 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                    838.9 lpm   (60.0 s, 2 samples)
System Call Overhead                         276681.1 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   30024941.0   2572.8
Double-Precision Whetstone                       55.0       3797.8    690.5
Execl Throughput                                 43.0       3630.8    844.4
File Copy 1024 bufsize 2000 maxblocks          3960.0     332742.6    840.3
File Copy 256 bufsize 500 maxblocks            1655.0      90811.0    548.7
File Copy 4096 bufsize 8000 maxblocks          5800.0     903244.8   1557.3
Pipe Throughput                               12440.0     487114.9    391.6
Pipe-based Context Switching                   4000.0     115958.0    289.9
Process Creation                                126.0      10922.9    866.9
Shell Scripts (1 concurrent)                     42.4       6742.0   1590.1
Shell Scripts (8 concurrent)                      6.0        838.9   1398.1
System Call Overhead                          15000.0     276681.1    184.5
                                                                   ========
System Benchmarks Index Score                                         770.0

Index Score

通常時とブーストモードで3回UnixBenchを走らせた結果デス。

通常時ブーストモードg1-smalln1-standard-1f1-micro
1475.7770.0847.71313.6152.1
2483.0768.8
3476.8769.0

おまけ

比較のため、f1-micro, g1-small, n1-standard-1のUnixBenchも採ったので載せておきます。

g1-small
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: g1small: GNU/Linux
   OS: GNU/Linux -- 4.9.0-7-amd64 -- #1 SMP Debian 4.9.110-3+deb9u2 (2018-08-13)
   Machine: x86_64 (unknown)
   Language: en_US.utf8 (charmap="ANSI_X3.4-1968", collate="ANSI_X3.4-1968")
   CPU 0: Intel(R) Xeon(R) CPU @ 2.30GHz (4600.0 bogomips)
          Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
   01:53:20 up 3 min,  1 user,  load average: 0.08, 0.04, 0.01; runlevel Aug

------------------------------------------------------------------------
Benchmark Run: Mon Aug 20 2018 01:53:20 - 02:22:12
1 CPU in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       30951363.0 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     3507.5 MWIPS (12.2 s, 7 samples)
Execl Throughput                               2996.6 lps   (30.0 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        458268.7 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks          133952.0 KBps  (30.1 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks       1218898.4 KBps  (30.0 s, 2 samples)
Pipe Throughput                              776309.5 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 135166.1 lps   (10.0 s, 7 samples)
Process Creation                               8439.8 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   4922.6 lpm   (60.1 s, 2 samples)
Shell Scripts (8 concurrent)                    617.5 lpm   (60.1 s, 2 samples)
System Call Overhead                         527722.7 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   30951363.0   2652.2
Double-Precision Whetstone                       55.0       3507.5    637.7
Execl Throughput                                 43.0       2996.6    696.9
File Copy 1024 bufsize 2000 maxblocks          3960.0     458268.7   1157.2
File Copy 256 bufsize 500 maxblocks            1655.0     133952.0    809.4
File Copy 4096 bufsize 8000 maxblocks          5800.0    1218898.4   2101.5
Pipe Throughput                               12440.0     776309.5    624.0
Pipe-based Context Switching                   4000.0     135166.1    337.9
Process Creation                                126.0       8439.8    669.8
Shell Scripts (1 concurrent)                     42.4       4922.6   1161.0
Shell Scripts (8 concurrent)                      6.0        617.5   1029.2
System Call Overhead                          15000.0     527722.7    351.8
                                                                   ========
System Benchmarks Index Score                                         847.7
n1-standard-1
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: n1standard1: GNU/Linux
   OS: GNU/Linux -- 4.9.0-7-amd64 -- #1 SMP Debian 4.9.110-3+deb9u2 (2018-08-13)
   Machine: x86_64 (unknown)
   Language: en_US.utf8 (charmap="ANSI_X3.4-1968", collate="ANSI_X3.4-1968")
   CPU 0: Intel(R) Xeon(R) CPU @ 2.30GHz (4600.0 bogomips)
          Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
   01:53:04 up 3 min,  1 user,  load average: 0.19, 0.07, 0.02; runlevel Aug

------------------------------------------------------------------------
Benchmark Run: Mon Aug 20 2018 01:53:04 - 02:21:11
1 CPU in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       31460987.6 lps   (10.0 s, 7 samples)
Double-Precision Whetstone                     4176.3 MWIPS (9.9 s, 7 samples)
Execl Throughput                               5369.1 lps   (30.0 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        735957.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks          209307.4 KBps  (30.0 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks       1854594.5 KBps  (30.0 s, 2 samples)
Pipe Throughput                             1130884.6 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                 208971.2 lps   (10.0 s, 7 samples)
Process Creation                              15182.0 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   9874.3 lpm   (60.0 s, 2 samples)
Shell Scripts (8 concurrent)                   1206.0 lpm   (60.0 s, 2 samples)
System Call Overhead                         769258.9 lps   (10.0 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   31460987.6   2695.9
Double-Precision Whetstone                       55.0       4176.3    759.3
Execl Throughput                                 43.0       5369.1   1248.6
File Copy 1024 bufsize 2000 maxblocks          3960.0     735957.9   1858.5
File Copy 256 bufsize 500 maxblocks            1655.0     209307.4   1264.7
File Copy 4096 bufsize 8000 maxblocks          5800.0    1854594.5   3197.6
Pipe Throughput                               12440.0    1130884.6    909.1
Pipe-based Context Switching                   4000.0     208971.2    522.4
Process Creation                                126.0      15182.0   1204.9
Shell Scripts (1 concurrent)                     42.4       9874.3   2328.8
Shell Scripts (8 concurrent)                      6.0       1206.0   2010.1
System Call Overhead                          15000.0     769258.9    512.8
                                                                   ========
System Benchmarks Index Score                                        1313.6
f1-micro
========================================================================
   BYTE UNIX Benchmarks (Version 5.1.3)

   System: f1micro: GNU/Linux
   OS: GNU/Linux -- 4.9.0-7-amd64 -- #1 SMP Debian 4.9.110-3+deb9u2 (2018-08-13)
   Machine: x86_64 (unknown)
   Language: en_US.utf8 (charmap="ANSI_X3.4-1968", collate="ANSI_X3.4-1968")
   CPU 0: Intel(R) Xeon(R) CPU @ 2.30GHz (4600.0 bogomips)
          Hyper-Threading, x86-64, MMX, Physical Address Ext, SYSENTER/SYSEXIT, SYSCALL/SYSRET
   01:52:55 up 2 min,  1 user,  load average: 0.22, 0.10, 0.03; runlevel Aug

------------------------------------------------------------------------
Benchmark Run: Mon Aug 20 2018 01:52:55 - 02:23:43
1 CPU in system; running 1 parallel copy of tests

Dhrystone 2 using register variables       17570154.4 lps   (10.1 s, 7 samples)
Double-Precision Whetstone                      838.1 MWIPS (28.3 s, 7 samples)
Execl Throughput                               1218.6 lps   (30.0 s, 2 samples)
File Copy 1024 bufsize 2000 maxblocks        161377.9 KBps  (30.0 s, 2 samples)
File Copy 256 bufsize 500 maxblocks           39812.8 KBps  (30.1 s, 2 samples)
File Copy 4096 bufsize 8000 maxblocks        330861.9 KBps  (30.0 s, 2 samples)
Pipe Throughput                              340018.4 lps   (10.0 s, 7 samples)
Pipe-based Context Switching                  62298.5 lps   (10.0 s, 7 samples)
Process Creation                               3822.6 lps   (30.0 s, 2 samples)
Shell Scripts (1 concurrent)                   2085.7 lpm   (60.1 s, 2 samples)
Shell Scripts (8 concurrent)                    288.9 lpm   (60.2 s, 2 samples)
System Call Overhead                         228185.5 lps   (10.1 s, 7 samples)

System Benchmarks Index Values               BASELINE       RESULT    INDEX
Dhrystone 2 using register variables         116700.0   17570154.4   1505.6
Double-Precision Whetstone                       55.0        838.1    152.4
Execl Throughput                                 43.0       1218.6    283.4
File Copy 1024 bufsize 2000 maxblocks          3960.0     161377.9    407.5
File Copy 256 bufsize 500 maxblocks            1655.0      39812.8    240.6
File Copy 4096 bufsize 8000 maxblocks          5800.0     330861.9    570.5
Pipe Throughput                               12440.0     340018.4    273.3
Pipe-based Context Switching                   4000.0      62298.5    155.7
Process Creation                                126.0       3822.6    303.4
Shell Scripts (1 concurrent)                     42.4       2085.7    491.9
Shell Scripts (8 concurrent)                      6.0        288.9    481.4
System Call Overhead                          15000.0     228185.5    152.1
                                                                   ========
System Benchmarks Index Score                                         330.4

最後に

Index Scoreをざっと見ると、Cloud Shellはg1-smallがプロビジョニングされているとは言えだいぶ制限されているように見えます。
通常時はf1-microより少しいいぐらいで、ブースト時にg1-small相当のような感じでしょうか。
Cloud Shellは無料で使えるので勿論十分すぎるといえば十分すぎますね。

Kusanagi for ConoHa で最低限しておきたいSSHのセキュリティ設定

昨日ぐらいにGCEのf1-micro(とロリポップ)からConoHaに乗り換えました。

 
このはちゃん可愛い…

普段はDebianを使っているのですがWordPressやらの環境を整えるのが面倒くさいので、手抜きでKUSANAGI for ConoHaを使うことにしました。
CentOSがベースなんですね…うぅ…

では、KUSANAGI for ConoHaに限らず本当に最低限しておきたいセキュリティ設定です。
続きを読む