- Más nuevo
- Más votos
- Más comentarios
Got the answer from tech support:
The rate-limiting errors were observed in “/var/log/messages” file.
... the rate-limiting signals were being sent by “journald” service.
Solved by configuring "rsyslog” and “journald” services through .ebextensions
(workaround solution provided by tech support):
files: /tmp/Test.txt: mode: "000644" owner: root group: root content: | $SystemLogRateLimitInterval 0 $SystemLogRateLimitBurst 0 $ImjournalRateLimitInterval 0 /tmp/script.sh: mode: "000755" owner: root group: root content: | #!/bin/bash #Fetching grep values for if condition to check whether the update has been performed or not. value=$(grep -f /tmp/Test.txt /etc/rsyslog.conf) value1=$(grep -w 'RateLimitInterval=0' /etc/systemd/journald.conf) value2=$(grep -w 'RateLimitBurst=0' /etc/systemd/journald.conf) # Updating /etc/rsyslog.conf file if [ ! -z "$value" ] then echo "Match Found" else echo "Modifying /etc/rsyslog.conf" echo -e '$SystemLogRateLimitInterval 0\n$SystemLogRateLimitBurst 0\n$ImjournalRateLimitInterval 0' >> /etc/rsyslog.conf fi # Updating /etc/systemd/journald.conf file if [ ! -z $value1 ] then echo "Match Found for RateLimitInterval" else echo "Adding RateLimitInterval=0 to /etc/systemd/journald.conf" echo -e "RateLimitInterval=0" >> /etc/systemd/journald.conf fi if [ ! -z $value2 ] then echo "Match Found for RateLimitBurst" else echo "Adding RateLimitBurst=0 to /etc/systemd/journald.conf" echo -e "RateLimitBurst=0" >> /etc/systemd/journald.conf fi commands: 01_run_script.sh: command: ./tmp/script.sh 02_restart_journald: command: systemctl restart systemd-journald 03_restart_rsyslog: command: systemctl restart rsyslog
Did you enable the streaming environment's logs to the CloudWath Logs ? You can do it using Console (for detailed steps how to achieve this please check [2]), using EB CLI [3] or using configuration files [4]. After completing these steps you should be able to see these CloudWatch LogGroups and the environment will start streaming appropriate logs into them.
[1] Enabling Elastic Beanstalk enhanced health reporting https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/health-enhanced-enable.html [2] Using Elastic Beanstalk with Amazon CloudWatch Logs https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/AWSHowTo.cloudwatchlogs.html [3] Instance log streaming using the Elastic Beanstalk console https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/AWSHowTo.cloudwatchlogs.html#AWSHowTo.cloudwatchlogs.streaming.console [4] Instance log streaming using the EB CLI https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/AWSHowTo.cloudwatchlogs.html#AWSHowTo.cloudwatchlogs.streaming.ebcli [5] Instance log streaming using configuration files https://docs.aws.amazon.com/elasticbeanstalk/latest/dg/AWSHowTo.cloudwatchlogs.html#AWSHowTo.cloudwatchlogs.files
Contenido relevante
- OFICIAL DE AWSActualizada hace 2 años
Yes I did, see the "AWS Beanstalk Environment Configuration" section of the question.
I see some logs of my application in the CW log group, the problem is that they are partial/incomplete, i.e. some log lines are missing.
I assume the problem is somewhere between application ->
/var/log/web.stdout.log
(within the EC2 instance) rather than between/var/log/web.stdout.log
-> CW.