IDT for greengrass v2 shows error Failed at 'Unable to cache expired credentials'

0

So after launching the IDT for greengrass v2 it shows:

========== Test Summary ==========
the Greengrass deployment is COMPLETED on the device after 180 seconds'
17:05:41.182 [] [cloudComponent] [idt-3ed646a1c6d65be8f45d] [ERROR] com.aws.greengrass.testing.launcher.reporting.StepTrackingReporting - Failed: 'As a developer, I can create a component in Cloud and deploy it on my device via thing group': Failed at 'the Greengrass deployment is COMPLETED on the device after 180 seconds'
[ERROR] [2023-03-27 17:05:46]: Test exited unsuccessfully error=exit status 1 executionId=cb788e4e-cc79-11ed-90c7-080027641c32 testCaseId=cloudcomponent
[INFO] [2023-03-27 17:05:46]: All tests finished. executionId=cb788e4e-cc79-11ed-90c7-080027641c32
[INFO] [2023-03-27 17:05:48]:

========== Test Summary ==========
Execution Time:         34m1s
Tests Completed:        7
Tests Passed:           5
Tests Failed:           2
Tests Skipped:          0
----------------------------------
Test Groups:
    component:                  FAILED
    lambdadeployment:           PASSED
    pretestvalidation:          PASSED
    coredependencies:           PASSED
    version:                    PASSED
    mqtt:                       FAILED
----------------------------------
Failed Tests:
    Group Name: mqtt
        Test Name: mqttpubsub
            Reason: Failed at 'the Greengrass deployment is COMPLETED on the device after 300 seconds'
    Group Name: component
        Test Name: cloudcomponent
            Reason: Failed at 'the Greengrass deployment is COMPLETED on the device after 180 seconds'
----------------------------------


the followings is a part of the greengrass-test-run.log

2023-Mar-27 16:41:04,362 [mqtt] [idt-38bef2d5ba95f1ee98d1] [ERROR] com.aws.greengrass.testing.launcher.reporting.StepTrackingReporting - Failed: 'Component publishes MQTT message to Iot core and retrieves it as well': Failed at 'the Greengrass deployment is COMPLETED on the device after 300 seconds'

in greengrass.log itshows (both mqtt and cloudcomponent) shows the same error

2023-03-27T16:36:27.716Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Unable to cache expired credentials which expired at 2023-03-27T09:35:49Z. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials}
2023-03-27T16:36:27.717Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Error in retrieving AwsCredentials from TES. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials, credentialData=TES responded with credentials that expired at 2023-03-27T09:35:49Z}
2023-03-27T16:37:11.346Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Unable to cache expired credentials which expired at 2023-03-27T09:36:33Z. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials}
2023-03-27T16:37:11.348Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Error in retrieving AwsCredentials from TES. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials, credentialData=TES responded with credentials that expired at 2023-03-27T09:36:33Z}
2023-03-27T16:37:42.877Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Unable to cache expired credentials which expired at 2023-03-27T09:37:05Z. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials}
2023-03-27T16:37:42.879Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Error in retrieving AwsCredentials from TES. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials, credentialData=TES responded with credentials that expired at 2023-03-27T09:37:05Z}
2023-03-27T16:38:35.889Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Unable to cache expired credentials which expired at 2023-03-27T09:37:58Z. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials}
2023-03-27T16:38:35.891Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Error in retrieving AwsCredentials from TES. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials, credentialData=TES responded with credentials that expired at 2023-03-27T09:37:58Z}

not sure why is this happening anyone know where can I get more info about this Error the log seems did not give any extra info about it

2 Answers
0
Accepted Answer

It seems like the rtc modify my device time causing error happened; after turning off the rtc and set the time before the credential expired fix the error log Not sure if there is a better solution to fix the error

loordb
answered a year ago
0

Hi loordb. The deployment is failing to complete within 180s. You can find more information about what's going on with the deployment in the core device logs. The file greengrass.log and component-name.log. IDT copies them to destinations outside the normal place (/greengrass/v2/logs): https://docs.aws.amazon.com/greengrass/v2/developerguide/idt-troubleshooting.html

profile pictureAWS
EXPERT
Greg_B
answered a year ago
  • thx for replying i will check for that

  • hey i found a specific error here why does it shows the credential expired but why ?2023-03-27T16:37:42.879Z [ERROR] (pool-2-thread-17) com.aws.greengrass.tes.CredentialRequestHandler: Error in retrieving AwsCredentials from TES. {iotCredentialsPath=/role-aliases/GreengrassV2TokenExchangeRoleAlias/credentials, credentialData=TES responded with credentials that expired at 2023-03-27T09:37:05Z}

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions