Link to home
Start Free TrialLog in
Avatar of Yashy
YashyFlag for United Kingdom of Great Britain and Northern Ireland

asked on

Error log shows on Linux server shows: Caught SIGTERM, shutting down. Any ideas what that means?

hi guys,

So I posted this week about how our EC2 Linux instance with Amazon suddenly became inaccessible on port 80 (SSH worked fine) and that things only worked once we restarted the httpd service. This happened around 4 to 5 times over the duration of two days.  

Thanks to EE people, I got help and  looked in the right places. Having trawled through some error logs in the /etc/httpd/logs I opened a log called 'error_log' with the date/timestamp of that time.

One thing I can see is that at exactly the time this issue occurred, this line was in the log:

Caught SIGTERM, shutting down


Does this mean the Apache service was shutdown for some reason? If so, then is there a way of finding out what caused it?

Thanks
Yashy
Avatar of arnold
arnold
Flag of United States of America image

A SIGTERM is a notice to terminate.

As to who or what issued the signal is a more difficult thing to track down.
This can be a result of a monitoring service that detected that the process exceeded a set threshold. If this was a consequence of a monitoring system, the app should have been restarted shortly there after.  It is possible that the detection process has a 5 or longer gap between, terminate and start.
You know when the signal was issued. In the environment you are it is more difficult to say.  
Checking whether something else was going on I.e. Updates being applied, admin on system performing a task...

Adding logging events to the service scripts to revord when anyone starts/stops/restarts services ..... Will have some answers going forward.

Apache/openssl patch and the admin issued a stop instead of restart in error.
Avatar of Yashy

ASKER

Thank you Arnold for the info. I appreciate it.

That last line 'Apache/openssl patch and the admin issued a stop instead of restart in error', was it an example of what you think it is? Or that it is something which we should add the logging script?
ASKER CERTIFIED SOLUTION
Avatar of arnold
arnold
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial