[GH-ISSUE #798] SIGINT/SIGTERM received...killing workers... #559

Closed
opened 2026-02-25 23:42:52 +03:00 by kerem · 2 comments
Owner

Originally created by @papanito on GitHub (Feb 28, 2023).
Original GitHub issue: https://github.com/healthchecks/healthchecks/issues/798

I try to run healtchecks in kubernetes, so I created a helm chart. After the container started it is shutdown after some seconds

sendalerts is now running
sendreports is now running
Starting SMTP listener on 0.0.0.0:25 ...
SIGINT/SIGTERM received...killing workers...

Not sure though why I get a SIGINT/SIGTERM. Below the full log

[uWSGI] getting INI configuration from /opt/healthchecks/docker/uwsgi.ini
*** Starting uWSGI 2.0.21 (64bit) on [Tue Feb 28 10:02:00 2023] ***
compiled with version: 10.2.1 20210110 on 26 January 2023 07:27:23
os: Linux-3.10.0-1160.83.1.el7.x86_64 #1 SMP Wed Jan 25 16:41:43 UTC 2023
nodename: healthchecks-5cfc45cbfd-2dzt2
machine: x86_64
clock source: unix
detected number of CPU cores: 8
current working directory: /opt/healthchecks
detected binary path: /usr/local/bin/uwsgi
!!! no internal routing support, rebuild with pcre support !!!
uWSGI running as root, you can use --uid/--gid/--chroot options
*** WARNING: you are running uWSGI as root !!! (use the --uid flag) ***
chdir() to /opt/healthchecks
your memory page size is 4096 bytes
detected max file descriptor number: 10000
lock engine: pthread robust mutexes
thunder lock: enabled
uwsgi socket 0 bound to TCP address :8000 fd 3
uWSGI running as root, you can use --uid/--gid/--chroot options
*** WARNING: you are running uWSGI as root !!! (use the --uid flag) ***
Python version: 3.10.9 (main, Jan 23 2023, 22:43:18) [GCC 10.2.1 20210110]
Python main interpreter initialized at 0x55d2d21df6e0
uWSGI running as root, you can use --uid/--gid/--chroot options
*** WARNING: you are running uWSGI as root !!! (use the --uid flag) ***
python threads support enabled
your server socket listen backlog is limited to 100 connections
your mercy for graceful operations on workers is 60 seconds
mapped 405560 bytes (396 KB) for 4 cores
*** Operational MODE: preforking ***
running "exec:./manage.py migrate" (pre app)...
Operations to perform:
Apply all migrations: accounts, admin, api, auth, contenttypes, payments, sessions
Running migrations:
Applying contenttypes.0001_initial... OK
Applying auth.0001_initial... OK
Applying accounts.0001_initial... OK
Applying accounts.0002_profile_ping_log_limit... OK
Applying accounts.0003_profile_token... OK
Applying accounts.0004_profile_api_key... OK
Applying accounts.0005_auto_20160509_0801... OK
Applying accounts.0006_profile_current_team... OK
Applying accounts.0007_profile_check_limit... OK
Applying accounts.0008_profile_bill_to... OK
Applying accounts.0009_auto_20170714_1734... OK
Applying accounts.0010_profile_team_limit... OK
Applying accounts.0011_profile_sort... OK
Applying accounts.0012_auto_20171014_1002... OK
Applying accounts.0013_remove_profile_team_access_allowed... OK
Applying accounts.0014_auto_20171227_1530... OK
Applying accounts.0015_auto_20181029_1858... OK
Applying accounts.0016_remove_profile_bill_to... OK
Applying accounts.0017_auto_20190112_1426... OK
Applying accounts.0018_auto_20190112_1426... OK
Applying accounts.0019_project_badge_key... OK
Applying accounts.0020_auto_20190112_1950... OK
Applying accounts.0021_auto_20190112_2005... OK
Applying accounts.0022_auto_20190114_0857... OK
Applying accounts.0023_auto_20190117_1419... OK
Applying accounts.0024_auto_20190119_1540... OK
Applying accounts.0025_remove_member_team... OK
Applying accounts.0026_auto_20190204_2042... OK
Applying accounts.0027_profile_deletion_notice_date... OK
Applying accounts.0028_auto_20191119_1346... OK
Applying accounts.0029_remove_profile_current_project... OK
Applying accounts.0030_member_transfer_request_date... OK
Applying accounts.0031_auto_20200803_1413... OK
Applying accounts.0032_auto_20200819_0757... OK
Applying accounts.0033_member_rw... OK
Applying accounts.0034_credential... OK
Applying accounts.0035_profile_reports... OK
Applying accounts.0036_fill_profile_reports... OK
Applying accounts.0037_profile_tz... OK
Applying accounts.0038_profile_theme... OK
Applying accounts.0039_remove_profile_reports_allowed... OK
Applying accounts.0040_auto_20210722_1244... OK
Applying accounts.0041_fill_role... OK
Applying accounts.0042_remove_member_rw... OK
Applying accounts.0043_add_role_manager... OK
Applying accounts.0044_auto_20210730_0942... OK
Applying accounts.0045_auto_20210908_1257... OK
Applying admin.0001_initial... OK
Applying admin.0002_logentry_remove_auto_add... OK
Applying admin.0003_logentry_add_action_flag_choices... OK
Applying api.0001_initial... OK
Applying api.0002_auto_20150616_0732... OK
Applying api.0003_auto_20150616_1249... OK
Applying api.0004_auto_20150616_1319... OK
Applying api.0005_auto_20150630_2021... OK
Applying api.0006_check_grace... OK
Applying api.0007_ping... OK
Applying api.0008_auto_20150801_1213... OK
Applying api.0009_auto_20150801_1250... OK
Applying api.0010_channel... OK
Applying api.0011_notification... OK
Applying api.0012_auto_20150930_1922... OK
Applying api.0013_auto_20151001_2029... OK
Applying api.0014_auto_20151019_2039... OK
Applying api.0015_auto_20151022_1008... OK
Applying api.0016_auto_20151030_1107... OK
Applying api.0017_auto_20151117_1032... OK
Applying api.0018_remove_ping_body... OK
Applying api.0019_check_tags... OK
Applying api.0020_check_n_pings... OK
Applying api.0021_ping_n... OK
Applying api.0022_auto_20160130_2042... OK
Applying api.0023_auto_20160131_1919... OK
Applying api.0024_auto_20160203_2227... OK
Applying api.0025_auto_20160216_1214... OK
Applying api.0026_auto_20160415_1824... OK
Applying api.0027_auto_20161213_1059... OK
Applying api.0028_auto_20170305_1907... OK
Applying api.0029_auto_20170507_1251... OK
Applying api.0030_check_last_ping_body... OK
Applying api.0031_auto_20170509_1320... OK
Applying api.0032_auto_20170608_1158... OK
Applying api.0033_auto_20170714_1715... OK
Applying api.0034_auto_20171227_1530... OK
Applying api.0035_auto_20171229_2008... OK
Applying api.0036_auto_20180116_2243... OK
Applying api.0037_auto_20180127_1215... OK
Applying api.0038_auto_20180318_1306... OK
Applying api.0039_remove_check_last_ping_body... OK
Applying api.0040_auto_20180517_1336... OK
Applying api.0041_check_desc... OK
Applying api.0042_auto_20181029_1522... OK
Applying api.0043_channel_name... OK
Applying api.0044_auto_20181120_2004... OK
Applying api.0045_flip... OK
Applying api.0046_auto_20181218_1245... OK
Applying api.0047_auto_20181225_2315... OK
Applying api.0048_auto_20190102_0737... OK
Applying api.0049_auto_20190102_0743... OK
Applying api.0050_ping_kind... OK
Applying api.0051_auto_20190104_0908... OK
Applying api.0052_auto_20190104_1122... OK
Applying api.0053_check_subject... OK
Applying api.0054_auto_20190112_1427... OK
Applying api.0055_auto_20190112_1427... OK
Applying api.0056_auto_20190114_0857... OK
Applying api.0057_auto_20190118_1319... OK
Applying api.0058_auto_20190312_1716... OK
Applying api.0059_auto_20190314_1744... OK
Applying api.0060_tokenbucket... OK
Applying api.0061_webhook_values... OK
Applying api.0062_auto_20190720_1350... OK
Applying api.0063_auto_20190903_0901... OK
Applying api.0064_auto_20191119_1346... OK
Applying api.0065_auto_20191127_1240... OK
Applying api.0066_channel_last_error... OK
Applying api.0067_last_error_values... OK
Applying api.0068_auto_20200117_1023... OK
Applying api.0069_auto_20200117_1227... OK
Applying api.0070_auto_20200411_1310... OK
Applying api.0071_check_manual_resume... OK
Applying api.0072_auto_20200701_1007... OK
Applying api.0073_auto_20200721_1000... OK
Applying api.0074_auto_20200803_1411... OK
Applying api.0075_auto_20200805_1004... OK
Applying api.0076_auto_20201128_0951... OK
Applying api.0077_auto_20210506_0755... OK
Applying api.0078_sms_values... OK
Applying api.0079_auto_20210907_0918... OK
Applying api.0080_fill_slug... OK
Applying api.0081_channel_last_notify... OK
Applying api.0082_fill_last_notify... OK
Applying api.0083_channel_disabled... OK
Applying api.0084_ping_body_raw... OK
Applying api.0085_ping_object_size... OK
Applying api.0086_remove_check_last_ping_was_fail_and_more... OK
Applying api.0087_check_failure_kw_check_filter_body_and_more... OK
Applying api.0088_fill_kw... OK
Applying api.0089_remove_check_subject_remove_check_subject_fail... OK
Applying api.0090_alter_check_filter_subject... OK
Applying api.0091_alter_check_filter_body... OK
Applying api.0092_alter_check_success_kw... OK
Applying api.0093_alter_check_failure_kw... OK
Applying api.0094_ping_rid_alter_channel_kind... OK
Applying api.0095_check_last_start_rid... OK
Applying api.0096_check_start_kw_alter_channel_kind... OK
Applying contenttypes.0002_remove_content_type_name... OK
Applying auth.0002_alter_permission_name_max_length... OK
Applying auth.0003_alter_user_email_max_length... OK
Applying auth.0004_alter_user_username_opts... OK
Applying auth.0005_alter_user_last_login_null... OK
Applying auth.0006_require_contenttypes_0002... OK
Applying auth.0007_alter_validators_add_error_messages... OK
Applying auth.0008_alter_user_username_max_length... OK
Applying auth.0009_alter_user_last_name_max_length... OK
Applying auth.0010_alter_group_name_max_length... OK
Applying auth.0011_update_proxy_permissions... OK
Applying auth.0012_alter_user_first_name_max_length... OK
Applying payments.0001_initial... OK
Applying payments.0002_subscription_plan_id... OK
Applying payments.0003_subscription_address_id... OK
Applying payments.0004_subscription_send_invoices... OK
Applying payments.0005_subscription_plan_name... OK
Applying payments.0006_subscription_invoice_email... OK
Applying sessions.0001_initial... OK
WSGI app 0 (mountpoint='') ready in 1 seconds on interpreter 0x55d2d21df6e0 pid: 1 (default app)
uWSGI running as root, you can use --uid/--gid/--chroot options
*** WARNING: you are running uWSGI as root !!! (use the --uid flag) ***
*** uWSGI is running in multiple interpreter mode ***
spawned uWSGI master process (pid: 1)
spawned uWSGI worker 1 (pid: 9, cores: 1)
spawned uWSGI worker 2 (pid: 10, cores: 1)
spawned uWSGI worker 3 (pid: 11, cores: 1)
spawned uWSGI worker 4 (pid: 12, cores: 1)
[uwsgi-daemons] spawning "./manage.py sendalerts" (uid: 0 gid: 0)
[uwsgi-daemons] spawning "./manage.py smtpd" (uid: 0 gid: 0)
[uwsgi-daemons] spawning "./manage.py sendreports --loop" (uid: 0 gid: 0)
sendalerts is now running
sendreports is now running
Starting SMTP listener on 0.0.0.0:25 ...
SIGINT/SIGTERM received...killing workers...
[uwsgi-daemons] stopping daemon (pid: 13): ./manage.py sendalerts
Terminated, finishing...
[uwsgi-daemons] stopping daemon (pid: 14): ./manage.py sendreports --loop
Terminated, finishing...
Sent 0 alert(s). 
Originally created by @papanito on GitHub (Feb 28, 2023). Original GitHub issue: https://github.com/healthchecks/healthchecks/issues/798 I try to run healtchecks in kubernetes, so I created a [helm chart](https://github.com/papanito/healthchecks-helm). After the container started it is shutdown after some seconds ``` sendalerts is now running sendreports is now running Starting SMTP listener on 0.0.0.0:25 ... SIGINT/SIGTERM received...killing workers... ``` Not sure though why I get a `SIGINT/SIGTERM`. Below the full log ``` [uWSGI] getting INI configuration from /opt/healthchecks/docker/uwsgi.ini *** Starting uWSGI 2.0.21 (64bit) on [Tue Feb 28 10:02:00 2023] *** compiled with version: 10.2.1 20210110 on 26 January 2023 07:27:23 os: Linux-3.10.0-1160.83.1.el7.x86_64 #1 SMP Wed Jan 25 16:41:43 UTC 2023 nodename: healthchecks-5cfc45cbfd-2dzt2 machine: x86_64 clock source: unix detected number of CPU cores: 8 current working directory: /opt/healthchecks detected binary path: /usr/local/bin/uwsgi !!! no internal routing support, rebuild with pcre support !!! uWSGI running as root, you can use --uid/--gid/--chroot options *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** chdir() to /opt/healthchecks your memory page size is 4096 bytes detected max file descriptor number: 10000 lock engine: pthread robust mutexes thunder lock: enabled uwsgi socket 0 bound to TCP address :8000 fd 3 uWSGI running as root, you can use --uid/--gid/--chroot options *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** Python version: 3.10.9 (main, Jan 23 2023, 22:43:18) [GCC 10.2.1 20210110] Python main interpreter initialized at 0x55d2d21df6e0 uWSGI running as root, you can use --uid/--gid/--chroot options *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** python threads support enabled your server socket listen backlog is limited to 100 connections your mercy for graceful operations on workers is 60 seconds mapped 405560 bytes (396 KB) for 4 cores *** Operational MODE: preforking *** running "exec:./manage.py migrate" (pre app)... Operations to perform: Apply all migrations: accounts, admin, api, auth, contenttypes, payments, sessions Running migrations: Applying contenttypes.0001_initial... OK Applying auth.0001_initial... OK Applying accounts.0001_initial... OK Applying accounts.0002_profile_ping_log_limit... OK Applying accounts.0003_profile_token... OK Applying accounts.0004_profile_api_key... OK Applying accounts.0005_auto_20160509_0801... OK Applying accounts.0006_profile_current_team... OK Applying accounts.0007_profile_check_limit... OK Applying accounts.0008_profile_bill_to... OK Applying accounts.0009_auto_20170714_1734... OK Applying accounts.0010_profile_team_limit... OK Applying accounts.0011_profile_sort... OK Applying accounts.0012_auto_20171014_1002... OK Applying accounts.0013_remove_profile_team_access_allowed... OK Applying accounts.0014_auto_20171227_1530... OK Applying accounts.0015_auto_20181029_1858... OK Applying accounts.0016_remove_profile_bill_to... OK Applying accounts.0017_auto_20190112_1426... OK Applying accounts.0018_auto_20190112_1426... OK Applying accounts.0019_project_badge_key... OK Applying accounts.0020_auto_20190112_1950... OK Applying accounts.0021_auto_20190112_2005... OK Applying accounts.0022_auto_20190114_0857... OK Applying accounts.0023_auto_20190117_1419... OK Applying accounts.0024_auto_20190119_1540... OK Applying accounts.0025_remove_member_team... OK Applying accounts.0026_auto_20190204_2042... OK Applying accounts.0027_profile_deletion_notice_date... OK Applying accounts.0028_auto_20191119_1346... OK Applying accounts.0029_remove_profile_current_project... OK Applying accounts.0030_member_transfer_request_date... OK Applying accounts.0031_auto_20200803_1413... OK Applying accounts.0032_auto_20200819_0757... OK Applying accounts.0033_member_rw... OK Applying accounts.0034_credential... OK Applying accounts.0035_profile_reports... OK Applying accounts.0036_fill_profile_reports... OK Applying accounts.0037_profile_tz... OK Applying accounts.0038_profile_theme... OK Applying accounts.0039_remove_profile_reports_allowed... OK Applying accounts.0040_auto_20210722_1244... OK Applying accounts.0041_fill_role... OK Applying accounts.0042_remove_member_rw... OK Applying accounts.0043_add_role_manager... OK Applying accounts.0044_auto_20210730_0942... OK Applying accounts.0045_auto_20210908_1257... OK Applying admin.0001_initial... OK Applying admin.0002_logentry_remove_auto_add... OK Applying admin.0003_logentry_add_action_flag_choices... OK Applying api.0001_initial... OK Applying api.0002_auto_20150616_0732... OK Applying api.0003_auto_20150616_1249... OK Applying api.0004_auto_20150616_1319... OK Applying api.0005_auto_20150630_2021... OK Applying api.0006_check_grace... OK Applying api.0007_ping... OK Applying api.0008_auto_20150801_1213... OK Applying api.0009_auto_20150801_1250... OK Applying api.0010_channel... OK Applying api.0011_notification... OK Applying api.0012_auto_20150930_1922... OK Applying api.0013_auto_20151001_2029... OK Applying api.0014_auto_20151019_2039... OK Applying api.0015_auto_20151022_1008... OK Applying api.0016_auto_20151030_1107... OK Applying api.0017_auto_20151117_1032... OK Applying api.0018_remove_ping_body... OK Applying api.0019_check_tags... OK Applying api.0020_check_n_pings... OK Applying api.0021_ping_n... OK Applying api.0022_auto_20160130_2042... OK Applying api.0023_auto_20160131_1919... OK Applying api.0024_auto_20160203_2227... OK Applying api.0025_auto_20160216_1214... OK Applying api.0026_auto_20160415_1824... OK Applying api.0027_auto_20161213_1059... OK Applying api.0028_auto_20170305_1907... OK Applying api.0029_auto_20170507_1251... OK Applying api.0030_check_last_ping_body... OK Applying api.0031_auto_20170509_1320... OK Applying api.0032_auto_20170608_1158... OK Applying api.0033_auto_20170714_1715... OK Applying api.0034_auto_20171227_1530... OK Applying api.0035_auto_20171229_2008... OK Applying api.0036_auto_20180116_2243... OK Applying api.0037_auto_20180127_1215... OK Applying api.0038_auto_20180318_1306... OK Applying api.0039_remove_check_last_ping_body... OK Applying api.0040_auto_20180517_1336... OK Applying api.0041_check_desc... OK Applying api.0042_auto_20181029_1522... OK Applying api.0043_channel_name... OK Applying api.0044_auto_20181120_2004... OK Applying api.0045_flip... OK Applying api.0046_auto_20181218_1245... OK Applying api.0047_auto_20181225_2315... OK Applying api.0048_auto_20190102_0737... OK Applying api.0049_auto_20190102_0743... OK Applying api.0050_ping_kind... OK Applying api.0051_auto_20190104_0908... OK Applying api.0052_auto_20190104_1122... OK Applying api.0053_check_subject... OK Applying api.0054_auto_20190112_1427... OK Applying api.0055_auto_20190112_1427... OK Applying api.0056_auto_20190114_0857... OK Applying api.0057_auto_20190118_1319... OK Applying api.0058_auto_20190312_1716... OK Applying api.0059_auto_20190314_1744... OK Applying api.0060_tokenbucket... OK Applying api.0061_webhook_values... OK Applying api.0062_auto_20190720_1350... OK Applying api.0063_auto_20190903_0901... OK Applying api.0064_auto_20191119_1346... OK Applying api.0065_auto_20191127_1240... OK Applying api.0066_channel_last_error... OK Applying api.0067_last_error_values... OK Applying api.0068_auto_20200117_1023... OK Applying api.0069_auto_20200117_1227... OK Applying api.0070_auto_20200411_1310... OK Applying api.0071_check_manual_resume... OK Applying api.0072_auto_20200701_1007... OK Applying api.0073_auto_20200721_1000... OK Applying api.0074_auto_20200803_1411... OK Applying api.0075_auto_20200805_1004... OK Applying api.0076_auto_20201128_0951... OK Applying api.0077_auto_20210506_0755... OK Applying api.0078_sms_values... OK Applying api.0079_auto_20210907_0918... OK Applying api.0080_fill_slug... OK Applying api.0081_channel_last_notify... OK Applying api.0082_fill_last_notify... OK Applying api.0083_channel_disabled... OK Applying api.0084_ping_body_raw... OK Applying api.0085_ping_object_size... OK Applying api.0086_remove_check_last_ping_was_fail_and_more... OK Applying api.0087_check_failure_kw_check_filter_body_and_more... OK Applying api.0088_fill_kw... OK Applying api.0089_remove_check_subject_remove_check_subject_fail... OK Applying api.0090_alter_check_filter_subject... OK Applying api.0091_alter_check_filter_body... OK Applying api.0092_alter_check_success_kw... OK Applying api.0093_alter_check_failure_kw... OK Applying api.0094_ping_rid_alter_channel_kind... OK Applying api.0095_check_last_start_rid... OK Applying api.0096_check_start_kw_alter_channel_kind... OK Applying contenttypes.0002_remove_content_type_name... OK Applying auth.0002_alter_permission_name_max_length... OK Applying auth.0003_alter_user_email_max_length... OK Applying auth.0004_alter_user_username_opts... OK Applying auth.0005_alter_user_last_login_null... OK Applying auth.0006_require_contenttypes_0002... OK Applying auth.0007_alter_validators_add_error_messages... OK Applying auth.0008_alter_user_username_max_length... OK Applying auth.0009_alter_user_last_name_max_length... OK Applying auth.0010_alter_group_name_max_length... OK Applying auth.0011_update_proxy_permissions... OK Applying auth.0012_alter_user_first_name_max_length... OK Applying payments.0001_initial... OK Applying payments.0002_subscription_plan_id... OK Applying payments.0003_subscription_address_id... OK Applying payments.0004_subscription_send_invoices... OK Applying payments.0005_subscription_plan_name... OK Applying payments.0006_subscription_invoice_email... OK Applying sessions.0001_initial... OK WSGI app 0 (mountpoint='') ready in 1 seconds on interpreter 0x55d2d21df6e0 pid: 1 (default app) uWSGI running as root, you can use --uid/--gid/--chroot options *** WARNING: you are running uWSGI as root !!! (use the --uid flag) *** *** uWSGI is running in multiple interpreter mode *** spawned uWSGI master process (pid: 1) spawned uWSGI worker 1 (pid: 9, cores: 1) spawned uWSGI worker 2 (pid: 10, cores: 1) spawned uWSGI worker 3 (pid: 11, cores: 1) spawned uWSGI worker 4 (pid: 12, cores: 1) [uwsgi-daemons] spawning "./manage.py sendalerts" (uid: 0 gid: 0) [uwsgi-daemons] spawning "./manage.py smtpd" (uid: 0 gid: 0) [uwsgi-daemons] spawning "./manage.py sendreports --loop" (uid: 0 gid: 0) sendalerts is now running sendreports is now running Starting SMTP listener on 0.0.0.0:25 ... SIGINT/SIGTERM received...killing workers... [uwsgi-daemons] stopping daemon (pid: 13): ./manage.py sendalerts Terminated, finishing... [uwsgi-daemons] stopping daemon (pid: 14): ./manage.py sendreports --loop Terminated, finishing... Sent 0 alert(s). ```
kerem closed this issue 2026-02-25 23:42:52 +03:00
Author
Owner

@cuu508 commented on GitHub (Mar 6, 2023):

You need to figure who is sending SIGINT/SIGTERM and why.

<!-- gh-comment-id:1455736748 --> @cuu508 commented on GitHub (Mar 6, 2023): You need to figure who is sending SIGINT/SIGTERM and why.
Author
Owner

@tk512 commented on GitHub (Mar 10, 2023):

OOM (out of memory killer in Linux) may send SIGTERM. Is this possibly a memory starved VM? You might want to just add more memory and see.

<!-- gh-comment-id:1463754450 --> @tk512 commented on GitHub (Mar 10, 2023): OOM (out of memory killer in Linux) may send SIGTERM. Is this possibly a memory starved VM? You might want to just add more memory and see.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/healthchecks#559
No description provided.