Simple Machines Community Forum

SMF Support => SMF 2.0.x Support => Topic started by: NeedIt on May 09, 2013, 02:02:02 PM

Title: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 02:02:02 PM
I'm a newbie at this and have a basic question about upgrades.  I am currently sitting at 2.0 and need to go to 2.0.4 assuming it will work with the ad mod.

To do this, I have to go from 2.0 to 2.0.1 and then upgrade to 2.0.2 and then 2.0.3 and so on as multistep process, right?

In other words, there is no way to go from 2.0 to 2.0.4 directly, right?

I just want to make sure I'm not missing something...

Title: Re: 2.0 to 2.0.4
Post by: Chalky on May 09, 2013, 02:05:04 PM
Right :)  You need to do it in order one step at a time.  Don't forget to backup before you start  ;)
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 02:07:46 PM
Quote from: ChalkCat on May 09, 2013, 02:05:04 PM
Right :)  You need to do it in order one step at a time.  Don't forget to backup before you start  ;)

What about this?  I found this:

Can I use the middle option on this page?

http://download.simplemachines.org/

In other words, if I use the "Large Upgrade" option, it will take me from 2.0 to 2.0.4, right? Or am I misinterpreting?
Title: Re: 2.0 to 2.0.4
Post by: YogiBear on May 09, 2013, 02:11:56 PM
You can do that but Chalky's method is the easiest. I know someone who tried to go directly from 1.1.11 to 1.1.18 ended up with a MySQL database error which put her forum off-line so she had to rely on a backup.

If it were me I'd go incrementally 2.0 > 2.0.1 > etc...
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 09, 2013, 02:14:19 PM
If you go directly from 2.0 to 2.0.4 with the Large Upgrade, you will have to reinstall any other mods you have. Not recommended for minor upgrades like yours.
Title: Re: 2.0 to 2.0.4
Post by: Chalky on May 09, 2013, 02:15:46 PM
The large upgrade package is designed for those upgrading from the 1.x branch.  If you use that, you will lose all your mods and customisations, and be left with a clean vanilla install of SMF 2.0.4.  If you're only going from 2.0 that's completely unnecessary because each upgrade after that is just a security patch and will not affect your mods if done as intended 2.0 > 2.0.1, 2.0.1 > 2.0.2 >..... until you get to 2.0.4.  It doesn't take long really, each upgrade patch only took a minute to install on my forum, as each one is just like installing a mod and is installed through Package Manager the same way.

Just take a full backup, a deep breath and install the incremental patches :)
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 02:27:21 PM
Thx guys.

One last q:  the Ad Mod works with 2.0.4, right?
Title: Re: 2.0 to 2.0.4
Post by: Chalky on May 09, 2013, 02:29:56 PM
If it's already working on 2.0 there's no reason why it shouldn't  ;)
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 02:39:12 PM
Quote from: ChalkCat on May 09, 2013, 02:29:56 PM
If it's already working on 2.0 there's no reason why it shouldn't  ;)

Okay.  I will have faith.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 02:59:56 PM
Okay, I just clicked on the 2.0.1 to 2.0.2 download link and it brought up some script modifications:

http://custom.simplemachines.org/upgrades/index.php?action=upgrade;file=smf_patch_2.0.2.tar.gz;smf_version=2.0.1

So I am supposed to just do these manually, i.e. I do not use a formal install process, right?
Title: Re: 2.0 to 2.0.4
Post by: Chalky on May 09, 2013, 03:03:27 PM
No, not like that  :)  Click on the download button next to it instead.  Save it your your computer, then go into your package manager and in download packages, upload from your computer and install like a mod ;)
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 03:17:13 PM
Quote from: ChalkCat on May 09, 2013, 03:03:27 PM
No, not like that  :)  Click on the download button next to it instead.  Save it your your computer, then go into your package manager and in download packages, upload from your computer and install like a mod ;)

Okay, I downloaded it and it created this file on my laptop:

smf_patch_2.0.2.tar.gz

Then I went to BrowsePackage/Download Packages/File/I browse to file location/Upload and I got this error msg:

"Package upload failed due to the following error:
"The package you are trying to install cannot be located. You may want to manually upload the package to your Packages directory.""

Any idea what I'm doing wrong?  I can leave it tarred and gzipped, right?

Also, can I just ftp manually the above  file into ./Packages per the above right?
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 03:29:23 PM
Nevermind.  I pushed that into Packages and now it's showing up in Pkg Mgr.

So now I clicked Install Mod and I got the following error:

"You cannot download or install new packages because the Packages directory or one of the files in it are not writable!"

Do I need to change the file attributes through Package Manager File Permssions or should I do it through FileZilla?
Title: Tar.gz Package Not Writeable in Windows
Post by: NeedIt on May 09, 2013, 04:03:08 PM
To make a long story short, I downloaded the 2.0.1 to 2.0.2 package and it is a tar.gz file, specifically smf_patch_2.0.2.tar.gz.  I ftp'd that up into the packages directory and it does indeed now show up in Package Manager.

However, my site is on a Windows server, so it does not like a tarred and gzipped file and throws up when I click Install Mod.  When I click Install Mod and I get the following error:

"You cannot download or install new packages because the Packages directory or one of the files in it are not writable!"

There must be some way around this?  Can I extract the files out of the tar.gz file and then upload them somehow individually or something?

Any help is much appreciated.
Title: Re: Tar.gz Package Not Writeable in Windows
Post by: Arantor on May 09, 2013, 04:04:34 PM
There is a way around it - it's telling you the problem: it doesn't have proper permissions to write to everywhere it needs...
Title: Re: Tar.gz Package Not Writeable in Windows
Post by: Colin on May 09, 2013, 04:06:19 PM
I am not convinced that it has to do with the compression. You can always unarchive it and then archive it into a ZIP if you want to give that a try. Have you checked the file permissions though?



**Ninja'd by Arantor.
Title: Re: Tar.gz Package Not Writeable in Windows
Post by: NeedIt on May 09, 2013, 04:14:17 PM
Quote from: Colin on May 09, 2013, 04:06:19 PM
I am not convinced that it has to do with the compression. You can always unarchive it and then archive it into a ZIP if you want to give that a try. Have you checked the file permissions though?



**Ninja'd by Arantor.

Okay, but I'm asking a more basic question I think:

What can the installer handle?  It can handle a zip file on a windows system, right? 
Title: Re: Tar.gz Package Not Writeable in Windows
Post by: NeedIt on May 09, 2013, 04:17:42 PM
Quote from: Arantor on May 09, 2013, 04:04:34 PM
There is a way around it - it's telling you the problem: it doesn't have proper permissions to write to everywhere it needs...

Okay, I think you're saying that the file needs to have FULL CONTROL, right?

But I have a more basic question:  Windows can't handle tar or gzip, right?  So even in the Installer likes those, it's not going to work on a Win server, correct?
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 09, 2013, 04:19:43 PM
Where do you get this idea that Windows can't handle tar or gzip?

SMF doesn't use the raw operating system handling (because that would be different from system to system)... it does it itself.

Not to mention that PHP has a library for gzip support ;)

You have to give Full Control to the Packages folder and EVERY FOLDER AND FILE in the rest of SMF since that's how the package manager works, it applies find/replace operations on PHP files
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 04:20:30 PM
Quote from: Arantor on May 09, 2013, 04:19:43 PM
Where do you get this idea that Windows can't handle tar or gzip?

SMF doesn't use the raw operating system handling (because that would be different from system to system)... it does it itself.

Not to mention that PHP has a library for gzip support ;)

You have to give Full Control to the Packages folder and EVERY FOLDER AND FILE in the rest of SMF since that's how the package manager works, it applies find/replace operations on PHP files

Noted.  I will call them back.
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 09, 2013, 04:22:05 PM
Call what back?
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 05:14:40 PM
Quote from: Arantor on May 09, 2013, 04:22:05 PM
Call what back?

The hosting company and make sure all files in Package and Package itself has FULL CONTROL.  If I'm missing your point, let me knwo.
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 09, 2013, 05:16:43 PM
Sort of...

You have to make sure Packages, and then Sources and Themes and every folder and file within...
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 09, 2013, 05:21:58 PM
Quote from: Arantor on May 09, 2013, 05:16:43 PM
Sort of...

You have to make sure Packages, and then Sources and Themes and every folder and file within...

Sorry I didn't quite understand that originally as there are no such folders under the Package directory and I assumed my forum would not function without those.  But I will ask about those just to make sure.
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 09, 2013, 05:23:59 PM
No, there aren't. That's because I wasn't talking about that. I was talking about the MAIN Sources and Themes folders where the rest of SMF is located. Seeing how the package manager does find/replaces on the MAIN SMF code, it sort of needs to be able to modify the actual SMF files...
Title: Re: 2.0 to 2.0.4
Post by: Colin on May 09, 2013, 07:43:01 PM
Out of curiosity did your hosting company try to tell you the issue was because you were running Windows thus it wouldn't be able to handle tars?
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 10, 2013, 12:42:12 AM
The first guy told me that but I pushed per the suggestions on this thread and found out - knock on wood - how to handle the permissions in Plesk File Manager.  The issue was just what you guys said.

Question:  I successfully ran the install from 2.0.1 to 2.0.2.  However, when I got to the very bottom of my home page, it still says 2.0.1.  Where can I prove that the install was really successful by seeing a new version number?
Title: No Install Now
Post by: NeedIt on May 10, 2013, 02:22:19 PM
I successfully installed the 2.0.2 mod - woo hoo my first mod! - and it shows the green dot next to it in package manager, so I assume that's a good sign.

Anyway, just now I uploaded the 2.0.3 mod and the 2.0.4 mod using FTP technique.  These do show up in the package manager.  However, there is not an option to Install Now next to these.  All it says is List Files.

What would cause this behavior and what do I do?
Title: Re: No Install Now
Post by: TheListener on May 10, 2013, 02:23:31 PM
Firstly which mod.

Have a look at the mod emulate link in my sig which will explain what to do.
Title: Re: No Install Now
Post by: NeedIt on May 10, 2013, 02:27:28 PM
Quote from: Old Fossil on May 10, 2013, 02:23:31 PM
Firstly which mod.

Have a look at the mod emulate link in my sig which will explain what to do.

Okay, I just installed the 2.0.1 to 2.0.2 mod.  Then I was trying to do the 2.0.2 to 2.0.3 mod.  (After that I want to do the 2.0.3 to 2.0.4 mod, but one thing at a time I guess.)

So, again, it's the 2.0.2 to 2.0.3 mod that does not have the Install Now.

One question:  after I did the install of the 2.0.1 to 2.0.2, it did not change the version down at the very bottom of my home page.  Does this mean I did something or something went wrong?
Title: Re: No Install Now
Post by: TheListener on May 10, 2013, 02:29:22 PM
Quotejust installed the 2.0.1 to 2.0.2 mod.

You just repeated the first post without answering my question.
Title: Re: No Install Now
Post by: NeedIt on May 10, 2013, 02:32:11 PM
Quote from: Old Fossil on May 10, 2013, 02:29:22 PM
Quotejust installed the 2.0.1 to 2.0.2 mod.

You just repeated the first post without answering my question.

Okay, well, I'm sorry I'm not sure I totally understand the question.  I want to install the 2.0.2 to 2.0.3 mod and I am not sure what that is called?  Sorry - not being difficult - but I don't understand what else you are looking for.

Also, I did the emulation and it shows this in the text box if that helps:

SMF 2.0.1

But I did not do anything else as I want to read what you have to say before I pull the trigger...
Title: Re: No Install Now
Post by: TheListener on May 10, 2013, 02:36:24 PM
Is it a mod you are stalling or an upgrade.

Do you have a forum link we can view?

An image may help us understand more too.
Title: Re: No Install Now
Post by: Drunken Clam on May 10, 2013, 02:37:14 PM
Old Fossil, a bit of background can be found   HERE (http://www.simplemachines.org/community/index.php?topic=503470.msg3541606#msg3541606)
Title: Re: No Install Now
Post by: TheListener on May 10, 2013, 02:39:40 PM
Thanks Clam.

If as it seems the problem is with the ad mod then the OP should use the mods support topic.
Title: Re: No Install Now
Post by: NeedIt on May 10, 2013, 02:46:03 PM
Quote from: Old Fossil on May 10, 2013, 02:39:40 PM
Thanks Clam.

If as it seems the problem is with the ad mod then the OP should use the mods support topic.


No, I'm not doing the Ad Mod yet.  Sorry - one sec as I'm trying to locate the download link that I used.  I can't remember if it was called Upgrade or what.
Title: Re: 2.0 to 2.0.4
Post by: Kindred on May 10, 2013, 02:46:24 PM
merged topics - please don't open a new topic if you already have asked the question in another topic.

Fossil...  nope.   I suspect that the 2.0.2 patch did not get fully applied. The note that the forum copyright still red 2.0.1 suggests that. --- and that is why the system is not added an install link next to the 2.0.3 patch ---   because the system still thinks that it is running 2.0.1
Title: Re: 2.0 to 2.0.4
Post by: TheListener on May 10, 2013, 02:50:32 PM
Thanks for the update Kindred.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 10, 2013, 02:50:46 PM
Quote from: Kindred on May 10, 2013, 02:46:24 PM
merged topics - please don't open a new topic if you already have asked the question in another topic.

Fossil...  nope.   I suspect that the 2.0.2 patch did not get fully applied. The note that the forum copyright still red 2.0.1 suggests that. --- and that is why the system is not added an install link next to the 2.0.3 patch ---   because the system still thinks that it is running 2.0.1

K.  Sorry.  I didn't know if you allowed bumps?

Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 10, 2013, 02:51:56 PM
Quote from: Old Fossil on May 10, 2013, 02:50:32 PM
Thanks for the update Kindred.

Okay, I found it.  It was an Upgrade - sorry I used the wrong term.

Here is the link to the downloads that I have been doing.  I used FTP to load them into the Packages folder and I had to go into Plesk File Mgr in order to alter permissions for it to work. 

http://custom.simplemachines.org/upgrades/
Title: Re: 2.0 to 2.0.4
Post by: TheListener on May 10, 2013, 02:52:33 PM


Quote from: NeedIt on May 10, 2013, 02:50:46 PM
Quote from: Kindred on May 10, 2013, 02:46:24 PM
merged topics - please don't open a new topic if you already have asked the question in another topic.

Fossil...  nope.   I suspect that the 2.0.2 patch did not get fully applied. The note that the forum copyright still red 2.0.1 suggests that. --- and that is why the system is not added an install link next to the 2.0.3 patch ---   because the system still thinks that it is running 2.0.1

K.  Sorry.  I didn't know if you allowed bumps?

Only after a 24 hour period.
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 10, 2013, 02:53:43 PM
Sounds to me like you didn't give permissions to Sources and Themes and *every* file inside all those folders.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 10, 2013, 02:59:13 PM
Quote from: Arantor on May 10, 2013, 02:53:43 PM
Sounds to me like you didn't give permissions to Sources and Themes and *every* file inside all those folders.

No I know how to do that now and the install was succesful last night.  I'm pumped.  But for some reason the Install Now is not showing up beside the next mod in the Package Manager.

It looks like I can use the emulator but I don't know what to put in the text box. I guess I'd put 2.0.2, right?  I mean since I successfully installed 2.0.2 and I want to do the upgrade to 2.0.3?
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 10, 2013, 03:06:20 PM
If you installed 2.0.2 but the footer still says 2.0.1 it WAS NOT successful since at least one file was NOT changed.

Verify every edit made by the 2.0.1 -> 2.0.2 upgrade before proceeding.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 10, 2013, 03:08:50 PM
Quote from: Arantor on May 10, 2013, 03:06:20 PM
If you installed 2.0.2 but the footer still says 2.0.1 it WAS NOT successful since at least one file was NOT changed.

Verify every edit made by the 2.0.1 -> 2.0.2 upgrade before proceeding.

Okay.  Will do.  And one question.  If it did not modify everything, which it sounds like it did not, then can I just rerun this upgrade? 
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 10, 2013, 03:16:01 PM
That depends. If *some* things are done but not everything, you'll have to fix the missing bits manually. (Or at least you'll be best doing it that way)

But if nothing has been changed, you could theoretically 'uninstall' the 2.0.2 patch mod, ignore all the failed edits, then reinstall.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 11, 2013, 03:18:58 AM
Quote from: Arantor on May 10, 2013, 03:16:01 PM
That depends. If *some* things are done but not everything, you'll have to fix the missing bits manually. (Or at least you'll be best doing it that way)

But if nothing has been changed, you could theoretically 'uninstall' the 2.0.2 patch mod, ignore all the failed edits, then reinstall.

Thx for all the help.  I edited all of those files and now the "Install Now" shows up for the next Update.  I think I know what I did wrong last time and will try it again.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 12, 2013, 07:54:11 PM
I tried to upgrade from 2.0.2 to 2.0.3.  I got the following error message:

"At least one error was encountered during a test installation of this package. It is strongly recommended that you do not continue with installation unless you know what you are doing, and have made a backup very recently. This error may be caused by a conflict between the package you're trying to install and another package you have already installed, an error in the package, a package which requires another package that you don't have installed yet, or a package designed for another version of SMF."

Below is where the reported error is.  I have the same permissions, which I set through Plesk File Manager, on index.php as I did on everything else, so I don't know why it is balking.  Any idea what might cause this?

Also, why does it show one replace works and one doesn't?  This isn't because of traffic on the forum itself, right?

Error in Package Installation

Type   Action   Description
   1.   Execute Modification   ./index.php   Test failed
   1.   Replace   ./index.php   Test failed
   2.   Replace   ./index.php   Test successful
   2.   Execute Modification   ./SSI.php   Test successful
   3.   Execute Modification   ./Sources/Modlog.php   Test successful
   4.   Execute Modification   ./Sources/Security.php   Test successful
   5.   Execute Modification   ./Sources/Subscriptions-PayPal.php   Test successful
   6.   Execute Modification   ./Sources/ManagePaid.php   Test successful
   7.   Execute Modification   ./Sources/QueryString.php   Test successful
   8.   Execute Modification   ./Sources/Load.php   Test successful
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 12, 2013, 07:57:16 PM
Well, that's saying that the first edit it's trying to do is failing. Specifically, that is the following:

index.php
Code (find) Select
* @copyright 2011 Simple Machines
* @license http://www.simplemachines.org/about/smf/license.php BSD
*
* @version 2.0.2


Code (replace) Select
* @copyright 2011 Simple Machines
* @license http://www.simplemachines.org/about/smf/license.php BSD
*
* @version 2.0.3


That suggests that the 2.0.2 upgrade did not complete fully as before because it's expecting to find the @version 2.0.2 header but that it isn't.

This test doesn't care about permissions, it simply attempts to check that for every find/replace it wants to do, it can actually find it.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 12, 2013, 08:04:38 PM
Great info.  Thx.

As you may or may not remember, I manually edited these when I did the upgrade from 2.0.1 to 2.0.2.  Here is what is in my index.php:

/**
* Simple Machines Forum (SMF)
*
* @package SMF
* @copyright 2011 Simple Machines
  * @license http://www.simplemachines.org/about/smf/license.php BSD
  *
* @version 2.0.2
*/

Now that looks correct to me, except of course for the spacing on the very left of each line.  Does that have to be perfect as well?
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 12, 2013, 08:06:03 PM
Yes, that has to be perfect as well. It's one space then the asterisk.

The only reason the first line of the quoted code is off is because that's what the package looks for. The file, ultimately looks like:

<?php

/**
 * Simple Machines Forum (SMF)
 *
 * @package SMF
 * @author Simple Machines http://www.simplemachines.org
 * @copyright 2011 Simple Machines
 * @license http://www.simplemachines.org/about/smf/license.php BSD
 *
 * @version 2.0.2
 */
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 12, 2013, 08:22:59 PM
Thx.  Okay, I notice that the Install Now is still next to that mod.  So basically I can fix that and then rerun the Install Now and it should work, right?
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 12, 2013, 08:25:50 PM
In theory, yes. The install now simply means that the mod has instructions for the current version of SMF that you have installed ;)
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 12, 2013, 10:59:06 PM
Quote from: Arantor on May 12, 2013, 08:25:50 PM
In theory, yes. The install now simply means that the mod has instructions for the current version of SMF that you have installed ;)

Noted.  Will try it again soon.
Title: Re: 2.0 to 2.0.4
Post by: NeedIt on May 13, 2013, 11:57:28 AM
Okay, I was able to run successfully I'm pretty sure the upgrades to 2.0.3 and 2.0.4.  But I have a question:

Let's say you were going to do a more involved mod like the Ad Mod.  And let's say it has 30 pages to change - I haven't looked but I assume it's very large.  Can you end up, if the install fails in the middle, with 20+ changes to change manually?  And can you end up with your forum in a non-functional state?
Title: Re: 2.0 to 2.0.4
Post by: Arantor on May 13, 2013, 12:00:48 PM
QuoteAnd can you end up with your forum in a non-functional state?

Yes, you can, but read on first.

QuoteCan you end up, if the install fails in the middle, with 20+ changes to change manually?

The install won't 'fail in the middle'. The tests are all done before any changes are applied. So if any fail, nothing will be changed.

Now, if you proceed with 'test failed' entries, all that it means is that all the successful operations will actually be applied, but the ones with 'test failed' will (obviously) not have been applied. So yes, you can at that point end up with a non functional state.

But you can then proceed to perform the outstanding edits manually.

It is possible, too, that some even 'successful' mods can leave you with a non functional forum because of the fragile nature of 'find/replace' operations, e.g. when operating on what appear to be code that can appear multiple times.