While I am trying to update security patches I got following error message.

Checking if patch can be applied/reverted successfully...
ERROR: Patch can't be applied/reverted successfully.

patching file app/code/core/Mage/Admin/Model/Observer.php
Hunk #1 FAILED at 37.
Hunk #2 FAILED at 44.
Hunk #3 FAILED at 55.
3 out of 3 hunks FAILED -- saving rejects to file app/code/core/Mage/Admin/Model/Observer.php.rej
patching file app/code/core/Mage/Core/Controller/Request/Http.php
Hunk #1 succeeded at 39 with fuzz 1 (offset 1 line).
Hunk #2 succeeded at 537 (offset 1 line).
patching file lib/Varien/Data/Collection/Db.php
Hunk #1 FAILED at 442.
1 out of 1 hunk FAILED -- saving rejects to file lib/Varien/Data/Collection/Db.php.rej

How can I update patches in this regard ??

  • This is a bit less of information. Did you modify the corresponding files at any point? Best thing is to open the rejected files (*.rej) and see what happend there. – Anna Völkl Jun 16 '15 at 12:05

If patches can't be applied, check:

  1. Are you using the right patch version for your Magento version?
  2. Do the files that the patch fails to update present or have they been changed? Replace them with original files from your Magento version and apply the patch again

I had the problem, that only the file endings were replaced. dos2unix is here your tool of choice.

Just run it on the whole directory:

find . -type f -exec dos2unix {} \;

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.