1

I have an error in my Drupal 7 site when I try to install any module.

If I try the Install from a URL I get:

HTTP error 0 occurred when trying to fetch http://ftp.drupal.org/files/projects/google_analytics-7.x-1.3.tar.gz.

Unable to retrieve Drupal project from http://ftp.drupal.org/files/projects/google_analytics-7.x-1.3.tar.gz.

If I try Upload a module or theme archive to install I get:

An AJAX HTTP request terminated abnormally. Debugging information follows. Path: StatusText: ResponseText: ReadyState: 4

The error page shows me:

Notice: Undefined index: log in update_authorize_install_batch_finished() (line 235 of V:\www\site\modules\update\update.authorize.inc).
Warning: Invalid argument supplied for foreach() in update_authorize_install_batch_finished() (line 235 of V:\www\site\modules\update\update.authorize.inc).
Notice: Undefined index: log in update_authorize_install_batch_finished() (line 276 of V:\www\site\modules\update\update.authorize.inc).
Notice: Undefined index: tasks in update_authorize_install_batch_finished() (line 277 of V:\www\site\modules\update\update.authorize.inc).
Installation failed! See the log below for more information.

Any ideas on how I can troubleshoot this?

  • Can your drupal website check for updates (admin/reports/updates)? – Pawel G Feb 21 '13 at 16:53
  • Can you uninstall Update manager module? – Aboodred1 Feb 21 '13 at 16:57
  • Can your drupal website check for updates (admin/reports/updates) -> Core and modules all have "Failed to get available update data" message. Running "Check manually" gives error message of "Failed to get available update data for 533 projects". So no, checking for updates is not working. – John81 Feb 22 '13 at 18:27
  • Can you uninstall Update manager module? -> Sure I can Disable it. What is that suppose to accomplish? – John81 Feb 22 '13 at 18:35
4

This looks like a ownership / permissions problem on a Linux server. Make sure to set the ownership of the drupal root folder and underlying files to the webserver's user (like 'apache', for example).

Also, make sure that the "temporary" and the "private" folders are setup correctly and with the right permissions (if in doubt, just test with 777 - don't forget to lower them to your requirements afterwards).

2

There can be another issue at play, as well--the version of PHP you're running on your server.

I have a few test sites running in a local dev environment, and when I updated one from 7.39 to 7.42, all appeared OK, until I attempted to download module updates via the GUI where I was hit with HTTP error 0. Checked file path, OK. Ran update.php and cleared caches, still the same issue. Granted, I could run updates via Drush, just not the GUI.

On a hunch, though, I changed the version of PHP from 5.6.7 to 5.5.23, and the issue was resolved.

0

I have been having the same issue since moving my site from a hosted platform to an internal iis8 server2012 machine. I fixed the issue by installing and switching to the latest revision of PHP5.6 with wincache in Web Platform installer. There is not much info out there for us windows guys so I hope this helps someone else too.

0
  • Install CA certificates (should be sufficient)
# apt-get install ca-certificates

In others cases:

  • Configure /etc/php/7.0/apache2/php.ini
openssl.capath=/etc/ssl/certs/
  • Fix function drupal_http_request
--- ./includes/common.inc       2017-06-21 15:20:18.000000000 -0300
+++ /var/www/drupal-7/includes/common.inc       2017-09-14 22:20:02.254394637 -0300
@@ -823,7 +823,7 @@
     'data' => NULL,
     'max_redirects' => 3,
     'timeout' => 30.0,
-    'context' => NULL,
+    'context' => stream_context_create(array('ssl'=>array('capath'=> ini_get('openssl.capath'),))),
   );

   // Merge the default headers.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.