建立服務帳戶

建立 gsfuse 名稱

選角色
權限授予 storage 管理員
建立金鑰

安裝 gcsfuse
系統掛載 gcp storage
$ export GCSFUSE_REPO=gcsfuse-`lsb_release -c -s`
$ echo "deb http://packages.cloud.google.com/apt $GCSFUSE_REPO main" | sudo tee /etc/apt/sources.list.d/gcsfuse.list
$ curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | sudo apt-key add -
$ sudo apt-get update
$ sudo apt-get install gcsfuse
# mkdir /test
upload gcp.json and mount
# gcsfuse --key-file /root/tonal-studio-176502-9c4092f1dfa6.json devops-test-2 /test
vi /etc/rc.local
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
gcsfuse --key-file /root/tonyxxx.json devops-test-2 /test
exit 0
test
https://blog.toright.com/posts/5051/linux-disk-io-%E6%95%88%E8%83%BD%E6%B8%AC%E8%A9%A6.html
sysbench –test=fileio –num-threads=20 –file-total-size=1G –file-test-mode=rndrw prepare