This is more of an reminder for myself when trying to install cPanel system on cheap, low memory system, just to test something out. On CentOS 7 cPanel requires at least 1024MB of RAM, while on CentOS 6 it requires 768MB of RAM. If you have less than that install will straight out fail.

I understand that this are recommended requirements, and that is not good idea to run anything serious on less memory than that. But what about spawning cPanel just for testing something out? Or running DNSOnly install for 2-3 domains? In such cases it is enough to have 512MB for normal day to day usage. Although, I would certainly recommend adding at least 1-2GB of swap in cases when system is upgrading etc.

Without further ado, to override cPanel memory limits you can follow first two steps of their guide, but in third step use:

sh latest-dnsonly --keep

So, when it fails it’ll leave its working directory there. After that change into that working directory and edit install file:

cd installd

vi install

locate

my $min_memory_rules = {
	default => 768,      # CentOS 5/6 => in a better world should be 512
	7       => 1_024,    # CentOS 7
};

And change values to the desired ones. After that’s done, run appropriate script. I want DNSOnly server so I’ll run:

sh bootstrap-dnsonly

Keep in mind that recommended requirements are there for a reason, and running a system with less memory than recommended means you’re left on your own when something breaks due to the memory constraints of the server ;-)