1.使用OSS作为文件服务器,保存一些常用的资料
开通方法就不说了,主要是linux系统上传和下载相关内容
首先,需要安装客户端
https://help.aliyun.com/document_detail/50452.html?spm=a2c4g.11186623.6.841.82037f85BWlPVt
wget http://gosspublic.alicdn.com/ossutil/1.6.19/ossutil64
需要进行配置:
./ossutil64 config
endpoint=oss-cn-beijing.aliyuncs.com
accessKeyID=
accessKeySecret=
接着就通过命令操作就行,和linux文件基本操作一样
[hadoop@hadoop-001 test]$ sudo ./ossutil64 ls oss://eric-doc/ LastModifiedTime Size(B) StorageClass ETAG ObjectName 2020-10-14 14:41:02 +0800 CST 197657687 Standard F6BEE933AEE535CD6F80422A2D7FCF6D-78 oss://eric-doc/hadoop -2.7.2.tar.gzObject Number is: 1 0.032499(s) elapsed [hadoop@hadoop-001 test]$ sudo ./ossutil64 cp oss://eric-doc/hadoop-2.7.2.tar.gz /opt/test/ Succeed: Total num: 1, size: 197,657,687. OK num: 1(download 1 objects). average speed 13658000(byte/s) 14.472077(s) elapsed [hadoop@hadoop-001 test]$