Pages

Tuesday 17 December 2013

How to fix /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory

This will happen only on 64 bit systems, the cause is the fact that 32 bit libraries are missing from the system, so you can easily fix this issue by installing the 32 bit libraries on your system. So if you encounter this error /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory this is how you can fix it:
On any RPM based distribution (CentOS/RedHat/Fedora/Suse/Mandriva):
yum -y install glibc.i686
 
On any DEB based distribution (Debian/Ubuntu/Mint/Crunchbang):
apt-get update
apt-get install ia32-libs

Tuesday 16 April 2013

Fork : Cannot allocate memory(VPS Server)

In a VPS server, this usually occurs when VPS is running out of resources especially RAM. By restarting the VPS you can fix the issue. But it would be a temporary fix and it will only allow you to login to the server, but cannot execute some of the commands.
Check for the failcnt value of privvmpages and kmemsize variables. Due to the increase in failcnt, you are receiving the error “fork:Cannot allocate memory”.  Please check /proc/user_beancounters on vps for checking the failcount.

$ cat /proc/user_beancounters
uid      resource         held        maxheld    barrier    limit    failcnt
privvmpages               33656     44989       96550       96550    106507

You can increase the limit by editing the following file in the main node.

$ /etc/sysconfig/vz-scripts/<ve-node>.conf

You can see the value as below
PRIVVMPAGES=”96550:96550″

Increase the value as you need and then restart the vps.
Another method to increase the limit is using command as follows:

$ vzctl set <ve_node> –privvmpages 12752512:12752512 –save

You will now be able to restart cpanel and it will be working fine.

Sunday 17 March 2013

How to fixed error bad ELF interpreter

I got the following error:
/usr/local/lsws/bin/lswsctrl: ./litespeed: /lib/ld-linux.so.2: bad ELF interpreter: No such file or directory
[ERROR] Failed to start litespeed!

While was fixed by typing
yum install ld-linux.so.2

Then after that installed type
/usr/local/lsws/bin/lswsctrl start