whm high memory usage in processes

Posted on 2016-11-07
Last Modified: 2016-11-09
Sometimes my site slows down and when I check the processes I see this high memory process. How can I identify the problem?
Thank you

Pid                           Owner      Priority             CPU %      Memory %
849 (Trace) (Kill)      tr1msite         19                     8.99               55.05      

/usr/local/cpanel/3rdparty/bin/analog +CIMAGEDIR /images/ +CDOMAINSFILE /usr/local/cpanel/3rdparty/share/analog/ +CCHARTDIR ./ +CALLCHART ON +CLANGFILE /usr/local/cpanel/3rdparty/share/analog/us.lng +COUTFILE /home/tr1msite/tmp/analog/ssl/ +CLOCALCHARTDIR /home/tr1msite/tmp/analog/ssl/ +CCACHEOUTFILE /home/tr1msite/tmp/analog/ssl/ +CCACHEFILE /home/tr1msite/tmp/analog/ssl/ +CVHOST ON +COSREP ON +CBROWSER ON +CFULLBROWSER ON +CREDIRREF ON +CREFSITE ON +CFAILREF ON +CLOGFORMAT COMBINED +CHOSTNAME +CHOSTURL /usr/local/apache/domlogs/
Question by:myyis
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
  • 2
LVL 16

Expert Comment

by:Shaik M. Sajid
ID: 41876983
logon to IIS (webserver)

on command prompt  type cd %windir%\system32\inetsrv   then enter

then type appcmd list wps

Author Comment

ID: 41876992
I have nothing with windows. Everything is linux and apache? Can you explain some more details?
Thank you
LVL 16

Expert Comment

by:Shaik M. Sajid
ID: 41877001
sorry man i thought it's windows environment...
Building an interactive eFuture classroom

Watch and learn how ATEN provided a total control system solution including seamless switching matrix switch, HDBaseT extenders, PDU, lighting control to build an interactive eFuture classroom.

LVL 110

Expert Comment

by:Ray Paseur
ID: 41877063
Who is your hosting company?

PHP has some memory-related settings and functions.  You may be able to use these to identify memory usage patterns.

If you're running a back-level version of PHP (Less than PHP 7) you may find that arrays and objects have very high memory requirements.  Unset() can release most of the memory that is consumed by large arrays.  Large arrays can result from SQL queries with SELECT *, or other similar activities that load large files, such as parsing large XML documents.

Author Comment

ID: 41877099
Hi Ray,
I have a dedicated server and I manage the whm panel.
The problem occurs once or twice a day, the memory goes up and returns back to normal in about 1 min.
I suspect  from some of the queries and php scripts but can not catch the exact part that increases the memory.
I use php 5, I may upgrade it but before that I would prefer to solve the problem before the upgrade since after the upgrade the symptoms may disappear even the problem keeps going on.
Thank you.
LVL 110

Accepted Solution

Ray Paseur earned 500 total points
ID: 41877164
Maybe something like this will help.  You can drop a one-line function call into the scripts where you suspect an issue.
<?php // demo/temp_myyis.php

function memory_log($tag = NULL)
    $log = ini_get('error_log');
    ini_set('error_log', 'memory_log');
    error_log($tag . ' ' . number_format( memory_get_usage() ) );
    ini_set('error_log', $log);

$foo = range(0,15);

$bar = range(0,32767);

echo file_get_contents('memory_log');

Open in new window

Outputs something like
[07-Nov-2016 08:28:39 America/Chicago] small 217,176
[07-Nov-2016 08:28:39 America/Chicago] large 4,936,400

Open in new window


Author Closing Comment

ID: 41878635
I will check thank you

Featured Post

On Demand Webinar - Networking for the Cloud Era

This webinar discusses:
-Common barriers companies experience when moving to the cloud
-How SD-WAN changes the way we look at networks
-Best practices customers should employ moving forward with cloud migration
-What happens behind the scenes of SteelConnect’s one-click button

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
PHP mail() function not working... 8 36
Google Dork query 7 69
Session time out quickly. 6 28
How do I Import CSV File In my PHP Application 29 21
Build an array called $myWeek which will hold the array elements Today, Yesterday and then builds up the rest of the week by the name of the day going back 1 week.   (CODE) (CODE) Then you just need to pass your date to the function. If i…
These days socially coordinated efforts have turned into a critical requirement for enterprises.
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
The viewer will learn how to create a basic form using some HTML5 and PHP for later processing. Set up your basic HTML file. Open your form tag and set the method and action attributes.: (CODE) Set up your first few inputs one for the name and …

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question