500 using CodeIgniter

I just moved the CodeIgniter project to a new server, and now I get a 500 error and do not output from the project. It works fine on my old server and in my test environment. I absolutely do not understand how to fix this problem, especially if nothing is used in the log files. Any help would be great!

+4
source share
5 answers

Well, that’s awkward. I was missing php-mysql. CodeIgniter did not register the fact that he could not find it, nothing appeared in / var / log / messages. Installed it and suddenly, it works. Thank you all for your answers.

+14
source

I get this problem on my real server with SuPHP. To avoid this, all PHP files must have 0644 permissions and 0755 directories.

To do this without a headache, do one of the following:

  • Get an FTP client that will be downloaded using the permissions that you specify
  • Find a PHP script that will change permissions based on filtering criteria after loading
  • Get access to your host shell!
+2
source

Some ideas for you:

  • Are you sure there is nothing in the log files? Have you checked both the web server log files and the system logs (EG: / var / log / messages)? Have you checked all the logs included in php.ini?

  • Double check the CI configuration settings. Perhaps you are pointing to the wrong database?

  • You have confirmed that the underlying PHP script <?phpinfo(); ?> <?phpinfo(); ?> ? This would isolate the problem with CI.

+1
source

Most likely, you did not specify the base url for the new location, you can install it from the file:

 /system/config/config.php 

in line:

 $config['base_url'] = 'your new url here'; 
0
source

Try downloading a new CodeIgniter project and trying to download a test environment? it works?

From my experiment, a 500 error is usually caused by a web server problem. But from what you said, you did not have .htaccess. Better just try downloading a clean CI project and see if your web server is OK or not.

0
source

Source: https://habr.com/ru/post/1311015/


All Articles