Code Monkey home page Code Monkey logo

Comments (4)

helloxz avatar helloxz commented on August 23, 2024 1

可以参考下这里的回复:https://www.hostloc.com/thread-650479-13-1.html

已解决
通过rclone上传到网盘(比如onedrive)的操作需要读取rclone的相关配置,由于是以ccaa用户运行的,它会先查找/home/ccaa/.rclone. config文件,但是一开始可能并没有建这个文件,甚至该文件夹都不存在,由于查不到该.config文件,rclone会用其default的config,但显然与用户自己设置的网盘信息是不同的,所以上传会失败。
用root权限直接使用rclone上传则没有问题,因为此时可以读到root用户下的config文件(位置是/root/.config/rclone/rclone.config),所以可以正常上传。
解决办法很简单,先把/root/.config/rclone/rclone.config拷贝到/home/ccaa/.rclone.config,然后给文件夹和文件改至ccaa用户组:chown -R ccaa:ccaa /home/ccaa/.rclone.config
chown -R ccaa:ccaa /home/ccaa/
以上文件夹需要如此操作的原因是rclone运行过程中还会在/home/ccaa文件夹中创建临时config文件,所以需要文件夹的权限。另外上传用的脚本也需要如此操作。

from ccaa.

NaclFire avatar NaclFire commented on August 23, 2024

同问这个问题,我也无法自动上传了

from ccaa.

helloxz avatar helloxz commented on August 23, 2024

新版本为了安全性考虑,使用的ccaa这个用户来运行服务。

from ccaa.

wuweiluohua avatar wuweiluohua commented on August 23, 2024

我参考了那个回复,还是失败了,我的rclone的配置文件应该是/root/.config/rclone/rclone.conf,/home/ccaa不存在,然后我进行了新建,将rclone.conf文件复制过去了,并更改了用户组,也将上传脚本的用户组进行了修改,依然无法调用rclone

from ccaa.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.