Advanced SEO Working Great Except Attached ZIP File Download

phpBB3 SEO Advanced mod Rewrite support forum.
This mods performs URL rewriting for phpBB, injecting forums and topic titles in their URLs.

Moderator: Moderators

Advanced SEO Working Great Except Attached ZIP File Download

Postby admintiger » Mon Jul 07, 2008 5:39 am

I have been using the premod system with the Advanced SEO option for several weeks on two active boards. I have had excellent results, except for a problem discovered today.

If a ZIP file is attached to a post and then the ZIP file is downloaded, the downloaded file has slightly fewer bytes than the original and WinZIP reports that its contents are corrupted.

I have determined that attached ZIP files are not corrupted on the server. If I copy an attached file directly from the server /files directory to a /test directory and then rename the file so it has a ZIP extension, the file size is correct and WinZIP unzips the file with no errors.

I don't know whether this problem has anything to do with your SEO code. It may be a phpbb3 problem. However, I have been unable to find anything about it at the phpbb site.

Are you familiar with this problem or do you have an idea what might be causing it?

Thanks...

-Bob
Last edited by admintiger on Mon Jul 07, 2008 7:36 pm, edited 1 time in total.
admintiger
 
Posts: 16
Joined: Thu May 29, 2008 11:32 pm

Advertisement

Postby SeO » Mon Jul 07, 2008 1:06 pm

Now this is a weird one.

I was unable to reproduce it so far : http://phpbb3.phpbb-seo.net/demo-en/a-z ... d-t39.html

Could you try to deactivate url rewriting for a second to see if it changes something.

If not, chances are very little that it could be related to our mods (or the eventual additional ones by the way).
Then you could as well try without your .htaccess for a second (backup it, delete it, perform the test and put it back ASAP)

To go further, you could try to reproduce the bug on a vanilla install.
If you can, this would mean that the bug is really related to phpBB3 and most likely your server file-system.
SeO
Admin
Admin
 
Posts: 6333
Joined: Wed Mar 15, 2006 9:41 pm

Postby admintiger » Tue Jul 08, 2008 4:38 am

Thanks for your quick response.

1) I briefly deactivated url rewriting on both boards. That did not affect the ZIP download problem on either board.

2) I also temporary moved .htaccess from both board root directories to temporary directories. That also did not affect the problem.

3) I copied a test ZIP file to a temporary directory within one of the website roots. I then put url tags (instead of attachment tags) around the ZIP file URL in a post. I downloaded the ZIP file. Its size was correct and WinZIP unzipped it.

I wonder whether the fact that I am having this problem and you were unable reproduce it could be due to PHP version differences. My two boards are running on different physical servers (both my own) that are identically configured. They both have PHP 5.2.6, Apache 2.2.9 and Windows 2000 Advanced Server operating systems.

I didn't have time try a vanilla phpbb3 installation today. I plan to try that tomorrow.

Thanks very much for your help.

-Bob
admintiger
 
Posts: 16
Joined: Thu May 29, 2008 11:32 pm

Postby dcz » Tue Jul 08, 2008 8:46 am

Could be an apache / windows bug : http://www.apache.org/dist/httpd/binaries/win32/

Problems Installing or Running Apache 2

If you encounter problems running Apache 2 under Windows, such as corrupted or incomplete file downloads, unexplained error messages, or a conflict with a software firewall, please place the following three directives in your httpd.conf configuration file to see if they eliminate the problems:

EnableSendfile Off
EnableMMAP Off
Win32DisableAcceptEx

The general problem is that many people install various add-ons to windows (such as software firewalls, virus checkers, etc) that break some of the advanced functionality that Apache uses to speed the sending of files. The above directives turn off the advanced functionality and make Apache fall back to more basic (but slower) techniques. This resolves most, but not all of the potential problems. If you continue to experience problems, be certain that there is no spyware installed on the box, which exhibits exactly the same sorts of flaws (often more obviously).
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21219
Joined: Fri Apr 28, 2006 9:03 pm

Postby admintiger » Tue Jul 08, 2008 11:38 pm

Thanks for the Apache/Windows bug information. I saw that notice a couple months ago and put those three directives in httpd.conf, but then commented them out when I couldn't see that they changed anything. However, I wasn't aware of the ZIP file download problem at that time.

I re-enabled those three directives today and restarted Apache, but that didn't correct the ZIP file download problem or change anything else that I noticed.

I will try the vanilla phpbb3 installation that you suggested to see what can be learned from that.

-Bob
admintiger
 
Posts: 16
Joined: Thu May 29, 2008 11:32 pm

Postby dcz » Wed Jul 09, 2008 3:56 pm

I'm sorry I have very few knowledge about windows servers. We need to see if you can reproduce the bug with a vanilla test install on the same server to know more and eventually find out.

Have you tried with .rar files ? .gz ? etc ?

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21219
Joined: Fri Apr 28, 2006 9:03 pm

ZIP File Download Problem Solved

Postby admintiger » Fri Jul 11, 2008 11:16 pm

A vanilla installation of phpbb 3.01 had the same ZIP file download problem. However, I discovered with more testing that most ZIP files downloaded properly, but that some didn't. I also discovered that if I renamed a ZIP file that exhibited the problem with an EXE extension, attached it to a posted message, downloaded it, and then renamed it back to ZIP it had the correct file size and WinZIP would unzip it.

This is one of the fixes in the newly released phpbb 3.0.2:

"[Fix] Made the compress_tar class tolerate archives that do not properly have their archived contents listed (Bug #14429 / thanks to JRSweets for his patch)"

I just installed a vanilla phpbb 3.0.2. It does not exhibit the problem. The same ZIP files that 3.0.1 corrupted attach and download perfectly.

-Bob
admintiger
 
Posts: 16
Joined: Thu May 29, 2008 11:32 pm

Postby dcz » Sat Jul 12, 2008 7:44 am

So I guess we got our clue here, thanks for reporting the full story ;)

++
Useful links :
SEO Forum || SEO Directory || SEO phpBB || Search
____________________

Liens Utiles :
Forum référencement || Annuaire référencement || Référencement phpBB || Recherche
dcz
Admin
Admin
 
Posts: 21219
Joined: Fri Apr 28, 2006 9:03 pm


Return to Advanced SEO URL

 


  • Related topics
    Replies
    Views
    Last post

Who is online

Users browsing this forum: No registered users and 2 guests