Elgg Memory Spikes and Heavy memory

I am using elgg-1.8.19 . My URL : https://safalaya.com . I have recently upgraded to vps server as recommended by my web host . I have seen the following problems :

I could see that the server previously had a lot of memory spikes and heavy memory:

12:00:11 AM runq-sz plist-sz ldavg-1 ldavg-5 ldavg-15
12:10:18 AM 1 511 89.22 117.11 72.70
12:20:03 AM 0 425 1.11 19.76 41.73
12:30:10 AM 0 620 3.33 5.15 23.06
12:41:34 AM 1 672 233.93 157.00 83.27
12:50:34 AM 0 832 324.50 278.97 176.76
04:20:10 AM 0 871 324.70 344.60 364.31
04:53:52 AM 1 985 466.75 420.21 371.63
05:08:29 AM 0 973 445.49 454.68 426.89
07:12:07 AM 0 981 434.29 435.86 436.90
07:25:13 AM 0 967 422.16 429.81 433.46
07:50:52 AM 1 859 373.50 378.03 398.58
08:00:09 AM 2 244 3.32 91.61 249.16
08:10:01 AM 1 234 1.93 14.47 132.84
08:20:01 AM 3 234 0.84 2.66 69.98
08:30:01 AM 4 235 1.09 2.43 37.92
08:40:01 AM 2 266 6.39 4.30 21.62
08:50:03 AM 1 283 4.86 4.03 12.94
09:00:09 AM 0 334 6.90 6.82 10.02
09:10:04 AM 0 580 5.12 5.10 7.51
09:20:03 AM 0 684 4.91 8.93 10.01
09:30:41 AM 0 764 157.65 131.15 76.01
09:40:07 AM 0 728 173.81 162.32 116.38

12:00:11 AM kbmemfree kbmemused %memused kbbuffers kbcached kbcommit %commit
12:10:18 AM 69016 1458648 95.48 1768 24788 3648032 78.06
12:20:03 AM 65068 1462596 95.74 10208 392160 2866136 61.33
12:30:10 AM 77292 1450372 94.94 1424 33792 5233708 111.99
12:41:34 AM 51228 1476436 96.65 2960 27928 6919940 148.07
12:50:34 AM 67472 1460192 95.58 2000 27084 8230556 176.12
04:20:10 AM 51588 1476076 96.62 5328 101868 7613492 162.91
04:53:52 AM 51208 1476456 96.65 1304 23756 8516296 182.23
05:08:29 AM 51168 1476496 96.65 2704 26540 9471504 202.67
07:12:07 AM 51416 1476248 96.63 2340 21816 10558124 225.92
07:25:13 AM 51200 1476464 96.65 1672 22424 10778816 230.64
07:50:52 AM 51308 1476356 96.64 4324 25616 7702016 164.81
08:00:09 AM 92464 1435200 93.95 20576 1075824 784672 16.79

root@serv1049 [~]# free -m
total used free shared buffers cached
Mem: 1491 1320 170 0 22 565
-/+ buffers/cache: 733 758
Swap: 3071 214 2857

Due to this the scripts on the site were timing out which can be verified below:

[Fri Apr 13 21:10:38 2018] [error] [client 23.94.20.214] Script timed out before returning headers: index.php, referer: http://safalaya.com/
[Fri Apr 13 21:10:44 2018] [error] [client 103.204.166.206] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/
[Fri Apr 13 21:10:47 2018] [error] [client 80.252.171.72] Script timed out before returning headers: page_handler.php
[Fri Apr 13 21:10:47 2018] [error] [client 80.252.171.68] Script timed out before returning headers: page_handler.php
[Fri Apr 13 21:10:59 2018] [error] [client 163.172.27.213] Script timed out before returning headers: page_handler.php
[Fri Apr 13 21:11:03 2018] [error] [client 213.58.202.70] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com
[Fri Apr 13 21:11:15 2018] [error] [client 139.196.48.232] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/
[Fri Apr 13 21:11:15 2018] [error] [client 95.110.224.30] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/
[Fri Apr 13 21:11:18 2018] [error] [client 66.249.64.29] Script timed out before returning headers: page_handler.php
[Fri Apr 13 21:11:21 2018] [error] [client 192.169.140.100] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/
[Fri Apr 13 21:11:24 2018] [error] [client 192.169.136.80] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/
[Fri Apr 13 21:11:25 2018] [error] [client 95.110.224.30] Script timed out before returning headers: page_handler.php, referer: http://safalaya.com/

The load was being used by the user nsikdar and would suggest you to optimize the sites for the user on the server to avoid any further issues:

PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
45793 nsikdar 20 0 280m 18m 8820 S 4.0 1.2 0:00.12 php

How could I solve this problem ? Please reply urgently .