cancel
Showing results for 
Search instead for 
Did you mean: 

PATCH_SUPEE_6788

PATCH_SUPEE_6788

I'm attempting to install this patch in our CE Magento ver. 1.8.1.0.

 

I've tried both these scripts:

 

PATCH_SUPEE-6788_CE_1.8.1.0_v1-2015-10-26-11-59-27.sh

PATCH_SUPEE-6788_CE_1.8.0.0_v1-2015-10-26-11-59-56.sh

 

And both appear to error out when executing the script

 

Are there any prereq patches that must be installed first?  I have the following already installed

 

2015-04-30 04:11:01 UTC | SUPEE-1533

2015-04-30 04:11:25 UTC | SUPEE-5344

2015-05-19 07:21:42 UTC | SUPEE-5994

2015-07-08 14:09:32 UTC | SUPEE-6285

2015-11-24 17:14:31 UTC | SUPEE-6482

 

Many thanks!

 

Robby

 

9 REPLIES

Re: PATCH_SUPEE_6788

Here is the error....looks like it patches but nothing gets updated in my applied.patches.list file.

 

[root@<host> httpdocs]# ./PATCH_SUPEE-6788_CE_1.8.1.0_v1-2015-10-26-11-59-27.sh
Checking if patch can be applied/reverted successfully...
ERROR: Patch can't be applied/reverted successfully.

patching file .htaccess
Hunk #1 FAILED at 207.
1 out of 1 hunk FAILED -- saving rejects to file .htaccess.rej
patching file .htaccess.sample
patching file app/code/core/Mage/Admin/Model/Block.php
patching file app/code/core/Mage/Admin/Model/Resource/Block.php
patching file app/code/core/Mage/Admin/Model/Resource/Block/Collection.php
patching file app/code/core/Mage/Admin/Model/Resource/Variable.php
patching file app/code/core/Mage/Admin/Model/Resource/Variable/Collection.php
patching file app/code/core/Mage/Admin/Model/Variable.php
patching file app/code/core/Mage/Admin/etc/config.xml
patching file app/code/core/Mage/Admin/sql/admin_setup/upgrade-1.6.1.1-1.6.1.2.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Block.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Block/Edit.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Block/Edit/Form.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Block/Grid.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Variable.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Variable/Edit.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Variable/Edit/Form.php
patching file app/code/core/Mage/Adminhtml/Block/Permissions/Variable/Grid.php
patching file app/code/core/Mage/Adminhtml/controllers/Permissions/BlockController.php
patching file app/code/core/Mage/Adminhtml/controllers/Permissions/VariableController.php
patching file app/code/core/Mage/Adminhtml/etc/adminhtml.xml
patching file app/code/core/Mage/Catalog/Model/Product/Option/Type/File.php
patching file app/code/core/Mage/Core/Controller/Request/Http.php
patching file app/code/core/Mage/Core/Controller/Varien/Router/Admin.php
patching file app/code/core/Mage/Core/Helper/UnserializeArray.php
patching file app/code/core/Mage/Core/Model/Email/Template/Filter.php
patching file app/code/core/Mage/Core/Model/Resource/Setup.php
patching file app/code/core/Mage/Core/etc/config.xml
patching file app/code/core/Mage/Core/etc/system.xml
patching file app/code/core/Mage/Customer/Block/Account/Changeforgotten.php
patching file app/code/core/Mage/Customer/Block/Account/Resetpassword.php
patching file app/code/core/Mage/Customer/controllers/AccountController.php
patching file app/code/core/Mage/Downloadable/Model/Product/Type.php
patching file app/code/core/Mage/Eav/Model/Resource/Attribute/Collection.php
patching file app/code/core/Mage/Sales/Model/Resource/Order/Item/Collection.php
patching file app/code/core/Mage/Sales/controllers/DownloadController.php
patching file app/code/core/Mage/SalesRule/Model/Resource/Coupon/Collection.php
patching file app/code/core/Zend/Soap/Server.php
patching file app/code/core/Zend/Xml/Exception.php
patching file app/code/core/Zend/Xml/Security.php
patching file app/code/core/Zend/XmlRpc/Request.php
patching file app/code/core/Zend/XmlRpc/Response.php
patching file app/design/adminhtml/default/default/layout/admin.xml
patching file app/design/frontend/base/default/layout/customer.xml
patching file app/design/frontend/base/default/template/customer/form/register.phtml
patching file app/design/frontend/base/default/template/customer/form/resetforgottenpassword.phtml
patching file app/design/frontend/base/default/template/page/js/cookie.phtml
patching file app/design/frontend/base/default/template/persistent/customer/form/register.phtml
patching file app/design/frontend/default/iphone/layout/customer.xml
patching file app/design/frontend/default/modern/layout/customer.xml
patching file cron.php
patching file errors/processor.php
patching file lib/Unserialize/Parser.php
patching file lib/Unserialize/Reader/Arr.php
patching file lib/Unserialize/Reader/ArrKey.php
patching file lib/Unserialize/Reader/ArrValue.php
patching file lib/Unserialize/Reader/Bool.php
patching file lib/Unserialize/Reader/Dbl.php
patching file lib/Unserialize/Reader/Int.php
patching file lib/Unserialize/Reader/Str.php
patching file lib/Varien/Data/Collection/Db.php

Re: PATCH_SUPEE_6788

patching file .htaccess

Hunk #1 FAILED at 207.

1 out of 1 hunk FAILED -- saving rejects to file .htaccess.rej

You have a customized .htaccess file which most sites do.

 

Save a copy of the .htaccess file somewhere safe.

 

Download the Magento 1.8.1.0 installer archive, extract .htaccess and upload it to your website

 

Apply patch SUPEE-6788

 

Merge the changes made to this .htaccess file with your saved customized .htaccess file and upload it to your website.

Re: PATCH_SUPEE_6788

That's incorrect because I have 2 separate magento installations both 1.9.1.0 and I get no error when 6788 patching (with all other prior patches being successful) one but the other produces the exact same error as described above (again with all other prior patches being successful). The .htaccess files are identical on both servers - and exactly the same as the original magento 1.9.1 download zip version. The only identifiable difference is one server is running php 5.4 with suhosin enabled - which is the server where the patch failed, the other has suhosin disabled an the installation was perfect. So I'll try disabling suhosin on the failing server but somebody else may also read this and be able to identify any other issues hopefully.

Re: PATCH_SUPEE_6788

Silly question......are there any drawbacks to running the patch multiple times?  I assume the script checks if the files have been patched already?

 

 

Re: PATCH_SUPEE_6788

@Encaps

 

Hunk failures are caused because there is a discrepancy between what the patch expects and what is in the file.

 

This can be as simple as an extra space, newline or an upload that failed to translate from MSDOS to *nix line endings.

 

Suhosin is a security measure that depending on settings, will protect certain files from modification, so yeah, having it enabled is going to cause issues.

Re: PATCH_SUPEE_6788

@robbyotts

 

The way the *nix patch program works is to read a template, find what is expected at the line number and then change the line numbers indicated for change. If it doesn't pass finding the expected content and the fuzzing factor isn't met, it fails and gives a hunk failure, pops out a reject file that's supposed to help you find what the issue is and terminates without applying the patch.

 

The patch is not supposed to modify anything unless it actually can pass the initial test pass, so it should be able to be run until it passes with success. If you accidentally run it after a successful patch, it will attempt to undo the patch and revert the files to their original content. That would be it's drawback.

Re: PATCH_SUPEE_6788

Don't think it's Suhosin in my case....this is my .htaccess file  (although I'm not familiar with Suhosin)

 

###########################################
# disable user agent verification to not break multiple image upload

    php_flag suhosin.session.cryptua off

 

 

Re: PATCH_SUPEE_6788

Thanks!!  I looked for the .htaccess.rej file but can't locate it so not sure if it's actually being created or not.....

 

Sorry for constant replies....I have done as much googling as I can before I ask.....

 

Thanks again for all yalls help!!

 

Rob

Re: PATCH_SUPEE_6788

My failed installation didn't produce a .htaccess.rej file either. I have however successfully been able to apply the patch now. Note that disabling suhosin made no difference. The patch still failed with suhosin disabled in cpanles php version settings. Also note that I obtained the .htaccess file from the original zip file I still had for the 1.9.1 magento installation.

 

 

basically what I did was back up my existing .htccess file. I then ftp uploaded the original magento full installation zip into my existing shops top level directory where the problematic .htacess file lives. I then used cpanel file manager to decompress it which creates a new 'magento' directory that contains the fresh original .htaccess file in it. I then deleted the existing problematic .htaccess in the top level of my shop and copied the new .htaccess file from the new magento folder into my shops top level so I had the original version .htaccess there. I then ran the patch and it worked perfectly. I then deleted the zip and newly created 'magento' folder as no longer needed and job done.

 

You can then merge the backed up .htaccess with the new patched version, but in my case this wasn't necessary. The odd thing is prior to doing the above method, I decompressed the magento installation zip locally and compared the local .htaccess file with the live one and there was no discernible difference. So it would seem there is something indistinguishable introduced onto the .htaccess when it is decompressed locally that caused the patch to fail in a live setting. Decompressing the zip on the live sever instead and moving files around in that environment using either shell or cpanel file manager seemed to resolve this problem.

 

It's worth noting though that 6788 makes enough significant changes to your magento installation that I'd strongly recommend testing it first in a test environment to ensure it doesn't break any part of your shop as there are a number of aspects that could do this. It is by no means as 'easy going' on your shop as the prior patches so take necessary precautions and full backups and do some testing prior to patching.

 

@robbyotts

 

I think the reason the .htaccess.rej file may not be produced is there is nothing to put in it. As mentioned there was no discernible difference in my .htaccess files prior to patching when comparing them both on my local drive, however the patch obviously sees something minuscule causing the error. You could perhaps compare your 2 htaccess files yourself prior to running the patch (as in the current one in your shop and the original one that the decompressed zip produces)  to see if it's the same for you as well since we both experienced the same error. If they are indeed the same it may be that there will be noting to merge and once the patch is run and you won't need to do anything further with your new patched htaccess file.