Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

s3: sync/cp: regular filesystem ACL are not preserved #1585

Closed
drzraf opened this issue Oct 22, 2015 · 10 comments
Closed

s3: sync/cp: regular filesystem ACL are not preserved #1585

drzraf opened this issue Oct 22, 2015 · 10 comments
Labels
closed-for-staleness feature-request A feature should be added or improved. s3sync s3

Comments

@drzraf
Copy link

drzraf commented Oct 22, 2015

POSIX ACL (Access Control Lists) are not preserved during cp/sync operation.
I guess other filesystem extended attributes are not either.

$ getfacl file.txt

user::rw-
user:www-data:rw-
group::r--
mask::rw-
other::r--

$ aws s3 cp file.txt s3://bucket/
$ aws s3 cp s3://bucket/file.txt file.2.txt
$ getfacl file.2.txt

user::rw-
group::r--
mask::rw-
other::r--

The ACL about www-data was not preserved.

@mtdowling
Copy link
Member

I'll mark this as a feature request, but this might be something that we decide not to add support for.

@kyleknap
Copy link
Contributor

Adding on the request of having a general purpose "additional file metadata/attributes" feature from this issue #1833

@frekele
Copy link

frekele commented Apr 24, 2016

+1
example in s3cmd Config.py and FileList.py:

    preserve_attrs = True
    preserve_attrs_list = [
        'uname',    # Verbose owner Name (e.g. 'root')
        'uid',      # Numeric user ID (e.g. 0)
        'gname',    # Group name (e.g. 'users')
        'gid',      # Numeric group ID (e.g. 100)
        'atime',    # Last access timestamp
        'mtime',    # Modification timestamp
        'ctime',    # Creation timestamp
        'mode',     # File mode (e.g. rwxr-xr-x = 755)
        'md5',      # File MD5 (if known)
        #'acl',     # Full ACL (not yet supported)
    ]

@mike503
Copy link

mike503 commented Apr 14, 2017

+1 please add in at least basic mode support. if going through the effort, probably makes sense to just do all extended attributes. but I just had to evaluate and wound up using s3cmd instead of aws s3 sync (which is way faster!) because it supports the basic attributes I want (mainly executability / modes, but everything would be good to have...)

s3cmd is a lot slower, possibly because of extra work due to this? or maybe it just isn't as well done from the multithreading. either way, please consider. I didn't realize or think about this at first and have a variety of servers doing aws s3 sync, and recovery on some wouldn't be very fun if permissions that were important to retain were lost. luckily most of my stuff is just web files, but some do have scripts that need to be executable, and I wouldn't know exactly since I won't have a record of that if the system is lost!

@ASayre
Copy link
Contributor

ASayre commented Feb 6, 2018

Good Morning!

We're closing this issue here on GitHub, as part of our migration to UserVoice for feature requests involving the AWS CLI.

This will let us get the most important features to you, by making it easier to search for and show support for the features you care the most about, without diluting the conversation with bug reports.

As a quick UserVoice primer (if not already familiar): after an idea is posted, people can vote on the ideas, and the product team will be responding directly to the most popular suggestions.

We’ve imported existing feature requests from GitHub - Search for this issue there!

And don't worry, this issue will still exist on GitHub for posterity's sake. As it’s a text-only import of the original post into UserVoice, we’ll still be keeping in mind the comments and discussion that already exist here on the GitHub issue.

GitHub will remain the channel for reporting bugs.

Once again, this issue can now be found by searching for the title on: https://aws.uservoice.com/forums/598381-aws-command-line-interface

-The AWS SDKs & Tools Team

@ASayre ASayre closed this as completed Feb 6, 2018
@salmanwaheed
Copy link

salmanwaheed commented Feb 6, 2018 via email

@salmanwaheed
Copy link

salmanwaheed commented Feb 6, 2018 via email

@jamesls jamesls reopened this Apr 6, 2018
@jamesls
Copy link
Member

jamesls commented Apr 6, 2018

Based on community feedback, we have decided to return feature requests to GitHub issues.

@aaronjensen
Copy link

For anyone else coming here, I was able to use this to copy one bucket to another and keep ACLs: https://github.com/cobbzilla/s3s3mirror/tree/2.1-stable

It's also significantly faster.

@github-actions
Copy link

Greetings! It looks like this issue hasn’t been active in longer than one year. We encourage you to check if this is still an issue in the latest release. Because it has been longer than one year since the last update on this, and in the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment to prevent automatic closure, or if the issue is already closed, please feel free to reopen it.

@github-actions github-actions bot added closing-soon This issue will automatically close in 4 days unless further comments are made. closed-for-staleness and removed closing-soon This issue will automatically close in 4 days unless further comments are made. labels Sep 18, 2020
thoward-godaddy pushed a commit to thoward-godaddy/aws-cli that referenced this issue Feb 12, 2022
* fix: managed stack

- always catch ClientError and BotoCoreError
- on windows, create temporary files with delete=False, otherwise it
  results in a PermissionDeniedError

* fix: dont mask inbuilt `file`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
closed-for-staleness feature-request A feature should be added or improved. s3sync s3
Projects
None yet
Development

No branches or pull requests

9 participants