New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to get 2.4.1 Update #478
Comments
There are already a lot of checks occurring during the online update process. Is anything logged in the error log? A red icon should appear in the top admin menu that links to the error log page. |
Accessing the error log page manually shows the log directory but no log entries. The log directory contains a .placeholder file and nothing else. |
Maybe the whole includes/OSC/Work directory is not writable so no error log is being written. Will look into it. |
Jim, did you extracted the package on your server, or did you ftp the files 2016-11-11 20:42 GMT+01:00 Harald Ponce de Leon notifications@github.com:
|
The includes/OSC/Work directory was not writeable as installed. I made it writeable (recursing into all subdirectories) but the error is still there, and there is still no error log file. My copy of PHP was lacking the zip module as well, which I assume would make it impossible to unpack the zip file that osCommerce downloads. I installed the module, but again no difference. Shouldn't the installer check for this? |
Henry: The server is on my local box, so I unpacked the files and copied them into Apache's root directory. The server is running Apache/2.4.18 (Ubuntu) / PHP 7.1.0RC5 / MySQL 5.7.16-0ubuntu0.16.04.1 on Linux 4.4.0-21-generic kernel. |
I only remember on my windows machine that the path to the directory had back and forward slashes in the error log before it got fixed. When the fix was made i never checked the path. |
Running on Linux here, so not a slashes problem. This is supposed to be a bare-bones server install, similar to what you would get on a VPS or dedicated server. It seems to be successful at generating bugs anyway. |
lol |
Could you edit admin/online_update.php lines 693 and 717 and change the error message from Error! to Error1 and Error2. Then we can see which condition is failing. |
Error1, so Line 693. |
So it passes the statement on line 674 which downloads the update, but fails the statement on line 678 which tries to apply it. Edit: It also fails to retrieve the update log (because there is no log written maybe?) which explains just the Error! line appearing. (see, we did think of everything 😛 ) |
I think there is a problem with the php tag used. Btw i never liked <? , some servers not even allow it. |
@osc2nuke since PHP 5.4: |
Confirm that the file is downloaded: a file named 2.4.1-update.zip is in /includes/OSC/Work/OnlineUpdates. Confirm that the error log file is not written: the /includes/OSC/Work/Logs directory contains a .placeholder file and nothing else. |
Henry: I replaced all of the <?= with <?php echo. No change. I've also checked the server error log, and nothing is being logged there either. |
@Kymation did you install oscom24 on vagrant? I just tried on vagrant with Ubuntu 16.04, PHP 7.1 RC 5, Apache 2.4, MySQL 5.5 and can confirm that the installation procedure continues if curl/gd are not available. The error log is being written to though (I did not change anything in the permissions), for example:
The Administration Dashboard front page does not load properly due to this. We'll make this a requirement as it's needed for online updates, app installs, and payment/shipping api calls. Adding curl to PHP makes the Administration Dashboard function as normal again. The online update routine gives me this as the first error:
So yes, the zip extension should be checked for during the installation procedure and online update routine. Adding the zip extension makes the the online update routine function as normal - no errors at all. It's strange that no errors are being logged on your server even with correct file permissions. Maybe some ini setting is preventing the error handler to load. |
I had to go look up Vagrant. No, I run native Linux (currently Linux Mint 18, which is Ubuntu 16.04 with some extras). I installed the latest versions of Apache, PHP, and MySQL using Apt. Once I saw the missing requirements on the installer page, I also installed the GD and cURL extensions using Apt. Once I noticed that the ZIP extension was missing, I installed that (and bzip2 for good measure). The /includes/OSC/Work/ directory was not writeable as installed. I changed that and osC was able to download the file, but it then got no further. I have confirmed that the Work directory and all subdirectories are owned by Apache (the user is www-data) and all of the directories have permissions of 777. I've tried more normal permissions (755, 775) with no change. I have edited the php.ini file to change all of the settings to Developer mode -- that is, all of the error reporting options, both to the log and to the screen, are turned on. This is one of the first things I did when setting up the server. I have confirmed that those settings have not changed, and that introducing an error shows up immediately on the page and in the log. Older versions of osCommerce run correctly on this server, as does the front end of 2.4.0 Beta. This is the only function I've found that doesn't work as expected. I'll take a further look at the code in a bit -- I need to get familiar with the new code anyway. I'll post anything I find here. |
I think I found it. This is permissions error. The update was failing on this line: I gave write permissions to Apache to that file and fixed that error. Then it proceeded to fail at this line: I don't know where it was trying to write something there, so I just gave Apache write permissions to everything in the www directory. Probably not a good idea in general, but it worked in this case: The update installed. How are the write permissions set for an update? I can't see where this is being managed. |
I was able to install, and subsequently update to 2.4.1, with no problem. osCommerce Online Merchant Version: 2.4.1 |
After install I tried the New Version check. It first failed because the includes/OSC/Work/OnlineUpdates directory was not writeable. Most users will not know what to do about this. Shouldn't it be checked during the install process, or at least in the Admin after install? Or if not that, give the solution in the error message.
After fixing the permissions, I get a box labeled "v2.4.1 (Friday 11 November, 2016)" and containing the text "Error!" I really hate this error message. What is it saying? Is this the same error? Something else? What?
The text was updated successfully, but these errors were encountered: