robin Posted April 4, 2012 Share Posted April 4, 2012 Restored a backup to a different mySQL server and updated all appropriate config options. All works great except api access. We are able to send emails, but right after get a 500 Internal Server error. Looking in the logs we see the message "Premature end of script headers: api.php" No error logs on the mySQL server, and everything is recorded properly etc. As stated all works fine except for the 500 error page. Any ideas?? 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted April 4, 2012 Share Posted April 4, 2012 Try reuploading the files. It sounds like the encoded files got botched by an FTP upload. This is why I always upload the WHMCS zip file, and then extract it directly on the server from the command line. 0 Quote Link to comment Share on other sites More sharing options...
robin Posted April 5, 2012 Author Share Posted April 5, 2012 (edited) Thanks for the note, but the files were not touched and now continue to work properly with the data back on the localhost. We were in the process of moving the install, and decided to move the data first. So the (local) data was backed up and restored to a different server. The configuration was updated to point to this new data location. We've since moved the data back to the local system, and the errors have gone away. So it has something to do with the other MySQL server or the moving of the data. Seems odd since the error is not a database one, but an api.php (as listed) one. There is no other error message on any of the systems. WHMCS works fine other than when it is making API calls. WHMCS: Version: 5.0.3 MySQL (local): 5.0.95-community (pc-linux-gnu) MySQL (other): 5.5.15 (Win32) Edited April 5, 2012 by robin added versions 0 Quote Link to comment Share on other sites More sharing options...
othellotech Posted April 6, 2012 Share Posted April 6, 2012 Have you locked the API access down by IP and not included the new/old server IP addresses in the list ? 0 Quote Link to comment Share on other sites More sharing options...
laszlof Posted April 6, 2012 Share Posted April 6, 2012 Have you locked the API access down by IP and not included the new/old server IP addresses in the list ? Seems strange that the "database server" would be affected by that. That should only come into play if they moved an external script that uses the API to another IP. I would check any custom code you have to make sure you arent hardcoding the database connection somewhere, and also turn on display_errors to see if its returning anything. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.