Lots of files appearing in my Amazon S3 bucket - amazon-web-services

Objects and files names in my S3 bucket changed from my selected names to those displayed in the screenshot below.. And now when I update a file, it uploads successfully but doesn't change, the date modified is not changed neither are the changes in the codes are visible on the web page. Can someone please help me find out what happens to this bucket and how can I fix it?

The files you are showing are created by Amazon S3 bucket logging, which creates log files of access requests to Amazon S3.
Logging is activated within the Properties panel of your bucket, where you can nominate a target bucket and prefix for the logs.
So, your files are not being renamed. Rather, they are additional log files that are generated by Amazon S3.
If they are in the same location as your files, things will get confusing! Your files are still in there, but probably later in the naming scheme.
I would recommend:
Go into the bucket's properties
If you do not need the logs, then disable bucket logging
If you wish to keep the logs, configure them to write to a different bucket, or the same bucket but with a prefix (directory)
Delete or move the existing log files so that you will be left with just your non-log files

Related

Objects Not Visible Within S3 Bucket for GroundTruth Labeling Job

I am currently creating a GroundTruth Labeling job, and am following the tutorial
https://www.youtube.com/watch?v=_FPI6KjDlCI&t=210s
I have created the same bucket ground-truth-example-labeling-job and uploaded jpg files within the bucket. Within this tutorial, under Select S3 bucket or resource, they were able to go within the S3 Bucket and access the jpg files inside.
However, I am able to go inside the ground-truth-example-labeling-job bucket, but no jpg files are visible for me to select. The entire bucket is empty with nothing to select.
Is this a permissions settings problem?
You cannot select the files.
But if you have a folder within a bucket then you can select that folder which consists of the input data.
In the video they selected the bucket but not the files.

Upload the same name to Amazon S3 but keep the same permission

Just my thinking. Some of us may work on several files and frequently upload the same file with the same name onto Amazon S3. By default, the permission will be reset. Assuming that I don't use Versioning.
And I have a need to keep the same permission for any uploaded file which has the same name file existed on current Amazon S3.
I know it may not a good idea but technically how we can realize it?
Thanks
It is not possible to upload an object and request that the existing ACL settings be kept on the new object.
Instead, you should specify the ACL when the object is uploaded.

Different permissions same S3 bucket, parquet files

Problem
I have multiple files in the same S3 bucket. When I try to load one file into Snowflake, I get a "access denied" error. When I try a different file (in the same bucket), I can successfully load into Snowflake.
The file highlighted does not load into Snowflake.
This is the error
Using a different file but in the same bucket, I can successfully load into Snowflake.
Known Difference: The file that does not work was generated by AWS. The file that can be loaded into Snowflake was generated by AWS, saved to my local then reuploaded to the bucket.
The only difference is I brought it down to my local machine.
Question: Is there a known file permission on parquet files? Why does this behavior go away when I download and upload to the same bucket.
It cannot be an S3 bucket issue. It has to be some encoding on the parquet file.
Question: Is there a known file permission on parquet files? Why does
this behavior go away when I download and upload to the same bucket.
It cannot be an S3 bucket issue. It has to be some encoding on the
parquet file.
You are making some bad assumptions here. Each S3 object can have separate ACL (permission) values. You need to check what the ACL settings are by drilling down to view the details of each of those objects in S3. My guess is AWS is writing the objects to S3 with a private ACL, and when you re-uploaded one of them to the bucket you saved it with a public ACL.
Turns out I needed to add KMS permissions to the user accessing the file.

Files in s3 bucket are automatically moving to tombstone folder

I have created an S3 bucket, not sure what am I missing with IAM lifecycle policies.
Files in s3 bucket are automatically moving to tombstone folder after few days. how to stop this?
I have enabled only "Server access logging" in properties tab. And there are no life cycle rules are attached.
You can enable Amazon S3 Server Access Logging. following these instructions
Server access logging provides detailed records for the requests that are made to a bucket. Server access logs are useful for many applications. For example, access log information can be useful in security and access audits.

AWS S3 bucket versioning at the bucket level or directory level instead of object level

Is there a way to restore an AWS S3 bucket or directory inside a bucket to its previous version.
Scenario where i find this useful is
upload a website, containing multiple directories and multiple files
inside those directories into a aws s3 bucket with versioning and
website hosting enabled.
make code changes, upload latest code into
the bucket
if the build is bad, need to revert the s3 bucket to its old state quickly.
selecting 50+ files, for deletion, inside multiple directories that are marked as older versions is tedious and highly impossible.
In general it's bad idea to not have continuous integration in front of deployment website content to bucket. Having any test runner which check your build before it's uploaded to S3 is much better approach.
Anyway I have a solution for you. Please upload to S3 content of your website packed as ZIP/TAR archive. If build would fail, you can grab previous version of the archive, and unpack it into the bucket.