Portal Home > Knowledgebase > Articles Database > Why PHP was errors when runs on Dedicated Server?


Why PHP was errors when runs on Dedicated Server?




Posted by bbcrew, 03-08-2014, 04:50 AM
Why PHP was errors when runs on Dedicated Server? Normally, I using a script that was PHP function and it works with Hostgator reseller plan as well. No any errors display. However, I move from them to Dedicate Server at RouterHosting.com. I using a same script but when I try to install script that working with Hostgator (cPanel) but errors at RouterHosting (DirectAdmin). It seems Dedicate Server can't using php function likes writeFile and any.

Posted by DewlanceHosting, 03-08-2014, 05:28 AM
What is error message?

Posted by Tom_WebhostingUK LTD, 03-08-2014, 05:39 AM
You might need to do some settings. Can you please help with error message you are getting?

Posted by bbcrew, 03-08-2014, 05:50 AM
It's error as don't know a value of r and step like: if($_GET['r'] == 'remove') if($_POST['step'] != 2 && $_POST['step'] != 3) and else if($_POST['step'] == 3){ And if I disable error notification a script will go to blank page not generate new files. But with Hostgator I never found any problems with a script.

Posted by fabin, 03-08-2014, 06:00 AM
These scripts should work in any servers running php. Get the help of a php developer to see what is missing in php. If you have the phpinfo pages from both servers, you can compare the php settings.

Posted by bbcrew, 03-08-2014, 06:33 AM
Yes, I upload phpinfo to both servers and see difference in PHP Version, Server API, etc.

Posted by fabin, 03-08-2014, 07:30 AM
May be any php modules are missing? Try vardump or print_r on GET array and see the values in them.

Posted by bbcrew, 03-08-2014, 07:44 AM
I see errors as these after click install. I don't know how to fix it because I haven't knowledge in programming.

Posted by fabin, 03-08-2014, 07:53 AM
There is a config.php file in you webroot for which php doesn't have write permission. What is the ownership and mode of that file at present?

Posted by bbcrew, 03-08-2014, 08:06 AM
As I said with previously Hostgator reseller. After submit a script will create config.php to webroot automatically. But with Dedicate Server at RouterHosting it hasn't any files generated after click submit or install. So I feel surprised with Dedicate Server that it hasn't possibility to create files (I choose Linux OS and PHP was installed).

Posted by fabin, 03-08-2014, 08:35 AM
I guess the web folder is having incorrect ownership or mode. Their support should be able to fix it.

Posted by steven99, 03-08-2014, 06:15 PM
PHP is either running as mod_php and the file doesn't have write permissions for world or that file is not owned by the user that php is ran as. Under phpinfo output, what does it say for "Server API"? If it says apache handler, then that's mod_php and you need to change to fastcgi php or php-fpm. Have you contacted the host support about this?

Posted by Hannan, 03-08-2014, 08:20 PM
He is contacted us, as our servers are unmanaged, we offered them to reload the server if it has required to be done. or contact the software developer.

Posted by prashant1979, 03-09-2014, 06:36 AM
The issue is not that you have switched to a Dedicated server, but that you don't know how to resolve the issue. Hire a good Linux System Administrator or better a server management company who will be able to help you manage the server and fix this issue as well.



Was this answer helpful?

Add to Favourites Add to Favourites    Print this Article Print this Article

Also Read
Server Select (Views: 765)
php vs. python (Views: 780)
MyQoS License wanted (Views: 863)


Language:

LoadingRetrieving latest tweet...

Back to Top Copyright © 2018 DC International LLC. - All Rights Reserved.