Closed Bug 1089629 Opened 12 years ago Closed 11 years ago

[tracker] sumocelery1.webapp.phx1 frequently shows high SWAP utilization

Categories

(Infrastructure & Operations Graveyard :: WebOps: Other, task)

x86
macOS
task
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: rwatson, Assigned: cliang)

References

Details

(Whiteboard: [kanban:https://webops.kanbanize.com/ctrl_board/2/79] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] )

This seems to be a regular occurrence. sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL: SWAP CRITICAL - 18% free (733 MB out of 4095 MB) The machine has very little free memory.
Whiteboard: [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
Assignee: server-ops-webops → cliang
Short form: Swap seemed to be staying at high utilization, restarted celery processes. Things look okay for right now. Going to try to circle back with the developers about adding an additional celery node (more resources + redundancy) and possibly monitoring celery via New Relic. Notes: * The celery processes all seemed to date from Oct. 26th. * No errors in /var/log/celeryd-kitsune-prod-supervisor.log * celery process log to /var/log/celeryd-kitsune-prod.log; this was empty * No clogs in the celery queue (empty): /data/www/support.mozilla.com/kitsune/virtualenv/bin/python /data/www/support.mozilla.com/kitsune/manage.py celeryctl inspect active
Had to bounce the celery processes again after a long series of high swap alerts. Any joy on further changes?
and again, it looked like it had been bounced yesterday, too: apache 10213 0.1 1.4 534860 175472 ? S Nov01 1:54 /data/www/support.mozilla.com/kitsune/virtualenv/bin/python /data/www/support.mozilla.com/kitsune/manage.py celeryd --loglevel=INFO -f /var/log/celeryd-kitsune-prod.log -c 96 -E
It's been increasing and alerting again today. sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL: SWAP CRITICAL - 8% free (318 MB out of 4095 MB) I've had to restart the celery process.
I have a meeting on Nov. 10th set up with the main dev for SUMO to discuss any technical barriers to adding another celery node and instrumenting their celery usage in New Relic so we can get some data about which tasks are causing clogs in the pipe.
Since we're getting paged and having to restart this every day is there something that can be done sooner than another week out? Automate the restart?
Tue 04:47:01 PST [1783] sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL: SWAP CRITICAL - 20% free (795 MB out of 4095 MB) As Peter mentioned, is there anything that can be done sooner?
Whiteboard: [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] → [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3027] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
Whiteboard: [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3027] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] → [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3032] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
Whiteboard: [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3032] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] → [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3036] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
Dropped swappiness to 20 and kicked celery-kitsune-prod
Whiteboard: [kanban:engops:https://mozilla.kanbanize.com/ctrl_board/6/3036] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] → [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
Chris Turra, Ricky Rosario, and I had a brief meeting on Monday, November 10th, to outline some ways of attacking this issue. Converting this bug to act as a kind of tracker.
Depends on: 1097112
Summary: sumocelery1.webapp.phx1 SWAP CRITICAL. → [tracker] sumocelery1.webapp.phx1 frequently shows high SWAP utilization
It looks like we have a lot of close_waits. I don't think cpu will fix this? I am seeing load as high as 100 or even 200. [root@sumocelery1.webapp.phx1 ~]# lsof -i TCP | grep CLOSE_WAIT | wc -l 96 [root@sumocelery1.webapp.phx1 ~]#
kicked for swap alert: sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL
kicked for swap critical.
kicked for swap critical
Whiteboard: [kanban:webops:https://kanbanize.com/ctrl_board/4/1741] → [kanban:https://webops.kanbanize.com/ctrl_board/2/79] [kanban:webops:https://kanbanize.com/ctrl_board/4/1741]
kicked for swap alert
sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL --recovered
I have reduced the number of celery workers from 96 to 80. I'm hesitant to go much further without input from the SUMO dev team. I suspect we could reduce it further, but I'm not really sure where the floor is.
Thu 05:23:05 PST [1262] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 49% free (1980 MB out of 4095 MB) (http://m.mozilla.org/Swap)
kicked... sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 48% free (1928 MB out of 4095 MB)
Kicked, WARNING: SWAP WARNING - 49% free (1983 MB out of 4095 MB) (http://m.mozilla.org/Swap)
kicked, sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING
kicked for swap alert, sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING
kicked for swap alert, 00:35 < nagios-phx1> Wed 00:35:38 PST [1402] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING
kicked. sumocelery1.webapp.phx1.mozilla.com:Swap is CRITICAL
kicked sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 46% free (1865 MB out of 4095 MB)
Kicked
Kicked again.
kicked
sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 50% free (2041 MB out of 4095 MB)
Kicked for good measure.
Fri 08:54:19 PST [1092] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 50% free (2035 MB out of 4095 MB) (http://m.mozilla.org/Swap) Kicked.
Sat 01:43:51 PST [1212] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 47% free (1905 MB out of 4095 MB) (http://m.mozilla.org/Swap)
<nagios-phx1:#sysadmins> Sun 02:20:35 PST [1364] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 50% free (2038 MB out of 4095 MB) (http://m.mozilla.org/Swap) Kicked again.
<nagios-phx1:#sysadmins> Mon 06:12:58 PST [1126] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 50% free (2042 MB out of 4095 MB) (http://m.mozilla.org/Swap) Kicked again. If it's this bad at leaking memory can we not have it automatically restarted every day if the problem isn't being dealt with?
another kick... sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 48%
kicked for swap alert
kicked.
Sun 00:42:58 PST [1866] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 49% free (1968 MB out of 4095 MB) Kicked.
Mon 00:43:07 PST [1083] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 40% free (1636 MB out of 4095 MB) Kicked.
Tue 00:33:02 PST [1179] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 47% free (1906 MB out of 4095 MB) Kicked.
Wed 00:29:12 PST [1278] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 45% free (1821 MB out of 4095 MB) (http://m.mozilla.org/Swap) Kicked.
Thu 01:14:06 PST [1393] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 45% free (1836 MB out of 4095 MB) Kicked yet again.
Fri 01:14:13 PST [1485] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 46% free (1878 MB out of 4095 MB) Kicked.
Sat 01:00:05 PST [1574] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 47% free kicked, again.
Sun 00:49:11 PST [1674] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 45% free (1806 MB out of 4095 MB) Kicked.
:jakem we're being alerted on and having to kick this basically every day now. That's adding up fast. Any progress on a fix for the issue?
Flags: needinfo?(nmaul)
Kicked...
kicked. 1:03 AM <nagios-phx1> Wed 01:03:23 PST [1029] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 44% free (1792 MB out of 4095 MB) (http://m.mozilla.org/Swap)
Flags: needinfo?(nmaul) → needinfo?(cliang)
<nagios-phx1:#sysadmins> Sun 03:41:32 PST [1655] sumocelery1.webapp.phx1.mozilla.com:Swap is WARNING: SWAP WARNING - 50% free (2047 MB out of 4095 MB) (http://m.mozilla.org/Swap) kicked.
Currently trying workarounds in bug 1136402. Should be working on bug 1097131 this week.
Flags: needinfo?(cliang)
Additional celery nodes went in on March 5th. I believe that there has *not* been a reboot of sumocelery1.webapp.phx1 since those new nodes went in. There is still some work to be done WRT rabbit but that is out of scope for this bug. =)
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Product: Infrastructure & Operations → Infrastructure & Operations Graveyard
You need to log in before you can comment on or make changes to this bug.