站长视角
用户至上

2022年谷歌无限网盘申请和VPS挂载谷歌网盘的方法

优质广告位招租,欢迎联系站长

虽然谷歌盘盘对网盘进行了捕捉的搬运限制,但还有足够的谷歌能力对个人还是有很大的作用,只要不饲养还是可以长期使用的,今天来说一下如何申请谷歌团队盘,不是把队伍盘挂到你的VPS上,挂载后可以安装离线下载,音影库,等等可以翻墙访问,注意:必须在vps上安装xray才能后续操作。

一、申请无限空间谷歌团队盘

2021年谷歌团队盘申请网址

中文  https://gdrive.zppcw.cn/

越南   https://team.gdrive.vip/

二、Rclone挂载谷歌团队盘

下面以centos系统为例

必要升级

 yum update && yum upgrade

安装命令

curl https://rclone.org/install.sh | sudo bash

配置rclone

 rclone config

开始配置

n) New remote
 s) Set configuration password
 q) Quit config
 n/s/q> n   #输入n回车,新建配置
 name> gd   #新建配置的名称,随意填写,后面会用到
 Type of storage to configure.
 Enter a string value. Press Enter for the default ("").
 Choose a number from below, or type in your own value
  1 / 1Fichier
     "fichier"
  2 / Alias for an existing remote
     "alias"
  3 / Amazon Drive
     "amazon cloud drive"
  4 / Amazon S3 Compliant Storage Provider (AWS, Alibaba, Ceph, Digital Ocean, Dreamhost, IBM COS, Minio, etc)
     "s3"
  5 / Backblaze B2
     "b2"
  6 / Box
     "box"
  7 / Cache a remote
     "cache"
  8 / Dropbox
     "dropbox"
  9 / Encrypt/Decrypt a remote
     "crypt"
 10 / FTP Connection
     "ftp"
 11 / Google Cloud Storage (this is not Google Drive)
     "google cloud storage"
 12 / Google Drive
     "drive"
 13 / Google Photos
     "google photos"
 14 / Hubic
     "hubic"
 15 / JottaCloud
     "jottacloud"
 16 / Koofr
     "koofr"
 17 / Local Disk
     "local"
 18 / Mega
     "mega"
 19 / Microsoft Azure Blob Storage
     "azureblob"
 20 / Microsoft OneDrive
     "onedrive"
 21 / OpenDrive
     "opendrive"
 22 / Openstack Swift (Rackspace Cloud Files, Memset Memstore, OVH)
     "swift"
 23 / Pcloud
     "pcloud"
 24 / Put.io
     "putio"
 25 / QingCloud Object Storage
     "qingstor"
 26 / SSH/SFTP Connection
     "sftp"
 27 / Union merges the contents of several remotes
     "union"
 28 / Webdav
     "webdav"
 29 / Yandex Disk
     "yandex"
 30 / http Connection
     "http"
 31 / premiumize.me
     "premiumizeme"
 Storage> 12       #选择需要挂载的网盘
 ** See help for drive backend at: https://rclone.org/drive/ **
 
 Google Application Client Id
 Setting your own is recommended.
 See https://rclone.org/drive/#making-your-own-client-id for how to create your own.
 If you leave this blank, it will use an internal key which is low performance.
 Enter a string value. Press Enter for the default ("").
 client_id>       #默认直接回车,或者输入自己的OAuth ID
 Google Application Client Secret
 Setting your own is recommended.
 Enter a string value. Press Enter for the default ("").
 client_secret>   #默认直接回车,或者输入自己的OAuth秘锁
 Scope that rclone should use when requesting access from drive.
 Enter a string value. Press Enter for the default ("").
 Choose a number from below, or type in your own value
  1 / Full access all files, excluding Application Data Folder.
     "drive"
  2 / Read-only access to file metadata and file contents.
     "drive.readonly"
    / Access to files created by rclone only.
  3 | These are visible in the drive website.
    | File authorization is revoked when the user deauthorizes the app.
     "drive.file"
    / Allows read and write access to the Application Data folder.
  4 | This is not visible in the drive website.
     "drive.appfolder"
    / Allows read-only access to file metadata but
  5 | does not allow any access to read or download file content.
     "drive.metadata.readonly"
 scope> 1         #默认输入1回车
 ID of the root folder
 Leave blank normally.
 Fill in to access "Computers" folders. (see docs).
 Enter a string value. Press Enter for the default ("").
 root_folder_id> #默认直接回车
 Service Account Credentials JSON file path
 Leave blank normally.
 Needed only if you want use SA instead of interactive login.
 Enter a string value. Press Enter for the default ("").
 service_account_file>
 Edit advanced config? (y/n)
 y) Yes
 n) No
 y/n> n           #是否编辑高级配置,输入n回车
 Remote config
 Use auto config?
  * Say Y if not sure
  * Say N if you are working on a remote or headless machine
 y) Yes
 n) No
 y/n> n         #是否使用自动配置,输入n回车
 If your browser doesn't open automatically go to the following link: https://accounts.google.com/o/oauth2/XXX
 Log in and authorize rclone for access
 Enter verification code> XXXX #复制上面的链接在浏览器中打开,将得到的授权码复制到这里后回车
 Configure this as a team drive?
 y) Yes
 n) No
 y/n> y         #是否挂载团队网盘,如果没有输入n回车,需要挂载团队版输入y回车
 Fetching team drive list...
 Choose a number from below, or type in your own value
  1 / SunPma
     "0ADYACmKjlU3JUk9PVA"
 Enter a Team Drive ID> 1     #选择你需要挂载的团队盘然后回车
 --------------------
 [SUNPMAGD]
 type = drive
 scope = drive
 token = {"access_token":"XXX","expiry":"2019-10-23T14:32:06.481207275+08:00"}
 team_drive = 0ADYACmKjlU3JUk9PVA
 --------------------
 y) Yes this is OK
 e) Edit this remote
 d) Delete this remote
 y/e/d> y       #默认输入y回车
 Current remotes:
 
 Name                 Type
 ====                 ====
 SUNPMAGD             drive
 
 e) Edit existing remote
 n) New remote
 d) Delete remote
 r) Rename remote
 c) Copy remote
 s) Set configuration password
 q) Quit config
 e/n/d/r/c/s/q> q   #输入q回车,保存配置退出

新建本地挂载文件夹

 mkdir /home/gd

挂载磁盘命令说明

 #/usr/bin/rclone mount DriveName:Folder LocalFolder 
 下面整体代码中最上面的这条需要自己修改,不要直接复制,注意代码中有空格
 DriveName       #配置时填写的name
 Folder         #网盘里要挂载的文件夹名
 LocalFolder     #本地要挂载的文件夹绝对路径
 例:/usr/bin/rclone mount gd: /home/gd

挂载

#下面代码是一个整体,全部复制后粘贴运行
 /usr/bin/rclone mount gd: /home/gd 
  --umask 0000 
  --default-permissions 
  --allow-non-empty 
  --allow-other 
  --transfers 1 
  --buffer-size 64M 
  --low-level-retries 200 
  --dir-cache-time 12h 
  --vfs-read-chunk-size 32M 
  --vfs-read-chunk-size-limit 1G
  #如果你还涉及到读取使用,比如使用H5ai等在线播放,就在后面多加上最后三条参数

参数说明

--transfers:该参数是最大同时传输任务数量,如果经常传输大文件,或CPU性能不佳,建议设置为单线程,也就是设置为“1”
 --buffer-size:该参数为读取每个文件时的内存缓冲区大小,控制rclone上传和挂载的时候的内存占用
 --low-level-retries:该参数为传输文件没速度的时候重试次数,没速度的时候,单个会自动睡眠10ms起,然后再重试

如果挂载时候出错如下图:

2022年谷歌无限网盘申请和VPS挂载谷歌网盘的方法如果出错安装fuse

 yum install fuse

查看是否成功

 df -h

如下图显示gd 挂载成功

2022年谷歌无限网盘申请和VPS挂载谷歌网盘的方法

三、开机启动

找到/etc/systemd/system ,在里面新建一个名为 rclone.service 的文件,文件的完整路径为 /etc/systemd/system/rclone.service 然后在文件中填入以下代码。

 [Unit]
 Description=Rclone
 AssertPathIsDirectory=/home/gd
 After=network-online.target
 
 [Service]
 Type=simple
 ExecStart=/usr/bin/rclone mount gd: /home/gd 
  --umask 0000 
  --default-permissions 
  --allow-non-empty 
  --allow-other 
  --transfers 1 
  --buffer-size 64M 
  --low-level-retries 200 
  --dir-cache-time 12h 
  --vfs-read-chunk-size 32M 
  --vfs-read-chunk-size-limit 1G
 ExecStop=/bin/fusermount -u /home/gd
 Restart=on-abort
 User=root
 
 [Install]
 WantedBy=default.target

启动rclone

 systemctl start rclone

开机启动rclone

 systemctl enable rclone

rclone常用命令

 重启:systemctl restart rclone
 停止:systemctl stop rclone
 状态:systemctl status rclone

另外备注:如果你想要用宝塔面板安装可道云网盘的web管理界面,那就把谷歌盘挂载在可道云下面!只需要修改开机配置文件如下

[Unit]
Description=Rclone
AssertPathIsDirectory=/www/wwwroot/你的域名/data/User/admin/home/gd
After=network-online.target

[Service]
Type=simple
ExecStart=/usr/bin/rclone mount gd: /www/wwwroot/你的域名/data/User/admin/home/gd 
 --umask 0000 
 --default-permissions 
 --allow-non-empty 
 --allow-other 
 --transfers 1 
 --buffer-size 64M 
 --low-level-retries 200 
 --dir-cache-time 12h 
 --vfs-read-chunk-size 32M 
 --vfs-read-chunk-size-limit 1G
ExecStop=/bin/fusermount -u /www/wwwroot/你的域名/data/User/admin/home/gd
Restart=on-abort
User=root

[Install]
WantedBy=default.target

搬瓦工推荐方案

温馨提醒 如果您有选择困难症,直接选中间的 CN2 GIA-E方案,季付 $49.99,多达 12 个机房任意切换
方案 内存 CPU 硬盘 流量/月 带宽 机房 价格 购买
CN2
(最便宜)
1GB 1核 20GB 1TB 1Gbps DC3 CN2
DC8 ZNET
$49.99/年 购买
CN2 2GB 1核 40GB 2TB 1Gbps $52.99/半年
$99.99/年
购买
CN2 GIA-E
(最推荐)
1GB 2核 20GB 1TB 2.5Gbps DC6 CN2 GIA-E
DC9 CN2 GIA
日本软银 JPOS_1
荷兰 EUNL_9
$49.99/季度
$169.99/年
购买
CN2 GIA-E 2GB 3核 40GB 2TB 2.5Gbps $89.99/季度
$299.99/年
购买
HK 2GB 2核 40GB 0.5TB 1Gbps 中国香港 CN2 GIA $89.99/月
$899.99/年
购买
HK 4GB 4核 80GB 1TB 1Gbps $155.99/月
$1559.99/年
购买
TOKYO 2GB 2核 40GB 0.5TB 1.2Gbps 日本东京 CN2 GIA $89.99/月
$899.99/年
购买
TOKYO 4GB 4核 80GB 1TB 1.2Gbps $155.99/月
$1559.99/年
购买
搬瓦工优惠码:BWH3HYATVBJW

选择建议:

  • 入门:洛杉矶 CN2 套餐,目前最便宜,可选 CN2 GT 机房,入门之选。
  • 推荐:洛杉矶 CN2 GIA-E 套餐,速度超快,可选机房多(DC6、DC9、日本软银、荷兰联通等),性价比最高。
  • 高端:香港 CN2 GIA 套餐,价格较高,但是无可挑剔。东京 CN2 GIA 套餐也是非常不错的高端选择。
赞(0)
版权声明:本文采用知识共享 署名4.0国际许可协议 [BY-NC-SA] 进行授权, 转载请注明出处。
文章名称:《2022年谷歌无限网盘申请和VPS挂载谷歌网盘的方法》
文章链接:https://cnidc.co/28143.html
【声明】:国外主机测评仅分享信息,不参与任何交易,也非中介,所有内容仅代表个人观点,均不作直接、间接、法定、约定的保证,读者购买风险自担。一旦您访问国外主机测评,即表示您已经知晓并接受了此声明通告。
【关于安全】:任何 IDC商家都有倒闭和跑路的可能,备份永远是最佳选择,服务器也是机器,不勤备份是对自己极不负责的表现,请保持良好的备份习惯。
香港110M(含10M CN2)大带宽独服限量促销,香港E3-8G-1T硬盘-3IP,月付仅799!

登录

找回密码

注册