Xibo Migration to new server

Hi Everyone,

Please Help.

My issue that i having is server migration. I’ve been reading some info that i found here about server migration but failed to associate with the setup that i have. I have xibo server running on 1.7.9 version with a windows operating system and xampp. I read that i have to clone the database copy settings.php then restore and copy all in the new server. But unfortunately i can’t get it to work. Please help i’ll provide more info about my configuration if needed

It would be good to know more details about your current and the new server environment.

Do you plan to still use 1.7.9 CMS on a new server or are you considering upgrade to 1.8 series?

What exactly have you done so far and what do you mean by ‘can’t get it to work’ ie what exactly is not working and what do you see on your new server?

Hi Peter,

Okay on my current server i have xibo 1.7.9 running on a windows 7 pro os with xampp with the required version so i was thinking to migrate the whole entire server setup to another server. I have another windows pro machine with xampp and xibo cms already. So back to the old server what i did so far were dumping the current database, copied xibo library and pasted it to the new server and restored mysql database on the new machine and copied settings.php. The problem im having is after i did all of those i can’t get into the login page of xibo cms anymore it keeps on saying http error.

And by the way in regards about 1.8 version. I have plan of upgrading our cms to the latest upgrade i just want to migrate first with the current state then upgrade it to the latest version. I just want to do a procedure without affecting the current state of iur server because honestly it’s under production state already thats why im trying to be careful on all the actions that im doing cause i don’t want to crash the server cause there are 3 person controlling the cms on their daily activities and i have 8 client connected on the server.

Ok for the update.

  1. Copied ( settings.php , old server xibo library, old server dump files ) to the new server.
  2. Installed xibo 1.7.9 and created a blank mysql database on my phpmyadmin page.
  3. Then i did run xibo 1.7.9 installation with existing database pointing it to the new blank mysql database.
  4. copied settings.php on xibocms root folder then went to xibocms settings.
  5. Imported succesfully the mysql dump file that came from the old server and changed the library path similar to the path with the old server where the library was located.
  6. Did logged out then logged back in but nothing was change everything looks new install still.

Am i missing something??
All help will be much appreciated.
Thanks,

I believe all you’d have to do after CMS installation on a new server is to copy over the CMS library, settings.php and the database to your new server, which seems that you’ve done already.

What do you have in CMS Settings -> Configuration tab -> Library Location?
Does that point to the path if your library on the new server?

Did you edit the settings.php to make sure db credentials are correct for the new installation?

I assume you already tried to clear browser cache to make sure it’s not just the cache that’s causing problems?

I have the same path that is pointing to the copied xibo library on my new server.

I didn’t edit settings.php credentials because i made the new server same mysql credentials with the old server

When you say clear browser cache does that mean that i need to clean the browser cache after i did all the configuration to the new server?

And by the way i just noticed that after i imported the old server mysql dump file from xibo cms setting i was redirected and it say import was successful but upon checking on my phpmyadmin mysql database it seem like nothing is changed.

In this case, that’s most likely what’s causing your problem, if Xibo is not using a database created with your db dump file.

Could you perhaps make sure that correct .sql (dump) is in place and that the database on the new server use it as a source now?

and then that this database is definitely set in settings.php as well

ie the second part of this post pretty much Breakdown of how to clone a xibo database using mysql shell - #2 by Peter

CMS library - is it fully qualified path to the library?

Refresh - yes that, sometimes it may be necessary, similar after CMS upgrades.

Hi Peter,
After several attempts still no luck.
Anyway did you ever seen this before?

An error occurred populating the database. Statement number: 57. Error Message = [SQLSTATE[HY000]: General error: 1005 Can’t create table xibo.#sql-ab4_65 (errno: 121 “Duplicate key on write or update”)]. File = [Array]. SQL = [ALTER TABLE blacklist ADD CONSTRAINT blacklist_ibfk_1 FOREIGN KEY (MediaID) REFERENCES media (mediaID), ADD CONSTRAINT blacklist_ibfk_2 FOREIGN KEY (DisplayID) REFERENCES display (displayid)].

probably from there you can figure it out.

I’m pretty sure i have the correct dump file. Cause what i did is i went to the old server then i did run mysqldump command pointing it on the old server database and named it xibodump.sql. Then i copied that file from the old server going to the new server created a new blank database and uploaded the xibodump.sql using the mysql commands.
Everything was ok no error or nothing then i copied my settings.php and edited it with the new server mysql credentials and new database name but everytime i access the xibocms it’t giving me an http error 500 this page isn’t working.
I even tried to clear cache but still no luck.

So the process sounds correct. The error you list looks to me to have come from an installation rather than an upgrade. You’ll need to drop the database from your new server, recreate it, and then load in the backup again to get back to a clean slate.

I presume you’re then looking at an error 500 screen? When you access the new server, you shouldn’t be getting a 500. That’s the first thing you need to address.

Are you certain the filesystem permissions are correct on the library? If so, try manually updating the library path in the database to the new value.

UPDATE setting set value="/fully/qualified/path/to/your/existing/library/" where setting="LIBRARY_LOCATION";

Be sure to give a fully qualified path, and that there’s a trailing slash on the end.

Does that clear the 500 error and show you the login screen? If so, you should then be able to login and start the upgrade process. If you see the installer, then your settings.php file is in the wrong place, or contains the wrong information for the database.

Hey Alex your a genius man! Thank you so much i finally figured it out. I did analyze your instructions and found out that what i was missing changing the library from the phpmyadmin to the fully qualified path. I really do appreciate it man.

Peter you were awesome as well thanks for helping me out.

And by the way is there a guide for upgrading as well cause i’m planning to migrate everything to a new server in a docker environment with the latest version of xibo. And if i will do the instructions of migrating with latest version is it gonna work?

Thank you so much guys you guys are the best

I’m glad that it’s sorted now.

Yes there are upgrading instructions for various installations - http://xibo.org.uk/manual/en/upgrade.html

If you will want to switch to docker on a new server, then of course the ‘Upgrade and Switch to Docker’ would be relevant to you.

On a new server you’d follow the installation instructions for docker on Windows/linux and then, as per upgrading instructions,

Follow that guide, until you get to the step where the CMS is initially bootstrapped. Do not run the docker-compose up command. When you get to that step, please return here, and pickup.

Follow the upgrade and switch to docker instructions.

Once you will have your 1.8.2 on docker, upgrading to newer releases should be fairly straightforward - there are instructions for that as well in the first link in my post.

Peter or Alex

Upgrading xibo should i migrate with the old version 1.7.9 first from the old server to the new server then upgrade it from the new server or i can do it together with migration?

Cause i was doing it together with the migration i successfully got into the upgrade page after i started and finished the upgrade it’s showing me a configuration error Problem copying provided file into the Library Folder i added trailing slash on my settings.php but still same result i cleared cache as well same result. any idea??

And i did see bunch of library archive on my desktop

Never mind guys i did figured it out already :slight_smile:

1 Like