Author Topic: Version update - my poor understanding  (Read 3905 times)

Offline peladon

  • Newbie
  • *
  • Posts: 4
  • I tech and I'm an author. Or the other way round..
    • Writing the Bright Fantastic
Version update - my poor understanding
« on: April 03, 2013, 10:27:31 AM »
First, my apologies if this is in the wrong place. I could have put it in Issues, but I didn't think that really fitted either.
Yes - I'm an Idiot  :-[.
I'm looking at upgrading two Roundcube installs I have (one at 0.4.2 and one at 0.7.1). I've never done an upgrade before, so I looked at the WIKI and the UPGRADING file from the latest release.
That's, um, when I got confused.

From the UPGRADING file:
************************************
1. Replace index.php and all files in
   - ./bin/
   - ./SQL/
   - ./program/
   - ./installer/
   - ./skins/default/
   - ./plugins/
************************************

From the WIKI:
http://trac.roundcube.net/wiki/Howto_Upgrade
************************************
Check Your Configuration

Download your config/main.inc.php and config/db.inc.php files and place them in your config folder so you will not have to copy them over later.

Be sure to check config/main.inc.php.dist and config/db.inc.php.dist to make sure you have any new settings that may have appeared in the new version! Some people may prefer to copy the new .dist files and recreate their needed changes.
Upload a new copy

Use your favorite FTP/SFTP/SCP program to rename or remove the old folder and upload the new one.
************************************

Here's my confusion:

1: The WIKI seems to say 'trash your old install folder, and install the new unzipped folder set'. So no exceptions, delete top level of old install, copy in new top level folder.
That seems to contradict the rather more selective instructions in the UPGRADING file in the new package.

2: If the path isn;t actually to trash the whole of the old install folder, 'replace' can be read two ways. The text is:
"Replace index.php and all files in..."
Does the 'replace' refer to the whole folder, or to files in it? So, for example:

./bin - old install
File1
File2
File3
File4

./bin - new package
File2
File4
Newfile1

Do I:
Leave File1 and File3 in place, but copy over File2 and File4 from the new package, then add Newfile1 ('replace' at the file level)
or
delete ./bin and copy over the new ./bin ('replace' at the folder level)?

I know I'm probably being stupid. But everyone has to be good at _something_ - dumb seems to be one of my few talents  :).
In addition, if I may, does the mysql.update.sql script know how to autodetect which lines to run, or do I have to modify it prior to execution and drop lines prior to my current release level?
My thanks in advance - any apology for sounding like a total newb. It's mostly because, um, I am. To upgrading, at least  :-[ :).
---
The Idiot

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,881
    • SKaero - Custom Roundcube development
Re: Version update - my poor understanding
« Reply #1 on: April 03, 2013, 02:06:43 PM »
Follow the wiki your end up with less old un-used files. You'll need to open the mysql.upgrade.sql and run all of the lines under the version you are upgrading from. And remember backup before doing anything.

Offline peladon

  • Newbie
  • *
  • Posts: 4
  • I tech and I'm an author. Or the other way round..
    • Writing the Bright Fantastic
Re: Version update - my poor understanding
« Reply #2 on: April 03, 2013, 06:47:44 PM »
My thanks indeed  :).
I updated the 0.4.2 without issue, following your suggestion. I updated the 0.7.1 and was unable to connect. I deleted, recreated and re-imported the original database (I'd run the mysql update script fragment even though it said 'update from 0.7' and not 'update from 0.7.1' because there was in fact no 0.7.1 listing) from my backup. That worked - but I'd lost the address book. Which wasn't a big deal - because the address book (it's not global) in the 0.4.2 was still there, and mostly similar. So on the grounds of 'if it's not totally bust, don't bust it more', I kept the updated install, and exported/ imported the address book from the 0.4.2.
Suffice - no doubt after far too many words  :-[ - to say, it appears that now both installs are working and on the same release. My thanks again  :D.
---
The Idiot

Offline SKaero

  • Administrator
  • Hero Member
  • *****
  • Posts: 5,881
    • SKaero - Custom Roundcube development
Re: Version update - my poor understanding
« Reply #3 on: April 03, 2013, 10:54:34 PM »
The address book problem most likely was because the user record changed in the accounts table in the database. You can go into the accounts table and change the account record to get back all of the contacts.