You have mentioned that when you touch .rclone.conf the file is correctly created. Who is the owner of .rclone.conf after it was created and what are the permissions?
Current user is the owner the file with following permissions -rw-r--r--. So nothing weird on this side.
But note that it is point less to create the file this way since rclone cannot open the file, and it stops before displaying the configuration options.
There were some config file handling fixes between 1.36 and 1.38. Is your home directory on a different file system to your /tmp directory by any chance?
I'm trying to use rclone on a Snap installation with Nextcloud (Ubuntu 18 on a remote VPS). I get the same "Failed to save config..." error.
I've installed rclone via Snap which seems quite old now (1.36) - where do you get 1.38 from? Also I tried installing it from the installation script here:
which installs v1.55 (I think) but the config wizard script has totally changed and fails trying to get the authorization token from Dropbox (with 1.36 you can paste the prompt URL into a browser but 1.55 URL is using a local URL (127.0.0.1) which doesn't work as I'm on a headerless remote VPS.
Just managed to get the config script to run by installing rclone with the --devmode option (--classic is ignored in Snap due to Snap's security protocol).
I'm now getting an error which seems to be to do with rclone using old (outdated) autorization API:
rclone ls remote:
(produces the error): "Failed to ls: couldn't list: v1_retired"