MATLAB: Do I receive a “/lib/libc.so.6: Permission denied” error when starting MATLAB on Linux

MATLAB

When starting MATLAB, I receive the following error:
/usr/local/bin/matlab: line 1: /lib/libc.so.6: Permission denied
MATLAB then starts up successfully.

Best Answer

When MATLAB starts, it runs /lib/libc.so.6 to obtain library information. If /lib/libc.so.6 does not have execute permissions, then you will receive a "Permission Denied" message at startup. To correct this, make sure that /lib/libc.so.6 has execute permissions. To check, run the following command in the /lib directory
ls -l
The libc.so.6 should have the following permissions:
lrwxrwxrwx
and the libc-2.2.5.so that it points to should have the following permissions:
-rwxr-xr-x
or
-rwxrwxrwx
If the libc-2.2.5.so does not have the correct permissions, run the following command as root:
chmod 755 libc.so.6