Enlight RAM scaling

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Enlight RAM scaling

    Hi,

    I'm just starting out with Enlight and seem to have a problem. Support are telling me that everything is working fine, but I'm not sure.

    Basically, I have created one CentOS 6 Cpanel VM, configuring it to use a minimum on 0Mb RAM and a maximum of 2Gb.

    The VM seems to just sit there using a lot of RAM all the time. It started this morning using 1.5Gb, then this rose to 2Gb and it's sat there even since. the VM is not currently hosting any sites at all, and has not been used during this time.

    I have installed a Drupal site on the server yesterday and did a few page loads in the afternoon - That's the only use the server has had. The potential problem with this site (it's a pre-built "website in a box") is that the homepage causes PHP to use around 100Mb on page load. I thought that Enlight might be good for this, as although it requires quite a few resources, it's going to have only a maximum of a couple of hundred visitors a day, so thought that most of the time the server could just idle away using very few resources, scaling up when needed.

    Is this right that the box should sit there idling away using this much RAM all the time, even when it's not used? Support have told me this is correct.

    Any advice welcome!

    Thanks,

    Adam.

    #2
    Re: Enlight RAM scaling

    Hi Adam,

    idle time usage of the VM should be around 750Mb of RAM. we will need to get this checked from our eNlight Architects.

    Please let me know if I can ask them to login in your VM and check the resource usage. they will troubleshoot and post their response here.
    eUKhost - eNlight Cloud Hosting || eUKhost Knowledgebase
    Toll Free : 0808 262 0255 || Skype : mark_ducadi

    Comment


      #3
      Re: Enlight RAM scaling

      Originally posted by eUKhost.com View Post
      Hi Adam,

      idle time usage of the VM should be around 750Mb of RAM. we will need to get this checked from our eNlight Architects.

      Please let me know if I can ask them to login in your VM and check the resource usage. they will troubleshoot and post their response here.
      Hi,

      Sure, I'm happy for them to do this.

      One other thing, I actually disabled ClamAV yesterday on the server as it was using 300Mb RAM, so I guess the idle RAM usage should probably be even lower than your estimated 750Mb.

      Thanks,

      Adam.

      Comment


        #4
        Re: Enlight RAM scaling

        Hi Adam,

        Thank you for choosing eNlight Cloud for your varying server demands. eNlight Cloud should be a best fit for such dynamic environment.

        We have checked your server and found it to be taking a lot of cache.

        root@centos [~]# free -m
        total used free shared buffers cached
        Mem: 1972 1608 364 0 136 1081
        -/+ buffers/cache: 389 1582
        Swap: 511 0 511
        After emptying the cache it was on just

        root@centos [~]# free -m
        total used free shared buffers cached
        Mem: 1972 293 1679 0 0 19
        -/+ buffers/cache: 272 1699
        Swap: 511 0 511

        In eNlight, we have given two modes to run Virtual Machine, Economy Mode & Performance Mode. These modes can be changed or accessed via Virtual Machine properties.

        Performance Mode, considers your Cache as part of RAM and it will upscales the server if it finds that there is need of more RAM or Cache.

        Economy Mode, does not consider Cache as part of RAM and hence upscales server only if there is real need of RAM.

        I have changed the RAM mode of your server to Economy & it will be effective after reboot.

        Another way is to simply have a cron which will free up your cache at certain interval, lets say every hour. You can use below command to do it manually or use same command in cron.

        root@centos [~]# sync && echo 3 > /proc/sys/vm/drop_caches

        Let us know your doubts & we would be happy to assist.

        Regards,
        Rishi

        Comment


          #5
          Re: Enlight RAM scaling

          See my thread on using eNlight with low memory usage - you should be able to glean a fair bit. Minimum RAM would be better set at a more sensible figure of, say, 384Mb and ensure that the VM is set to Performance (rather than Economy) mode.

          Regarding ClamAV: Yes it's a PITA for memory leaks, that I've never discovered a cure for. 300Mb is much more than the usual circa 200Mb RAM usage though and it often uses less. A wee tip is to wait until services have settled for a few minutes after a reboot, then restart Exim (which restarts clamd). This often reduces memory consumption dramatically but not always.

          EJ

          [Rishi The Guru was typing at the same time and it's interesting to note that his take on Performance Mode conflicts with what was explained to me previously.] Check your Apache settings. I don't recommend periodic dropping of caches and prefer to restrict the propensity to swap instead.

          Comment


            #6
            Re: Enlight RAM scaling

            Thanks for both your responses, it's much appreciated.

            Now that the server is set to Economy mode, I've given it a reboot. After 10 minutes (irres[pective of whether it's a good idea or not) I cleared down the caches. Checking free -m a few minutes later, it shows:

            total used free shared buffers cached
            Mem: 1972 287 1684 0 18 44
            -/+ buffers/cache: 224 1747
            Swap: 511 0 511


            The server itself is now using 285Mb out of 2Gb. How long should I have to wait before the allocated RAM reduces down?

            I have understood how this works correctly haven't I? Because the server is reporting that it has 2Gb, that means I pay for 2Gb, irrespective of how much of the RAM is actually in use? That's what the graphs seem to indicate in the billing area.

            This is the main problem I seem to be having, it just seems to be sticky at 2Gb. My enlight control panel page shows the RAM is "2048/2048". Why so high?

            Adam.

            ps. Just saw the allocated RAM drop to 1.5Gb for a couple of seconds. Then it instantly went back up to 2Gb again.
            Last edited by derby_webteam; 30-05-2013, 13:41. Reason: addedd ps

            Comment


              #7
              Re: Enlight RAM scaling

              Hi Adam,

              The RAM scales down as soon as the need of it subsidise. RAM scale down operation happen in steps.

              Your current RAM status is 256/948 & you are being charged for the USED part and not allocated.
              eNlight is a true pay per consume, hence it allocates RAM in proportion to your USED RAM.


              You can take advantage of Min RAM if you need guaranteed minimum resources.


              Regards,
              Rishi

              Comment


                #8
                Re: Enlight RAM scaling

                Hi Adam,

                You will be billed only for the used RAM, which is 285Mb as per your previous response to this thread. the upper limit, which is 2GB and which came down to 1.5GB is the buffer limit for sudden scaling of the VM when required.
                eUKhost - eNlight Cloud Hosting || eUKhost Knowledgebase
                Toll Free : 0808 262 0255 || Skype : mark_ducadi

                Comment

                Working...
                X