We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 28471
    • 48 Posts
    Quote from: edipo at Mar 02, 2006, 03:09 PM

    Hi, I have a stupid question: how I restore the modx backup and the sql database ?
    Thanks to all

    Nothing stupid about that edipo. Restoring is a little more complex.

    File Strcuture:
    With the zip file, you could upload the entire zip file to your webhosts web documents directory (ie public_html, www, etc) if it’s control panel has an extraction option (cpanel’s filemanager does), and just extract the zip file, this will create the necessary directories and files, and than you need to change permissions(CHMOD) of the assets dir and folders/files under it.
    Note though, if the files/folders already exist on the webhost, I think cpanels filemanagers extract stops. So best to delete the old dirs beforehand.

    Or unzip the archive on your local machine, and FTP the files through, however this can take HEAPS longer, (im on cable and its slow, having to upload every file one by one).

    Database:
    If you can use PHPmyadmin or similar database admin on the host, you can use this to upload the database sql file, this will create the database tables.
    Look for SQL or Query option, and somewhere to upload a .sql file, than browse for your local database_backup.sql (you have to extract this from the .zip first)

    Ok, when I have some time soon, I’ll do a more indepth explanation of the procedure.
      • 8471
      • 333 Posts
      Thanks a lot stempy smiley
        Sorry for my bad English grin
        • 2130
        • 5 Posts
        The big move is on the way...

        I am about to move one of my MODx sites to Dreamhost. I just signed up for their Code Monster deal after much research. I have quite a few sites, and theirs seems to offer the most for the money. So I am transferring all sites that I own to Dreamhost and one of them is a MODx site I just completed for a friend (that she LOVES to update by the way - thanks to MODx!).

        One of the things that I read about Dreamhost and MODx is that Dreamhost runs PHP as CGI, which can create problems. The solution (from what I have read) is to make sure the domain with MODx is set to run PHP as a module instead. I am going to do that, but it seems as if Dreamhost is really pushing to run PHP as CGI everywhere I look. (In the Control Panel it says "Highly Recommended" next to "Run PHP as CGI" so I am hoping that sometime in the near future they don’t ’require’ that, and then cause my MODx sites to malfunction. But for now, for the MODx domain, I am going to run PHP as a module. Is it reasonable for me to think Dreamhost could someday ’require’ PGP as CGI or is it safe to say that I will always be able to run PHP as a module? I would hate to transfer all sites to Dreamhost, and build more MODx sites, and then have to move to a different host yet again because something like this changed. (Then again, maybe that’s a silly thought, but I wanted to ask anyway. smiley)

        Also, I have read about how to work on a MODx site in a staging area and then move it to a live server, but is this module also for moving a live site from one server to another live server? I assume all I do is use the module as instructed, save the files locally, and then FTP the unzipped files to the new server, but I wanted to make sure first because I am fairly new to Modx, and I want to make sure I do it right. (Or I will have an angry Criminal Justice Teacher poking me on the shoulder every chance she gets, asking me why she can’t update her web site. Haha.) The MODx site I will be moving is http://www.criminaljusticeteacher.com .

        Thanks in advance for any advice you can give for this move! smiley
          • 32241
          • 1,495 Posts
          I can’t give any advice regarding about how you’re going to move your data and etc, but I use dreamhost, so I know that running php as CGI won’t cause any problem, in fact it makes your life even easier, coz you don’t have to set permission on folders, because of the fact that it’s running under your account, instead of global php account that usually being used by standard php setup. I believe they call this suexec or whatever they named it (I have a bad memory smiley)
            Wendy Novianto
            [font=Verdana]PT DJAMOER Technology Media
            [font=Verdana]Xituz Media
            • 25663 MODX Staff
            • 12,272 Posts
            Great site looking site by the way... smiley
              Ryan Thrash, MODX Co-Founder
              Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
              • 28471
              • 48 Posts
              Quote from: arohner at Mar 14, 2006, 04:31 PM

              Also, I have read about how to work on a MODx site in a staging area and then move it to a live server, but is this module also for moving a live site from one server to another live server? I assume all I do is use the module as instructed, save the files locally, and then FTP the unzipped files to the new server, but I wanted to make sure first because I am fairly new to Modx, and I want to make sure I do it right. (Or I will have an angry Criminal Justice Teacher poking me on the shoulder every chance she gets, asking me why she can’t update her web site. Haha.) The MODx site I will be moving is http://www.criminaljusticeteacher.com .

              If you have the ability to extract archives with subdirectories on your control panel on dreamhost, than all you would need to do is upload the .zip file to the base directory where you want modx. Extract the zip on dreamhost, which should recreate the subdirs, then go into your database manager(ie PHPmyadmin) and use the database_backup.sql file to create and populate the database. Than log into the manager, and change the resource url, (and maybe a few other dirs) to your new directories.

              If you have cpanel, go into the file manager, click on the .zip to bring up the file options, than extract to acheive this.
                • 2130
                • 5 Posts
                Thank you for your replies.

                Wendy, I will go ahead and choose run PHP as CGI since you say that will be better anyway.

                Stempy, I will try what you said, although I am a little shaky when you say ’and maybe a few other directories’ after changing the resource URL because I am not sure at this point what those directories would be, but I guess those will be revealed as I go through the process.

                Thanks for the help guys. I will let you know how the move goes!

                  • 28471
                  • 48 Posts
                  Quote from: arohner at Mar 14, 2006, 10:38 PM

                  Stempy, I will try what you said, although I am a little shaky when you say ’and maybe a few other directories’ after changing the resource URL because I am not sure at this point what those directories would be, but I guess those will be revealed as I go through the process.

                  It should be ok, those directories in the manager are the resource url (where assets dir is), and another one which is used for the file manager, however MODx should still run ok if these directories are not set initially.
                    • 17282
                    • 283 Posts
                    this module rocks stempy ..

                    any thnx smiley

                      Everytime you use Flash ... a puppy dies .....
                      R.G Taylor
                      • 25787
                      • 14 Posts
                      Great module! I ran it successfully on my site. One question: The zip file contains the ’manager’ and ’assets’ directories of the MODx URL (i.e. [mysite]/modx/manager and [mysite]/modx/assets). However, I have my template stuff directly under the ’modx’, so [mysite]/modx/[templatename], and this directory is not included in the zip file. Is there some way to make that happen (or would you recommend not using that structure to begin with)?

                      Thanks
                      Ron