We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 2954
    • 40 Posts
    Hi,

    I ran your latest version of modbak and had the following problems:

    The instructions say that you need to update $modx_backup_dir in download.php in one place and settings.php in another. But this line also needs to be updated in the modbak.module.tpl before being copied and pasted into MODx.

    $modx_backup_dir = $_SERVER[’DOCUMENT_ROOT’].’/_backup/’;

    When I ran the module, I got the "Please wait until MODx finishes loading this page..." message, which never went away, so I just clicked "Generate Database." I then got this error:

    Error while inserting event log into database.

    Any help?
      • 14050
      • 788 Posts
      Check your backup directory. The backup was likely successful, it just wasn’t inserted into the System Log.
        Jesse R.
        Consider trying something new and extraordinary.
        Illinois Wine

        Have you considered donating to MODx lately?
        Donate now. Every contribution helps.
        • 12637
        • 26 Posts
        Hi,
        I just backed up the data and got a .zip and a .sql file. The question now is how to restore the backup. I am shifting from local server to live server, and the database and user names are different. Does the method described earlier work in these circumstances?
        Or is there a different route to do this? I hope the different route is not having to do a manual move...:(
        Any help will be much appreciated.
        Thanks
        icubyx
          • 7455
          • 2,204 Posts
          you still need to copy the files from the zip change your login credentials for the database in the config.inc.php. then open the sql in programmers notepad or any other editor that does not mess with the file encoding then replace the server adress and paths to the new server adress (search and replace).
          the import the sql file into your database using phpmyadmin or similar tool. then go to the site see if it works if you get a blank screen or error go to the manager and refresh your site (clear cache) that should do the trick.

          Dimmy
            follow me on twitter: @dimmy01
            • 12637
            • 26 Posts
            Hi Dimmy,
            Thanks. I am trying it right now. Another question. I do not wish to have all the language translations. Can I safely delete the PHP, JS files associated with those languages before uploading?
            icubyx
              • 12637
              • 26 Posts
              Got the answer to my last question. Other language files can be safely deleted...
                • 12637
                • 26 Posts
                Hi,
                I uploaded the files and imported the .sql file into the database after making the changes but I get the following error when I try the address http://sapling.in/index.php:
                « MODx Parse Error »
                MODx encountered the following error while attempting to parse the requested resource:
                « PHP Parse Error »
                 
                PHP error debug
                  Error: 	mysql_connect() [function.mysql-connect]: Access denied for user 'root'@'localhost' (using password: NO)	 
                  Error type/ Nr.: 	Warning - 2	 
                  File: 	/home/sapling/public_html/manager/includes/extenders/dbapi.mysql.class.inc.php	 
                  Line: 	87	 
                  Line 87 source: 	if (!$this->conn = ($persist ? mysql_pconnect($host, $uid, $pwd) : mysql_connect($host, $uid, $pwd, true))) { 	 
                 
                Parser timing
                  MySQL: 	0.0000 s	(0 Requests)
                  PHP: 	0.0525 s	 
                  Total: 	0.0525 s	 
                Error while inserting event log into database.

                I don’t find the entry to user ’root@localhost’ for the database in the config.inc.php to change it...
                Any idea what’s going wrong?
                Thanks
                  • 7455
                  • 2,204 Posts
                  another thing that helps is to run the installer select update unselect all snippets etc and then update.

                  Dimmy

                    follow me on twitter: @dimmy01
                    • 12637
                    • 26 Posts
                    That works. Thanks!
                    icubyx
                      • 29525
                      • 388 Posts
                      Hi all

                      I’m receiving the memory error referenced in this discussion.

                      Fatal error: Allowed memory size of 12582912 bytes exhausted (tried to allocate 32768 bytes) in /home/terrybar/public_html/JohnD/assets/modules/modbak/pclzip.lib.php on line 2217


                      I truncated the the event log and manager log in the SQL DB and reran Modbak but I still get the same error. I logged out of the server and MODx and tried again. No effect.

                      I’ve never dealt with SQL before, but based on the size of my site (only about 8 pages) and the totals from the DB structure view in cPanel. I can’t imagine the DB is too big.

                      Table Action Records Type Collation Size Overhead
                      43 table(s) Sum 479 MyISAM latin1_swedish_ci 552.6 KiB 66.8 KiB

                      Any ideas?

                      Thank you! Terry
                        www.terrybarthdesign.com