Error when updating "-1 - An error has occurred"

  • Posts: 209
  • Thank you received: 18
12 years 11 months ago #33114

Hi HS team,

Whenever I update a business licence I get the permissions error as follows:

-1 - An error has occurred
It was not possible to copy the selected file


I know this problem is documented within Hikashop, and largely it has to do with the security settings on my server. However it is annoying and I just wanted to post the solution here, partly for my own future reference as I need to make the changes everytime I upgrade, and also for anyone else having this issue. The effect of the error is a site that is offline completely until corrected and sometimes finding the offending file permissions takes a while.

So here's the fix:

1. BEFORE INSTALLING THE UPDATE...
In cpanel, change the permissions of the following files to 644.
/administrator/components/com_hikashop/classes/config.php
/administrator/components/com_hikashop/controllers/config.php
/administrator/components/com_hikashop/views/config/tmpl/config.php

2. INSTALL THE HIKASHOP UPDATE...
In the Joomla backend, install the updated Hikashop file as per usual.

3. AFTER INSTALLING THE UPDATE...
In cpanel, change the permissions of the above files back to 400.

Works everytime.

cheers!

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
12 years 11 months ago #33119

These files should always have a permission of 644. There is no need to have them with 400 permissions.
Is there a reason why you have them with 400 ? Maybe you have some security tool which does that automatically ?

Please Log in or Create an account to join the conversation.

  • Posts: 209
  • Thank you received: 18
12 years 11 months ago #33126

Hi Nicolas, yes it is a routine security measure on my servers that change config files to 400 automatically. So not a problem with Hikashop, however the routine is becoming more popular on PHP servers especially those running ecommerce.

Annoying yes, but worth it for the extra security! Just wanted to post it as some people don't have control over file permissions or server routines and the error can sometimes be a bit baffling as a result. If it's an issue please feel to remove my post.

cheers!

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13375
  • MODERATOR
12 years 11 months ago #33147

These files are not config files in the sense you have for joomla. These are files used for the operations on the configuration page of HikaShop but they do not contain any configuration variables.
So their permissions should not be changed.

We could always change the name of these files to something in order to avoid the problem.

Please Log in or Create an account to join the conversation.

Time to create page: 0.057 seconds
Powered by Kunena Forum