Alibaba Cloud ECS installs ossfs

Alibaba Cloud ECS installs ossfs

 

git clone https://github.com/aliyun/ossfs.git

cd ossfs

./autogen.sh

./configure

make

make install

 

The following error occurs:

checking for pkg-config... /usr/bin/pkg-config

checking pkg-config is at least version 0.9.0... yes

checking for common_lib_checking... no

configure: error: Package requirements (fuse >= 2.8.4 libcurl >= 7.0 libxml-2.0 >= 2.6) were not met:

 

No package 'fuse' found

 

Consider adjusting the PKG_CONFIG_PATH environment variable if you

installed software in a non-standard prefix.

 

The solution is to use root user to install

 

yum -y install libxml2-devel fuse fuse-* glib2 glib2-*

 

View installed fuse

rpm -qa |grep fuse

 

 

echo my-bucket:my-access-key-id:my-access-key-secret > /etc/passwd-ossfs

chmod 640 /etc/passwd-ossfs

mkdir /tmp/ossfs

Mount the oss bucket to the specified directory (ossfs my-bucket my-mount-point -ourl=my-oss-endpoint)

If the machine using ossfs is Alibaba Cloud ECS, you can use the intranet domain name to avoid traffic charges and improve the speed:

ossfs my-bucket /tmp/ossfs -ourl=http://oss-cn-hangzhou-internal.aliyuncs.com

 

If an error occurs use the -f parameter

 

After completing the test, copy the file to /tmp/ossfs, and then check whether the file has been uploaded to the specified bucket in the Alibaba Cloud console.

 

 

refer to:

https://github.com/aliyun/ossfs

http://zhujiangtao.blog.51cto.com/6387416/1437887

Guess you like

Origin http://10.200.1.11:23101/article/api/json?id=326710918&siteId=291194637