rsync backup-dir with files in read-only folders
Clash Royale CLAN TAG#URR8PPP
up vote
1
down vote
favorite
I am using rsync over ssh to backup directory structure. In that structure there is read-only folder with a few writable folders within. Content in these writable folders does change and needs to be backed up.
The main backup process works fine, but "backup of backup" (--backup --backup-dir
) fails for folders in read-only folder with:
rsync: mkdir failed - permission denied
This is rsync
command:
rsync -e "ssh -i some_key_file.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
--backup --backup-dir=backup_dir --force --ignore-errors --delete -a root_folder server:destination_folder/
This is folder structure:
root_folder
-- read_only_folder
---- writable_folder
Rsync fails creating backup_dir/read_only_folder/writable_folder
.
Because the main part of the backup does work (I assume rsync
adjusts permission after syncing files), I am thinking that I am just missing something that would apply the same to the --backup-dir
files.
linux permissions rsync
add a comment |Â
up vote
1
down vote
favorite
I am using rsync over ssh to backup directory structure. In that structure there is read-only folder with a few writable folders within. Content in these writable folders does change and needs to be backed up.
The main backup process works fine, but "backup of backup" (--backup --backup-dir
) fails for folders in read-only folder with:
rsync: mkdir failed - permission denied
This is rsync
command:
rsync -e "ssh -i some_key_file.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
--backup --backup-dir=backup_dir --force --ignore-errors --delete -a root_folder server:destination_folder/
This is folder structure:
root_folder
-- read_only_folder
---- writable_folder
Rsync fails creating backup_dir/read_only_folder/writable_folder
.
Because the main part of the backup does work (I assume rsync
adjusts permission after syncing files), I am thinking that I am just missing something that would apply the same to the --backup-dir
files.
linux permissions rsync
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22
add a comment |Â
up vote
1
down vote
favorite
up vote
1
down vote
favorite
I am using rsync over ssh to backup directory structure. In that structure there is read-only folder with a few writable folders within. Content in these writable folders does change and needs to be backed up.
The main backup process works fine, but "backup of backup" (--backup --backup-dir
) fails for folders in read-only folder with:
rsync: mkdir failed - permission denied
This is rsync
command:
rsync -e "ssh -i some_key_file.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
--backup --backup-dir=backup_dir --force --ignore-errors --delete -a root_folder server:destination_folder/
This is folder structure:
root_folder
-- read_only_folder
---- writable_folder
Rsync fails creating backup_dir/read_only_folder/writable_folder
.
Because the main part of the backup does work (I assume rsync
adjusts permission after syncing files), I am thinking that I am just missing something that would apply the same to the --backup-dir
files.
linux permissions rsync
I am using rsync over ssh to backup directory structure. In that structure there is read-only folder with a few writable folders within. Content in these writable folders does change and needs to be backed up.
The main backup process works fine, but "backup of backup" (--backup --backup-dir
) fails for folders in read-only folder with:
rsync: mkdir failed - permission denied
This is rsync
command:
rsync -e "ssh -i some_key_file.pub -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null"
--backup --backup-dir=backup_dir --force --ignore-errors --delete -a root_folder server:destination_folder/
This is folder structure:
root_folder
-- read_only_folder
---- writable_folder
Rsync fails creating backup_dir/read_only_folder/writable_folder
.
Because the main part of the backup does work (I assume rsync
adjusts permission after syncing files), I am thinking that I am just missing something that would apply the same to the --backup-dir
files.
linux permissions rsync
edited May 29 at 15:03
Yurij Goncharuk
2,2582521
2,2582521
asked May 29 at 14:35
Sasha
61
61
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22
add a comment |Â
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22
add a comment |Â
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
active
oldest
votes
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f446716%2frsync-backup-dir-with-files-in-read-only-folders%23new-answer', 'question_page');
);
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Sign up or log in
StackExchange.ready(function ()
StackExchange.helpers.onClickDraftSave('#login-link');
);
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
I could not find solution for this other than changing adding u+w to the source directory that was read-only and resetting it back with u-w when rsync completes.
â Sasha
May 29 at 19:22