#1
  1. No Profile Picture
    Registered User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Jul 2013
    Posts
    1
    Rep Power
    0

    MYSQL Memory Usage


    Hey guys,
    I am running a MySQL server, and i noticed that 80% of the server memory (8GB Total) is being used by mysqld processes.

    Here is an image of the HTOP

    http :// tinypic.com/view.php?pic=r1lvyu&s=5

    by the way, mysql> SHOW PROCESSLIST; displays only 4 users on "Sleep" command.

    What can be the issue?

    Thanks.
  2. #2
  3. No Profile Picture
    Problem Solver
    Devshed Specialist (4000 - 4499 posts)

    Join Date
    Jan 2001
    Location
    Stockholm, Sweden
    Posts
    4,495
    Rep Power
    534
    Probably no issue.
    The server is just waiting for the next time it is going to be "harassed" with a load of heavy queries.

    It all depends on the server configuration.
    In the configuration you specify how much RAM you allow MySQL to use for index/data cache and how many threads that it should be kept in cache for future use. In fact if you have a dedicated SQL server you very often let it use about 80% of the RAM on the machine and this is not something that is returned just because it doesn't have something to do just now. Because the database server can't know if it in about 1 ms might get hit with 1000 heavy queries. So it will keep all data it's allowed to have in memory to be able to answer the upcoming queries as fast as possible.
    /Stefan

IMN logo majestic logo threadwatch logo seochat tools logo