Drupal version: 7.8

When I try to install new modules, it fails with checksum error. For example, if I try to install panels, it throws this error:

Exception: Invalid checksum for file " (function ($) { Drupal.Panels = {}; Drupal.Panels.autoAttach = function() { if ($.browser." : 37331 calculated, 0 expected in Archive_Tar->_error() (line 635 of /home/mydomain/cmsbase7.8/modules/system/system.tar.inc).

This happens on the shared hosting server (linux) when installing using URL or Upload. But for the existing modules, the update works fine. The files are actually downloaded to the temporary directory of server and extracted properly. From the error, it looks like the file content has been used somewhere instead of file name.

The same install on my windows system works without any issues. Also, if I copy the update module from D7.0, it works fine on linux server.

Any kind of help or direction to solve the issue is appreciated. Thanks in advance.

Comments

LJCooper’s picture

I recently updated my install to 7.9 and since have had a similar issue?

I get a simple error message when trying to install or update modules that just says:

Invalid checksum for file " (this is exactly as it is seen with the " at the end of the error message)

Not sure what happened or what I did wrong on this update, but this is rather annoying not being able to add or update the modules I need to finish developing my site

chuckgnomes’s picture

I got the exact same error today even though it was working fine an hour before. I did a fresh install on another domain of my own I got the exact same problem. I can do a manual install and it's working perfectly but the invalid checksum appears only when I tried to install from the upload module within drupal.

bboldi’s picture

I have the exact same problem. I have just updated Drupal to version 7.9 and I get an error message when trying to update modules ( http://screencast.com/t/Pr4ViiZbX4VY ) :

Downloading updates failed:
Invalid checksum for file "

bboldi’s picture

And some more error messages: http://screencast.com/t/lVPdfC8x9NS

LJCooper’s picture

I went ahead and wiped everything out and tried again from a complete clean install of D7.9 since my project is still in the early stages and most of my content is saved in text files. Even after a clean install with new MySQL database, user and pass, I still get the error with an empty expression.

I am also getting this on another project also after I updated to 7.9 as well, so I wonder if this is something that corrupted in the upload feature, or is it something with shared hosting (i.e. is there something that the webhosts have or don't have that is affecting this)?

I am thinking of trying chuckgnomes method of manual install but not exactly sure which module folder to install the mods to, in the main module folder or in the module folder in default? Hey if someone can guide me to the right way of doing this I will try it just to get my projects back on track.

palwakeup’s picture

line 1319 in system.tar.inc

$this->_error('Invalid checksum for file "'.$v_data['filename']
.'" : '.$v_checksum.' calculated, '
.$v_header['checksum'].' expected');

above lines generate the error message,
from your message,
it seems the file name is not correct somehow.

Jim Ruby’s picture

never received thiswith 7.8, but in 7.9 I can not install or update modules any longter.

Jim Ruby’s picture

Just did a fresh install of 7.9 and I am getting this error when Iinstall a module with in drual. if I install it manually the install fails with a this web site encountered an error. could something of changed on my host provider? I would think this would be quite critical.

fauskanger’s picture

I too got the same error when trying to install the IMCE module, and when trying to install the Views module I got this error:

Invalid checksum for file "

It's a fresh, clean install of 7.9 and these two tasks were the first I tried to perform.

Anyone got an idea of a solution?

aarailfan’s picture

I'm seeing the same issue since upgrading to 7.9. It would be great to resolve this issue as I love how it simplifies updating my drupal sites.

alexdmccabe’s picture

I'm getting this too in 7.4 on HostGator.

facal’s picture

I am experiencing the same problem on Core 7.9 and Hostgator. Same site on a different host seems to be ok, it maybe a specific Hostgator problem.

aarailfan’s picture

Interesting...I'm on HostGator also. Must be something very recent as it worked until just a week or so ago. Anyone have any idea what might cause this?

bboldi’s picture

I'm on HG too!

allayit’s picture

Having same problem with Drupal module updates. First time I've had any issues updating Drupal v7.9.

Also using shared LAMP server with Hostgator. Is Hostgator the common factor here?

idaubs’s picture

Having the same issue on HostGator Shared LAMP Hosting env.

Drupal 7.9 when attempting to install any theme. Fresh install today.

Any help appreciated.

Thanks in advance,

-i

alexdmccabe’s picture

I got on Live Chat with Host Gator attempting to get a fix for this problem, and while attempting to demonstrate the issue with a test account on a throwaway Drupal install to a tech, I discovered that it now appears to be working, on three separate Drupal installs/subdomains. Anybody else having any luck?

facal’s picture

Seems to be working for me as well now.

alexdmccabe’s picture

I'm thinking somebody screwed up real good and HG didn't want to admit to it, because they were taking a very "We don't know what happened!" type of stance.

But it's fixed. Oh, well.

Ricardo Corai’s picture

How did you solve it?

bboldi’s picture

I think that the hosting company did something in the background, but unfortunately I do not know what that was exactly - it just started to work after a few days ...

drupalgod-1’s picture

Could be some issues with your Drupal temporary folder.

The following info helped me:
http://antojose.com/content/drupal-7-fix-modules-install-exception-inval...

skobe’s picture

thank you!! that solved it for me: changed temp folder from /tmp to tmp et voilà updates are applied and no error messages.

skobe’s picture

btw in my case there were canges made by the provider too.. could have caused the problem as well

sol289’s picture

First of all: I solved this issue by reinstalling php AND copying new /usr/local/etc/php.ini-production to /usr/local/etc/php.ini (FreeBSD 9.1).

At first i had this problem on multiple Drupal 7 sites within one server, PHP version was 5.3. Maybe it starts with an upgrade to 7 version, i don't remember, but i couldn't install module or theme via admin page, but had to manually copy it to /sites/ folder. The error was "Invalid checksum for file", and after upload in /tmp appears folders update-cache-xxxxxxxx with module archive in it and update-extraction-xxxxxxxx which is always empty. Then i upgrade PHP to 5.4.13 and all the extensions for it, and after restart error had changed to "Archivers can only operate on local files: temporary://path/to/archive not supported". Then i rename /usr/local/etc/php.ini-production to /usr/local/etc/php.ini and voila - everything starts to work as it should!

I diff'd old php.ini and new php.ini and found that my old php.ini contains a lot of strings that are not any more in new php.ini. This server was upgraded from FreeBSD 7.x to 8.x to 9.1 now, and so was PHP, and php.ini has been the same that was on FreeBSD 7.x.

So, in some cases it's just outdated config for new PHP. Try it, maybe you have it too.