XF2 [8WR] Database Backup

XF2 [8WR] Database Backup [Paid] 2.1.0.8

No permission to buy ($10.00)
Hey all..I've done this before and for some reason cannot remember how the heck I did it. I want to restore a backup, so that I have a test server to utilize before doing things in my production server.

However, I cannot get the backups to decompress (I am on a MAC - don't judge :)) and I am not even sure where you would place or what shh commands you'd run to import the backup databases contents into the fresh database.

I know this is really base and as an operator I should know this...I've done something like this with an import before but just cant wrap my head around it at the moment.

Can anyone offer any insight or assistance? Thanks if so!
 
If you know how to access your phpmyadmin, just import it by selecting the database file and click import
 
I sometimes (not always) get the following error log:

GuzzleHttp\Exception\ConnectException: cURL error 6: Could not resolve host: www.myforumdomain.com (see http://curl.haxx.se/libcurl/c/libcurl-errors.html) src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php:185

#0 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php(149): GuzzleHttp\Handler\CurlFactory::createRejection(Object(GuzzleHttp\Handler\EasyHandle), Array)
#1 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/CurlFactory.php(102): GuzzleHttp\Handler\CurlFactory::finishError(Object(GuzzleHttp\Handler\CurlHandler), Object(GuzzleHttp\Handler\EasyHandle), Object(GuzzleHttp\Handler\CurlFactory))
#2 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/CurlHandler.php(43): GuzzleHttp\Handler\CurlFactory::finish(Object(GuzzleHttp\Handler\CurlHandler), Object(GuzzleHttp\Handler\EasyHandle), Object(GuzzleHttp\Handler\CurlFactory))
#3 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php(28): GuzzleHttp\Handler\CurlHandler->__invoke(Object(GuzzleHttp\Psr7\Request), Array)
#4 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Handler/Proxy.php(51): GuzzleHttp\Handler\Proxy::GuzzleHttp\Handler\{closure}(Object(GuzzleHttp\Psr7\Request), Array)
#5 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/PrepareBodyMiddleware.php(37): GuzzleHttp\Handler\Proxy::GuzzleHttp\Handler\{closure}(Object(GuzzleHttp\Psr7\Request), Array)
#6 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Middleware.php(30): GuzzleHttp\PrepareBodyMiddleware->__invoke(Object(GuzzleHttp\Psr7\Request), Array)
#7 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/RedirectMiddleware.php(54): GuzzleHttp\Middleware::GuzzleHttp\{closure}(Object(GuzzleHttp\Psr7\Request), Array)
#8 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Middleware.php(60): GuzzleHttp\RedirectMiddleware->__invoke(Object(GuzzleHttp\Psr7\Request), Array)
#9 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/HandlerStack.php(67): GuzzleHttp\Middleware::GuzzleHttp\{closure}(Object(GuzzleHttp\Psr7\Request), Array)
#10 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Client.php(277): GuzzleHttp\HandlerStack->__invoke(Object(GuzzleHttp\Psr7\Request), Array)
#11 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Client.php(125): GuzzleHttp\Client->transfer(Object(GuzzleHttp\Psr7\Request), Array)
#12 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Client.php(131): GuzzleHttp\Client->requestAsync('get', Object(GuzzleHttp\Psr7\Uri), Array)
#13 src/addons/EWR/Backup/vendor/guzzlehttp/guzzle/src/Client.php(89): GuzzleHttp\Client->request('get', 'https://www.myf...', Array)
#14 src/addons/ThemeHouse/Core/Http/HttpClient/20181220.php(12): GuzzleHttp\Client->__call('get', Array)
#15 src/addons/ThemeHouse/XLink/RemoteHandler/Traits/APICall.php(64): ThemeHouse\Core\Http\HttpClient->simpleGet('https://www.myf...', Array)
#16 src/addons/ThemeHouse/XPress/RemoteHandler/Entity.php(107): ThemeHouse\XPress\RemoteHandler\Entity->callAPI('/wp/v2/posts', Array)
#17 src/addons/ThemeHouse/XPress/RemoteHandler/Entity.php(77): ThemeHouse\XPress\RemoteHandler\Entity->loadPosts(Object(XF\Mvc\Entity\ArrayCollection))
#18 src/addons/ThemeHouse/XPress/RemoteHandler/Entity.php(65): ThemeHouse\XPress\RemoteHandler\Entity->loadRemoteEntities(Object(XF\Mvc\Entity\ArrayCollection))
#19 src/addons/ThemeHouse/XLink/Entity/EntityLink.php(94): ThemeHouse\XPress\RemoteHandler\Entity->getRemoteEntity()
#20 src/XF/Mvc/Entity/Entity.php(148): ThemeHouse\XLink\Entity\EntityLink->getRemoteEntity()
#21 src/XF/Mvc/Entity/Entity.php(106): XF\Mvc\Entity\Entity->get('RemoteEntity')
#22 internal_data/code_cache/templates/l4/s16/public/thxpress_thread_insert.php(6): XF\Mvc\Entity\Entity->offsetGet('RemoteEntity')
#23 src/XF/Template/Templater.php(1315): XF\Template\Templater->{closure}(Object(ThemeHouse\XLink\XF\Template\Templater), Array)
#24 src/XF/Template/Templater.php(1388): XF\Template\Templater->renderTemplate('thxpress_thread...', Array)
#25 internal_data/code_cache/templates/l4/s16/public/thread_view.php(207): XF\Template\Templater->includeTemplate('public:thxpress...', Array)
#26 src/XF/Template/Templater.php(1315): XF\Template\Templater->{closure}(Object(ThemeHouse\XLink\XF\Template\Templater), Array)
#27 blog/wp-content/plugins/wp-xpress-plugin/src/templates/comments.php(35): XF\Template\Templater->renderTemplate('thread_view', Array)
#28 blog/wp-includes/comment-template.php(1510): require('/var/www/html...')
#29 blog/wp-content/themes/wp-xpress-theme/single.php(27): comments_template()
#30 blog/wp-includes/template-loader.php(78): include('/var/www/html...')
#31 blog/wp-blog-header.php(19): require_once('/var/www/html...')
#32 blog/index.php(17): require('/var/www/html...')
#33 {main}

Any ideas? Thanks!
 
I have a problem, when i tried to install your addon it crash and i had to delete the files from my server with ftp connection otherwise i could not access my forum

Here is the error message i have after deleting files from the server in admin panel

One or more add-ons currently have actions pending and may be in an inconsistent state. Because of this, some errors may be suppressed and unexpected behavior may occur. If this does not change shortly, please contact the add-on author for guidance.

If i tried tu reupload files on the server, i have a white page on the home page or every other pages saying that the forum is under update

What can i do to fix that issue ?

Thanks
 
Last edited:
[EDIT] Just ran the Cron manually with no errors - so maybe just the first time issue?



I have the same error log postings as @JohnDer with regards to uploading to Dropbox - the files transfer successfully as well

I have add Dropbox keys from my Dropbox app in order to upload backups to my Dropbox account but when it runs from Cron entries, I have an error at the end of process, except that I don't know what this error is, the backup files are uploaded in my Dropbox account. Locally backups works great.

Kunnu\Dropbox\Exceptions\DropboxClientException: {"error_summary": "path/conflict/file/.", "error": {".tag": "path", "reason": {".tag": "conflict", "conflict": {".tag": "file"}}, "upload_session_id": "AAAAAAAAAiQgqMib_xS13Q"}} in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Http/Clients/DropboxGuzzleHttpClient.php at line 59
  1. Kunnu\Dropbox\Http\Clients\DropboxGuzzleHttpClient->send() in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/DropboxClient.php at line 161
  2. Kunnu\Dropbox\DropboxClient->sendRequest() in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php at line 269
  3. Kunnu\Dropbox\Dropbox->sendRequest() in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php at line 936
  4. Kunnu\Dropbox\Dropbox->postToContent() in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php at line 1057
  5. Kunnu\Dropbox\Dropbox->simpleUpload() in src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php at line 784
  6. Kunnu\Dropbox\Dropbox->upload() in src/addons/EWR/Backup/Repository/DropboxDP.php at line 50
  7. EWR\Backup\Repository\DropboxDP->runBackupDP() in src/addons/EWR/Backup/Repository/Backup.php at line 102
  8. EWR\Backup\Repository\Backup->runBackup() in src/addons/EWR/Backup/Cron/Backup.php at line 11
  9. EWR\Backup\Cron\Backup::runBackup()
  10. call_user_func() in src/XF/Admin/Controller/CronEntry.php at line 112
  11. XF\Admin\Controller\CronEntry->actionRun() in src/XF/Mvc/Dispatcher.php at line 321
  12. XF\Mvc\Dispatcher->dispatchClass() in src/XF/Mvc/Dispatcher.php at line 244
  13. XF\Mvc\Dispatcher->dispatchFromMatch() in src/XF/Mvc/Dispatcher.php at line 100
  14. XF\Mvc\Dispatcher->dispatchLoop() in src/XF/Mvc/Dispatcher.php at line 50
  15. XF\Mvc\Dispatcher->run() in src/XF/App.php at line 2178
  16. XF\App->run() in src/XF.php at line 390
  17. XF::runApp() in admin.php at line 13

View attachment 212713
View attachment 212714

My error message:

  • Kunnu\Dropbox\Exceptions\DropboxClientException: {"error_summary": "path/conflict/file/..", "error": {".tag": "path", "reason": {".tag": "conflict", "conflict": {".tag": "file"}}, "upload_session_id": "AAAAAAABbavrqUQ6MrjSvw"}}
  • src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Http/Clients/DropboxGuzzleHttpClient.php:59
  • Generated by: Ravage
  • Jan 12, 2020 at 5:28 PM
Stack trace
#0 src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/DropboxClient.php(161): Kunnu\Dropbox\Http\Clients\DropboxGuzzleHttpClient->send('https://content...', 'POST', '{"runtime":1578...', Array, Array)
#1 src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php(269): Kunnu\Dropbox\DropboxClient->sendRequest(Object(Kunnu\Dropbox\DropboxRequest), NULL)
#2 src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php(936): Kunnu\Dropbox\Dropbox->sendRequest('POST', '/files/upload', 'content', Array, '8Wf8R38qx1IAAAA...', NULL)
#3 src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php(1057): Kunnu\Dropbox\Dropbox->postToContent('/files/upload', Array)
#4 src/addons/EWR/Backup/vendor/kunalvarma05/dropbox-php-sdk/src/Dropbox/Dropbox.php(784): Kunnu\Dropbox\Dropbox->simpleUpload(Object(Kunnu\Dropbox\DropboxFile), '/2020-01-12/_me...', Array)
#5 src/addons/EWR/Backup/Repository/DropboxDP.php(41): Kunnu\Dropbox\Dropbox->upload(Object(Kunnu\Dropbox\DropboxFile), '/2020-01-12/_me...')
#6 src/addons/EWR/Backup/Repository/Backup.php(102): EWR\Backup\Repository\DropboxDP->runBackupDP('/home/ukvacerc/...', '2020-01-12')
#7 src/addons/EWR/Backup/Cron/Backup.php(11): EWR\Backup\Repository\Backup->runBackup()
#8 [internal function]: EWR\Backup\Cron\Backup::runBackup(Array)
#9 src/XF/Admin/Controller/CronEntry.php(112): call_user_func(Array, Array)
#10 src/XF/Mvc/Dispatcher.php(350): XF\Admin\Controller\CronEntry->actionRun(Object(XF\Mvc\ParameterBag))
#11 src/XF/Mvc/Dispatcher.php(261): XF\Mvc\Dispatcher->dispatchClass('XF:CronEntry', 'Run', Object(XF\Mvc\RouteMatch), Object(XF\Admin\Controller\CronEntry), NULL)
#12 src/XF/Mvc/Dispatcher.php(113): XF\Mvc\Dispatcher->dispatchFromMatch(Object(XF\Mvc\RouteMatch), Object(XF\Admin\Controller\CronEntry), NULL)
#13 src/XF/Mvc/Dispatcher.php(55): XF\Mvc\Dispatcher->dispatchLoop(Object(XF\Mvc\RouteMatch))
#14 src/XF/App.php(2184): XF\Mvc\Dispatcher->run()
#15 src/XF.php(391): XF\App->run()
#16 admin.php(13): XF::runApp('XF\\Admin\\App')
#17 {main}
 
Last edited:
Error




  • ErrorException: Fatal Error: Uncaught XF\Db\Exception: Resource temporarily unavailable in /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/Mysqli/Adapter.php:165 Stack trace: #0 /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/Mysqli/Adapter.php(28): XF\Db\Mysqli\Adapter->makeConnection(Array) #1 /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/AbstractAdapter.php(60): XF\Db\Mysqli\Adapter->getConnection() #2 /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/Mysqli/Adapter.php(113): XF\Db\AbstractAdapter->connect() #3 /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/AbstractAdapter.php(516): XF\Db\Mysqli\Adapter->escapeString('options') #4 /home/pctuts/domains/pctuts.be/public_html/src/XF/Db/AbstractAdapter.php(494): XF\Db\AbstractAdapter->quote('options') #5 /home/pctuts/domains/pctuts.be/public_html/src/XF/DataRegistry.php(138): XF\Db\AbstractAdapter->quote(Array) #6 /home/pctuts/domains/pctuts.be/public_html/src/XF/DataRegistry.php(83): XF\DataRegistry->readFromDb(Array, Array) #7 /home/pctuts/domains/pctuts.be/pub
  • src/XF/Db/Mysqli/Adapter.php:165
Stack trace

#0 [internal function]: XF::handleFatalError()
#1 {main}



array(4) {
["url"] => string(48) "/threads/verwijderde-emails-terug-ophalen.16511/"
["referrer"] => bool(false)
["_GET"] => array(0) {
}
["_POST"] => array(0) {
}
}





 
I bought the addon yesterday because I wanted the backups to be downloaded to my synology at home via FTP.

The backup runs as it should but the backup file is completely empty (I am getting 0 KB size file).

Same for me. All database files are created but they're absolutely empty.
1584814323548.png
1584814638893.png
msedge_H6m1BAr8p4.png
1584820239557.png
The ftp user can write files so I don't know why it wouldn't fill them.


Also... The file structure didn't backup at all even though it is ticked.

Edit: Xenforo (v2.1.8 Patch 2) and all addons are up to date. It's a relatively small forum with 70 Users and about 450 posts.
 
Last edited:
@sbj @Jaxel

I have already screenshotted the FTP in the post above but here it is again:
-- Connecting to ...
-- Logged into FTP host as XXXXX_backup...
-- Creating directory /2020-03-21_19-43...
-- Failed to send /www/htdocs/w00fe5a7/forum/internal_data/backups/2020-03-21_19-43/_ftplog.txt...
-- Failed to send /www/htdocs/w00fe5a7/forum/internal_data/backups/2020-03-21_19-43/_metadata.txt...
-- Failed to send /www/htdocs/w00fe5a7/forum/internal_data/backups/2020-03-21_19-43/_mysqllog.txt...
-- Failed to send /www/htdocs/w00fe5a7/forum/internal_data/backups/2020-03-21_19-43/d02ffa48.sql.xz...
-- Failed to send /www/htdocs/w00fe5a7/forum/internal_data/backups/2020-03-21_19-43/index.html...
-- Disconnecting from <MY SECRET FTP SERVER>...
 
Your server may have limitations on ftpput. Contact your admin.

Code:
@ftp_put($ftpsession, $meta['directory'].'/'.basename($filename), $filename, FTP_BINARY)
 
@Jaxel Thanks so far!
I have installed the addon on another host and it works just as intended so I figured it wasn't an issue on my private FTP.

After some googleing I found a solution:
By inserting ftp_pasv($ftpsession, true); at line 30 of the /src/addons/EWR/Backup/Repository/FTP.php I managed to actually get files with content.
(Perhaps a checkbox to enable/disable passive ftp in the addon settings would be cool?)

The problem with the file structure archive not being created was unfortunately not solved by this. Any ideas?
It works on the other forum of mine though.
 
@Jaxel After fixing the first issue I still have the second.
The addon just won't backup the file structure and I can't figure out why.

Any reccomendations?

PS: Now I get a weekly email of a failed file integrity because I altered your addon.
Is there a chance you can include a toggle to en-/disable the FTP passive mode?
 
Purchased and currently trying this out on an XF2.1 test installation before migrating my production site from XF1.5. Both sites are hosted on the same VPS with separate user accounts and URLs.

I'm having an issue where the backup appears to start on time per the schedule in the internal XF cron system. However, when I go to visit the Backup History entry several hours after the job starts, It says the job is in progress and I find only the following entries:
- 00:00:01 - ##### BACKUP STARTING ##### - 00:00:01 - # Closing forum - 00:00:01 - # Database backup starting
The Forum has been closed and the folder for the backup has been created in the file system, but backup is not proceeding. But It seems that the act of viewing the backup entry somehow triggers the job to continue and it then completes successfully. When the job is run manually from AdminCP, it just works as expected. Is there any way to debug and see where this is getting hung up?
- 00:00:01 - ##### BACKUP STARTING ##### - 00:00:01 - # Closing forum - 00:00:01 - # Database backup starting - 00:00:32 - # Database backup completed - 00:00:32 - # Structure backup starting - 00:05:06 - # Structure backup completed - 00:05:06 - # Opening forum - 00:05:06 - ##### BACKUP FINISHING ##### - 00:05:06 - # Uploading to Amazon S3 - 00:06:42 - # Remote upload completed
 
Top Bottom