One of our client was trying to install Magneto on a new folder/subdomain of his website and getting the error:
[wpfmb type=’error’ theme=2]Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request[/wpfmb]
While checking on Apache error logs we found this:
SoftException in Application.cpp:357: UID of script "/home/username/public_html/index.php" is smaller than min_uid Premature end of script headers: index.php
This specific error occurs when the script is owned by a user (generally root) instead of the actual user.If you check out the list of files, you will see that the index.php file is owned by root where the others are owned by the cPanel user.
To fix the error, we need to change the ownership of the file to the cPanel username. We can do that by using the following command. Be sure to change the username to the proper cPanel username and index.php to the specific file you are going to change.
chown user:user index.php
After running the command, you can check the ownership of the files by running:
It should appear as below:
drwxr-x--- 4 user nobody 4.0K Aug 5 14:19 ./ drwx--x--x 11 user user 4.0K Aug 5 14:19 ../ drwxr-xr-x 2 user user 4.0K Aug 5 14:04 cgi-bin/ -rw-r--r-- 1 user user 0 Aug 5 14:05 .htaccess -rw-r--r-- 1 user user 3.0K Aug 5 2015 index.php -rw-r--r-- 1 user user 39K Aug 10 14:05 php.ini