1
chefry
upload to server
  • 2013/4/22 9:54

  • chefry

  • Home away from home

  • Posts: 1005

  • Since: 2006/10/14


I'm ready to upload the new site to the server 2.5.6

I propose the following:
1) upload index.html saying the site is under construction
2) backup & download the old site and copy it to my computer
3) delete the old site
4) do a clean install of the new site specifying the same same mysql name and table prefixes.
5) upload and overwrite all the core files with the new site
6) using phpmyadmin, drop all the tables
7) import the new database
8) check and correct all links
9) remove the "under construction" notice and go live
10) delete the old mysql

what do you think?

2
Mamba
Re: upload to server
  • 2013/4/22 11:56

  • Mamba

  • Moderator

  • Posts: 11251

  • Since: 2004/4/23


Assumptions:

1) you've tested everything locally and it works,
2) your current site is in

/OLD

folder

Then I normally would do following:

- install a new generic XOOPS website in /NEW folder
- copy /upgrade folder to /NEW folder
- copy all the required and tested modules to /NEW/modules (you don't need to install them)
- copy from the /OLD website all custom files, avatars, images etc. from individual modules and from /uploads
- in /xoops_data/data/secure.php change the Database info (location, user name, password, etc) to the old Website's database.
- in mainfile.php change the Domain URL info

- in Admin Preference, turn the current site off
- make a BACKUP of everything, especially the Database
- on the host, redirect the Domain to the /NEW directory.
- go to http://mysite.com/upgrade and run it
- the Website should now work.
- if there any issues (missing images, not updated modules) -> fix them
- turn on the Website for your users

Once tested and working, delete the /OLD folder with all the files, but keep a backup, just in case, especially of the Database. And drop the empty database that you've installed as first with the new fresh installation, before switching to the old database.

What you're basically doing is to install new XOOPS, but then switch to the old database and use it.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

3
mondarse
Re: upload to server
  • 2013/4/22 12:24

  • mondarse

  • Just popping in

  • Posts: 96

  • Since: 2003/2/3 1


In my opinion you are ok, I will only do some recommendations based in my experience:

- Backpup your files to you computer and also, if your host provides any kind of cpanel, "move" your old site to other folder instead of deleting it, so if your new installation gets impossible and you finally get frustrated you can get back you old site on-line by moving deleting new installation, moving back your old files and recovering your old db), so you can give "tomorrow" an other chance.
It is easiest to move folder than wait to ftp upload again your old files. Of course you need enough hard disk space for two site at the host.

- Backup your db twice, you never know what could happen.
As you said use phpmyadmin por db, but also try HeidiSQL for win. If have used this software for 3 years and it is very useful. You only need external (internet) db access to mysql databases.

- When installing new 2.5.6. make sure it works every thing before deleting the db and importing the local one.
Check if XOOPS_VAR_PATH if properly configured, try installing some common modules like news, create some stories.

- Test your theme with your 2.5.6. theme before importing your local db. If there are some errors, it is better to find them with less places to look in.

- After all previous check ok, back up your "fresh 2.5.6 db" before delete it and importing your local 2.5.6. db. If it doesn't work, you can easily go back.

- If complete local 2.5.6. db import doesn't work in the webhost to do it step by step:
- Install and check new fresh 2.5.6. (out of the box).
- Do basic configuration / customization.
- Do a db backup
- Install one module, test it, create dummy content and test.
- Import db tables only for the installed module. (Edit the sql file and copy and paste only the required tables to a new file).
- Test the module, and if every thing is ok, import an other module, and repeat previous "sub-steps".
- If you finally get success importing step by step make a db backup.
- Only one more recommendation, when everything online gets working import your 2.5.6. on-line db in your local computer and test it, if it doesn't work locally your webhost and localhost machine configurations are "critically" different, so you must find the differences and try to set config for both the same, so you can make "experiments / install new modules" in your local machine and then upload them to you webhost and meke them run easily.





4
mondarse
Re: upload to server
  • 2013/4/22 12:28

  • mondarse

  • Just popping in

  • Posts: 96

  • Since: 2003/2/3 1


When I started my post, Mamba post was not posted already.

Mamba explains it better, and both posts can complement the other.

MonDarSE

5
Mamba
Re: upload to server
  • 2013/4/22 12:44

  • Mamba

  • Moderator

  • Posts: 11251

  • Since: 2004/4/23


Quote:
if your host provides any kind of cpanel, "move" your old site to other folder instead of deleting it, so if your new installation gets impossible and you finally get frustrated you can get back you old site on-line by moving deleting new installation, moving back your old files and recovering your old db), so you can give "tomorrow" an other chance.

I prefer a fresh installation in a new location, so I don't carry extra baggage from old installations, since over time you collect a lot of un-needed files.

Then I just need to run few tests and copy any "custom" files to the new locations. Moving files is less desired, because once you overwrite a file, you don't have a clear comparison between both installations.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

6
mondarse
Re: upload to server
  • 2013/4/22 12:52

  • mondarse

  • Just popping in

  • Posts: 96

  • Since: 2003/2/3 1


Quote:

Mamba wrote:

I prefer a fresh installation in a new location, so I don't carry extra baggage from old installations, since over time you collect a lot of un-needed files.

Then I just need to run few tests and copy any "custom" files to the new locations. Moving files is less desired, because once you overwrite a file, you don't have a clear comparison between both installations.


Mamba Maybe I didn't explain my self.
When I say move the old site instead of delete it I mean to put the files in a hidden folder out of web root folder. Something like this:
/httpdocs/(here my old site files)

move them outside root folder:
/old/(here my old site files)

or if you don't have access or permission to that folder something like this:

move all the old file to a new backup folder:
/httpdocs/OLD-backup/(here my old site files)


then as Mamba stated make a fresh clean installation in /httpdocs/



7
Mamba
Re: upload to server
  • 2013/4/22 12:54

  • Mamba

  • Moderator

  • Posts: 11251

  • Since: 2004/4/23


Yes, I misunderstood you. Sorry!
Thanks for clarifying it.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

8
irmtfan
Re: upload to server
  • 2013/4/22 13:51

  • irmtfan

  • Module Developer

  • Posts: 3419

  • Since: 2003/12/7


Nice discussion
for those who have a large website or dont have high speed internet connection, it would be hard to download and upload too many files.
Also installing a new xoops and upgrade it is always harder than upgrade the current one.
I document all my hacks and changes in the running website so i didnt have any extra file to be worry about.
my website is about 5Gigs (files,pictures,downloads, ...) and database is about 1.2Gig so it is not possible for me to download/upload all of it at once.

I wrote this instruction for myself and will follow it especially in large websites for upgrade process:
1- test upgrade in local. more testing is better. test all your running themes, test all running modules and ...
2- close running website. turn php debug on and clear all caches and sessions in admin> system > maintenance(very important)
3- get a backup from old database.
4- disable all modules except protector
5- copy running website files (except /modules /uploads) to domain/BACKUP via Cpanel
6- copy /modules/system and /modules/protector and /modules/pm and /modules/profile to domain/BACKUP via Cpanel
7- copy xoops_data and xoops_lib to backup_data and backup_lib
8- upoload the new Upgrade Core Version* and overwrite domain, xoops_data and xoops_lib
9- go to domain/upgrade **
10- enable modules one by one and fix any issues.
11- turn debug off. open website.

* means the version with upgrade folder and removed mainfile.php and secure.php. I prepared an upgrade version for 2.5.5 persian release.
** if something goes wrong you always can use backups.

9
chefry
Re: upload to server
  • 2013/4/23 11:41

  • chefry

  • Home away from home

  • Posts: 1005

  • Since: 2006/10/14


Thanks for all the advice

One more tweak and I'll be uploading the new site tonight

Fingers Crossed!

10
chefry
Re: upload to server
  • 2013/4/24 10:02

  • chefry

  • Home away from home

  • Posts: 1005

  • Since: 2006/10/14


ok, live and all working without any problems (i hope)

check it out

http://zapenglishclub.com/

Login

Who's Online

74 user(s) are online (33 user(s) are browsing Support Forums)


Members: 0


Guests: 74


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Jul 31
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits