Pass credentials to windows share

Is there a way to connect to a shared folder on a remote windows PC that only has local accounts using rclone?
I can't see how to pass credentials to a windows share with rclone.

Windows shares work fine for PCs on our domain. There are just a few that cannot be connected for various reasons.

I have tried the following:
"C:\rclone\rclone.exe" --config "C:\rcloneconfig\rclone.conf" copy --dry-run --update --verbose \10.0.0.150\Users remote:thisbucket

I get the following output:
2019/09/17 10:48:52 ERROR : : error reading source directory: directory not found
2019/09/17 10:48:52 INFO : S3 bucket thisBucket: Waiting for checks to finish
2019/09/17 10:48:52 INFO : S3 bucket thisBucket: Waiting for transfers to finish
2019/09/17 10:48:52 ERROR : Attempt 1/1 failed with 1 errors and: directory not found
2019/09/17 10:48:52 Failed to copy: directory not found

Rclone doesn't have a way of doing this at the moment. You can use net use I think to open the share first.

rclone will run with the same access-level as the user who started it.

You can probably work around this fairly easily by just setting up a local account that has the needed access and spawn the clone process from that account. For scheduled tasks and the like you can just choose the account to run the process under in task scheduler.

i noticed that your share has only one backslash,

windows network shares need TWO back slashes.
\10.0.0.150\Users should be \\10.0.0.150\Users
that might be the reason you get an error about the source directory not found.
or perhaps you make a mistake on your forum post.
in a forum post, if you want to type a double back slash, you need to type 4 back slashes.

here is a code snippet you can use:

net use \\10.0.0.150\Users /user:username password

"C:\rclone\rclone.exe" --config "C:\rcloneconfig\rclone.conf" copy --dry-run --update --verbose \\10.0.0.150\Users remote:thisbucket

net use \\10.0.0.150\Users /delete /y

Thanks everyone. I am currently mapping the drive beforehand, I was just hoping for a native rclone way to do it. I have wrapped rclone in a powershell script and if all commands were native to rclone, i would only have to check return codes and errors for one program.

The missing backslash is just a forum display issue.

glad that you worked it out.

i have a wiki that enables VSS with rclone.
check it out and let me know if you have any questions, i want to help!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.