2

Summary :

While making a $http call from angular to the backend(php file) for getting the requested data. In localhost(e.g. http://localhost) everything is working fine. Issue is generating when open a web page on hosted server(e.g. http://www.example.com). I am getting this error.

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, webmaster@xyz.com and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.

This is my .htaccess file :

<IfModule mod_rewrite.c>
    RewriteEngine On
    RewriteBase /s/public/
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteRule ^(.*) /s/public/#/$1 
</IfModule>

Tried So far :

  1. check error logs in cpanel.

    I already checked out the error log and get more information on what is causing the error. Here is an example video that i followed for cPanel logs.

    http://www.youtube.com/watch?v=pzO1UNHZjZo

    Server logs :

    enter image description here

I am not able to understand this error. There are lot of answers on SO but all are confusing.

memory_limit = 1024M, still, Cannot allocate memory: couldn't create child process: /opt/suphp/sbin/suphp

Why might this problem be occurring? Is there any misconfiguration with my server settings?

halfer
  • 19,824
  • 17
  • 99
  • 186
Debug Diva
  • 26,058
  • 13
  • 70
  • 123
  • Have you got a lot of traffic visiting the site? The answer you linked to suggests it's a shared hosting limitation. – Henders Jul 05 '16 at 12:16
  • 1
    @Henders, site not live yet, i am doing testing only and it is showing 500 error. – Debug Diva Jul 05 '16 at 12:25
  • How are you calling the backend? Remember that angularJs runs in your browser and not your server, are you calling it via the IP address? Is firewall and everything configured on the server that it's capable of receiving the call from the angular application? – Mavi Domates Jul 05 '16 at 12:37
  • @MaviDomates, using `$http` service i am calling the backend api.I am calling it via domain name – Debug Diva Jul 05 '16 at 13:08
  • And when you call the endpoint (I'm assuming it's a service) outside of the app referring by just the domain name, does it work? I'm trying to figure out if there's something related to the way that the app calls the service vs site being not served from the domain name – Mavi Domates Jul 05 '16 at 13:10
  • @MaviDomates, services also having same domain as application have. – Debug Diva Jul 05 '16 at 13:19
  • Please [edit] to paste the text used in the image into your question so that it can be read on all devices, quoted, edited, and found through search. As it stands now, [your image makes it hard to answer your question or for people with related issues to find your question](//meta.stackoverflow.com/questions/285551/why-not-upload-images-of-code-errors-when-asking-a-question). See the [formatting documentation](/editing-help) for tips to make your text appear nicely without resorting to images. – Stephen Ostermiller Oct 02 '22 at 01:21

0 Answers0