Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-38898

Managed artifacts fails to upload to S3 - no errors logged

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Critical Critical
    • s3-plugin
    • None
    • Jenkins version 1.625.18.3 (CloudBees Jenkins Enterprise 15.11)

      Our devops core team updated to version 0.10.10 of the S3 Plugin. Build jobs that used the "Manage artifacts" check box for the post-build Publish artifacts to S3 Bucket then failed to upload the artifacts. Not even the directories were created in S3.

      However, as old builds where discarded the old artifacts are removed from S3.

      No errors are given. It looks successful but it fails to upload.

      Output looks like this:
      Publish artifacts to S3 Bucket Build is still running
      Publish artifacts to S3 Bucket Using S3 profile: jenkins
      Publish artifacts to S3 Bucket bucket=ellucian-mobilecloud, file=mobilecloud.war region=us-east-1, will be uploaded from slave=false managed=true , server encryption false
      Archiving artifacts

      After reverting back to 0.8 version of the S3 plugin that we were using output looks like this:
      Publish artifacts to S3 Bucket Using S3 profile: jenkins
      Publish artifacts to S3 Bucket bucket=ellucian-mobilecloud, file=mobilecloud.war region=us-east-1, upload from slave=false managed=true , server encryption false
      Archiving artifacts

          [JENKINS-38898] Managed artifacts fails to upload to S3 - no errors logged

          Alexander A added a comment -

          How did you understand then it fails to upload? By checking S3 directly?

          It's very strange that S3 didn't write anything to log. Did you check Jenkins log as well?

          p.s. Can you provide s3 settings? (for this job and global one and don't forget to remove sensitive data )

          Alexander A added a comment - How did you understand then it fails to upload? By checking S3 directly? It's very strange that S3 didn't write anything to log. Did you check Jenkins log as well? p.s. Can you provide s3 settings? (for this job and global one and don't forget to remove sensitive data )

          Bret Hansen added a comment -

          the buildnumber folder doesn't get created in S3, is the outcome I found it because a later job that deploys to AWS fails because the artifacts are missing.

          Things that may be relevant but not sensitive include:

          job settings:
          Storage class - Standard
          Bucket Region - us-east-1
          No upload on build failure is checked
          Manage artifacts is checked
          no other options are checked

          Bret Hansen added a comment - the buildnumber folder doesn't get created in S3, is the outcome I found it because a later job that deploys to AWS fails because the artifacts are missing. Things that may be relevant but not sensitive include: job settings: Storage class - Standard Bucket Region - us-east-1 No upload on build failure is checked Manage artifacts is checked no other options are checked

          Alexander A added a comment - - edited

          Did you check jenkins log?

          Something is missing here. A lot of stuff was fixed (flatten directories, fingerprints, "keep structure" in global configuration) since 0.8.

          Alexander A added a comment - - edited Did you check jenkins log? Something is missing here. A lot of stuff was fixed (flatten directories, fingerprints, "keep structure" in global configuration) since 0.8.

          Thomy Moore added a comment -

          Same here:

          Jenkins 2.25 / S3-Plugin 0.10.10

          The publish process keeps running and does nothing:

          Publish artifacts to S3 Bucket Build is still running
          Publish artifacts to S3 Bucket Using S3 profile: jenkins@xxxxxxxxxx
          Publish artifacts to S3 Bucket bucket=xxxxxxxxx.s3-eu-central-1.amazonaws.com, file=xxxxxxxxx region=eu-central-1, will be uploaded from slave=false managed=false , server encryption false
          

          using the S3 profile creds from aws cli works just fine.

          Thomy Moore added a comment - Same here: Jenkins 2.25 / S3-Plugin 0.10.10 The publish process keeps running and does nothing: Publish artifacts to S3 Bucket Build is still running Publish artifacts to S3 Bucket Using S3 profile: jenkins@xxxxxxxxxx Publish artifacts to S3 Bucket bucket=xxxxxxxxx.s3-eu-central-1.amazonaws.com, file=xxxxxxxxx region=eu-central-1, will be uploaded from slave= false managed= false , server encryption false using the S3 profile creds from aws cli works just fine.

          Alexander A added a comment -

          Try to upload from slave, it's common setting in both failed cases.
          I will check how uploading from master differs from uploading from slave later.

          Alexander A added a comment - Try to upload from slave, it's common setting in both failed cases. I will check how uploading from master differs from uploading from slave later.

          Thomy Moore added a comment -

          I got it running. I reentered the aws s3 creds in the jenkins configuration, mysteriously they were empty.

          Thomy Moore added a comment - I got it running. I reentered the aws s3 creds in the jenkins configuration, mysteriously they were empty.

          Liora Milbaum added a comment - - edited

          I have a similar issue.
          Jenkins 2.36. S3 Plugin 0.10.11.
          Bucket Region is eu-west-1

          My slave is running on AWS with IAM profile which enables publishing to S3. So no credentials are required.
          When the manage artifacts is not checked, the artifact is uploaded successfully.
          When the manage artifacts is checked, the artifact is not uploaded at all and no error message is reported. But, when drilling down to the "Last Successful Deployed Artifacts"

          This XML file does not appear to have any style information associated with it. The document tree is shown below.
          <Error>
          <Code>AuthorizationQueryParametersError</Code>
          <Message>
          Error parsing the X-Amz-Credential parameter; the region 'us-east-1' is wrong; expecting 'eu-west-1'
          </Message>
          <Region>eu-west-1</Region>
          <RequestId>CFC02E45B5802788</RequestId>
          <HostId>
          MX0ahVKKzXrJWovhhgDpabz1hGrBi5LjKh+RkpW6liy/1vK/zMe9Is6ZfexoZJCp7xhLQ4HPmVg=
          </HostId>
          </Error>

          Build log:
          10:05:14 Publish artifacts to S3 Bucket Build is still running
          10:05:14 Publish artifacts to S3 Bucket Using S3 profile: Publish
          10:05:14 Publish artifacts to S3 Bucket bucket=sb-current-build/unstable, file=sparkbeyond-RC-5273.run region=eu-west-1, will be uploaded from slave=true managed=true , server encryption false

          Liora Milbaum added a comment - - edited I have a similar issue. Jenkins 2.36. S3 Plugin 0.10.11. Bucket Region is eu-west-1 My slave is running on AWS with IAM profile which enables publishing to S3. So no credentials are required. When the manage artifacts is not checked, the artifact is uploaded successfully. When the manage artifacts is checked, the artifact is not uploaded at all and no error message is reported. But, when drilling down to the "Last Successful Deployed Artifacts" This XML file does not appear to have any style information associated with it. The document tree is shown below. <Error> <Code>AuthorizationQueryParametersError</Code> <Message> Error parsing the X-Amz-Credential parameter; the region 'us-east-1' is wrong; expecting 'eu-west-1' </Message> <Region>eu-west-1</Region> <RequestId>CFC02E45B5802788</RequestId> <HostId> MX0ahVKKzXrJWovhhgDpabz1hGrBi5LjKh+RkpW6liy/1vK/zMe9Is6ZfexoZJCp7xhLQ4HPmVg= </HostId> </Error> Build log: 10:05:14 Publish artifacts to S3 Bucket Build is still running 10:05:14 Publish artifacts to S3 Bucket Using S3 profile: Publish 10:05:14 Publish artifacts to S3 Bucket bucket=sb-current-build/unstable, file=sparkbeyond-RC-5273.run region=eu-west-1, will be uploaded from slave=true managed=true , server encryption false

          Sjoerd van Gestel added a comment - - edited

          same issue here:
          Publish artifacts to S3 Bucket bucket=-***, file=app-debug.apk region=eu-west-1, will be uploaded from slave=true managed=true , server encryption false

          Error parsing the X-Amz-Credential parameter; the region 'us-east-1' is wrong; expecting 'eu-west-1'

          Sjoerd van Gestel added a comment - - edited same issue here: Publish artifacts to S3 Bucket bucket=-***, file=app-debug.apk region=eu-west-1, will be uploaded from slave=true managed=true , server encryption false Error parsing the X-Amz-Credential parameter; the region 'us-east-1' is wrong; expecting 'eu-west-1'

            jimilian Alexander A
            ellucianbret Bret Hansen
            Votes:
            1 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: