Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

First of all, I'm very new to Linux but I don't think this is a "Linux ate my RAM" issue. While searching about my problem I ran in to that issue a lot but it doesn't fit with what I see. This seems to be really happening.

Everything I've tried is telling me that the RAM usage is very very high. I've tried top, htop, vmstat 2 10. My Hypanel admin page too (this is a VPS that I access remotely). Also I have started to get errors stating that it cannot allocate memory to whatever I'm trying to do, even opening a terminal. It didn't even have enough RAM to allow me to logout of Ubuntu at one point.

The VPS has 1gb of RAM. It's not a lot but from everything I have read it should be more than enough to run, particularly when I have basically no traffic going through it. I have setup Apache2 and added 2 domain names pointing to their own html folders. I can access the domains. For example: t4nk.com

I then installed some recommended things like modsecurity, fail2ban, MySQL, and tried to install PHP5 which didn't work (probably because it couldn't allocate memory), but this may be irrelevant because the RAM usage apparently started last month before I did much of anything, as you'll see in the screenshots below. The first shot is just the general info from Hypanel.

enter image description here

In the next screenshot you can see that the RAM usage spikes back up immediately after turning off the VPS for a few minutes:

enter image description here

And when I view the RAM usage from last month I can see that it all went bad after changing from CentOS 5 to Ubuntu 12.04. The reason that I changed to Ubuntu was that I thought it would be easier for a newbie like me to use, but honestly I haven't gained much from having a GUI and I spend most of my time in the terminal just like I did on CentOS.

Last month RAM usage:

enter image description here

top:

enter image description here

htop:

enter image description here

vmstat 2 10:

enter image description here

I don't really know what vmstat does, but it was recommended in one of the many threads I read on my many searches for a solution. I hope someone can help me out here. Please keep in mind that I'm very new to Linux.

How to resolve this ?

share|improve this question

1 Answer 1

up vote 4 down vote accepted

Your RAM usage looks totally normal, given the fact that you are running a GUI, Apache and mySQL on a box with only 1GB of RAM.

While the use for Apache and mySQL is rather obvious, installing complete desktop environments on a server – like Xfce on yours – is seldom useful and only wastes precious resources.

Ubuntu is as capable of being adminstrated from the command line as any other Linux distribution and I highly recommend you do so.

share|improve this answer
    
OK. Is it possible to uninstall the GUI without resetting the whole OS? I don't really need it. Thanks. BTW, the RAM usage started long before I installed MySQL, and it shouldn't be used for anything yet (no requests from vistors, because I don't have anything on the site yet). –  Trich Dec 18 '13 at 9:51
    
Yes, it is. From the looks of it, you are using either Xubuntu or Ubuntu with an added Xfce4. Uninstalling the packages xfce4 and xubuntu-desktop including their dependencies should get rid of the GUI. If not, please open a new question asking what exactly to uninstall. –  drc Dec 18 '13 at 9:57

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.