AWS CLI is configured with multiple credentials, how does the CloudWatch Logs agent specify the credentials?

0

Multiple credentials are configured in the ~/.aws/credentials file, including us-east-1 and us-gov-West-1. The default is the credentials of us-east-1. I need to upload the logs to the gov area. For cloudwatch, how do you configure the configuration file awslogs.conf of the cloudwatch log agent? ​ It was normal to use the gov region's credentials by default before. Now the logs will not be uploaded after the default credentials are changed to us-east-1.

1개 답변
0
수락된 답변

From the query, I understand that you are using the awslogs agent (older logs agent that is deprecated).

You can specify the AWS access key ID, AWS secret access key, and Default Region name while installing the agent. The CloudWatch Logs agent installer will ask you to provide certain information during the setup. I would suggest you to reinstall the agent while providing the correct access key IDs and region information.

Please feel free to refer to the following documentation for more details:

[+] https://docs.aws.amazon.com/AmazonCloudWatch/latest/logs/QuickStartEC2Instance.html#running-ec2-step-2

Furthermore, I would also request you to please reach out to the AWS support team via Support console for any further concerns and we will investigate the same in detail. Hope the information provided above is helpful. Have a great day ahead.

AWS
지원 엔지니어
답변함 5달 전

로그인하지 않았습니다. 로그인해야 답변을 게시할 수 있습니다.

좋은 답변은 질문에 명확하게 답하고 건설적인 피드백을 제공하며 질문자의 전문적인 성장을 장려합니다.

질문 답변하기에 대한 가이드라인

관련 콘텐츠