Dropbox Backup 2.0

dropboxDropbox Backup is a Plesk extension that extends the built-in Backup Manager and allows you to use Dropbox storage. Read more about the extension in the previous post.

A new version of the extension was recently released. It is available in the Extensions Catalog. In this post, I would like to announce new features implemented in this version. All of them are based on the feedback collected from the blog and the forum. Please continue providing your ideas.

The extension is compatible with Plesk since version 11.5 on both Linux and Windows platforms.

Server-Wide Backup

The server admin can back up the entire server to Dropbox. All features from domain backup are available for server-wide usage.

dropbox-screenshot-1

dropbox-screenshot-2

Ability to Import Backup

Plesk 12.0 has introduced an amazing feature for restoration of specific objects from a backup. Learn more about “granular restore”.

In order to support this ability in the extension, we added a button for importing to your local repository. The backup will be copied from Dropbox and you can find it in Plesk Backup Manager.

dropbox-screenshot-3

Windows Support

All of the Linux features are available on the Windows platform now.

Localization Support

English locale is placed to plib/resources/locales/en-US.php. You can translate all locale entries in a new file, for example plib/resources/locales/de-DE.php. The extension uses the same locale as Plesk.

Minor Fixes and Improvements

  • Filtering files by the x-tar mime-type. I guess other files are useless in the backup repository.
  • “Zebra-striping” in versions list. It makes buttons clicking a bit simpler and prevents mistakes.
  • Fixing internal error on domains list (sorting and paging): “Unable to load list data”.
  • Adding domain names into the page title. You will not mix up your domains.
  • Adding current time as a default setting for scheduled backup. You will be sure in the timezone of your server.

Known Problems and Limitations

  • Dropbox authentication does not work in frames. If you use the Service Provider view in Plesk, the extension’s repository cannot be opened. As a workaround you can open the extension’s link in a new browser tab or use the Power User view.
Showing 67 comments
  • Henry
    Reply

    Hello,
    May i import a backup from one server to another ?
    Thanks.

    • Eugene Kazakov
      Reply

      Hello,

      Unfortunately, no.
      You will get an error: Global server security settings prohibits restore from unsigned or modified backups. You can not restore from it, except your service provider explicitly allow it.
      There is no ability to ignore invalid backup sign neither in 11.5 nor in 12.0 Plesk API.
      You may manually upload backup file to the backup manager.

      • Chris
        Reply

        This may have changed since the original reply, but IT APPEARS you can restore from another server. Download your backup file from DropBox and upload it to /usr/local/psa/var/modules/dropbox-backup. Log in to your server and run: /usr/local/psa/bin/pleskrestore –restore ‘/usr/local/psa/var/modules/dropbox-backup/’ -ignore-sign -level domains -filter list:.

        I just did this for a domain I was running WHMCS on and it *seems* to be OK. Certain elements on the admin page (WHMCS News Feed, Income Overview and Orders Overview) are sitting there “Loading” but I’m not sure just yet if that’s related to the restore.

        • jibran
          Reply

          Hey, thanks for the info Chris, but I’m getting an error. Any ideas? I’m running CentOS 7.2 / Plesk 12.5.

          # /usr/local/psa/bin/pleskrestore –restore ‘/usr/local/psa/var/modules/dropbox-backup/’ -ignore-sign -level domains -filter list:example.com
          ‘–restore’ is not a command

  • Markus Eyrich
    Reply

    I personally would like to see a Google Drive Extension and i believe this is used more than dropbox at all. You guys got google apps integration, drive and other google services are the next logical step if you ask me.

  • Roderic
    Reply

    If only this extension would allow weekly or bi-weekly backups. Making a backup of a 3gb website on a daily basis is a bit much. Also puts a strain on the bandwith.

    • jamie
      Reply

      +1 to customised scheduling

      • Eugene Kazakov
        Reply

        You can customize it from Plesk:
        go to Tools&Settings (Server tab) > Scheduled Tasks > root user
        find your task like:/opt/psa/admin/plib/modules/dropbox-backup/scripts/plesk-scheduler.php ‘2’
        where ‘2’ is domain id or ‘0’ in case server backup
        fix the schedule you’d like

  • Dylan
    Reply

    I’m experiencing a lot of failed backups on individual domains recently – mostly “select/poll returned error”. What could be the cause of this?

    • Eugene Kazakov
      Reply

      Something is going wrong with Dropbox API, it seems not reliable.
      I will find out whether there is anything could be done from the Plesk side.

  • Rein
    Reply

    Great extension! But i have a problem. I have multiple domain where i want to make scheduled backups for to the same dropbox account. But when i log in to one the domain owners and click on dropbox they can see the backups from all the other domain. Is it possible to hide the exension completely for non admin users?

    • Eugene Kazakov
      Reply

      Hi Rein,

      May be server-wide backup is suitable for you, isn’t it? Non admin users would be able to setup there own backup storage, and you will have backups of all domains.
      I can suggest you some custom fix for the problem, but it will be overwritten by next extension upgrade.

  • Rein
    Reply

    I’ve tried a server-wide backup but then i got an error after a couple of hours. I think because it’s to big (full server is around 11 gb). A custom fix would be great, but i’ve you tell me te view lines that have to be changed i can do that myself when there is an update. But on plesk there is just no simple option to hide the extension for non-admin users?

  • Adam
    Reply

    Does this backup the users databases as well?

  • Nico
    Reply

    As the plugin fails to work I wanted to do a removal and reinstall. However when I want to remove I get this error:
    Unable to remove the Dropbox Backup extension: Executing /usr/local/psa/admin/plib/modules/dropbox-backup/scripts/pre-uninstall.php failed: Object not found: 0x0824…………………

    Any idea on how to fix this?

    • Eugene Kazakov
      Reply

      The error is caused by missing scheduled task for daily backup. Try to enable/disable it in the extension’s settings tab.

      • Nico
        Reply

        Hi Eugene,

        Thanks for the reply. However that did not solve it.

    • Eugene Kazakov
      Reply

      The following query will remove the task from the database:
      # plesk db “delete from ModuleSettings where name = ‘managerTaskId'”
      After that I suggest to manually remove all tasks with “dropbox-backup” from the crontab:
      # crontab -e -u root

      • Nico
        Reply

        Thanks a lot

  • Jason
    Reply

    I’ve been using this extension for months and it’s great. However, my Plesk 12.0.8 updated to Update 31 last week and since then the Dropbox backups alway fail with the following error:

    Failed to Execute: ‘/usr/local/psa/bin/pleskbackup’ domains-id –output-file=’/usr/local/psa/var/modules/dropbox-backup/backup.tar’ 15 2>&1
    Output: Runtime error: Unknown error from pmmcli

    It was working fine until the #31 update.

    Any ideas?

    • Tom Kolodotschko
      Reply

      Hey Jason.

      I am also getting this error.

    • Mauro
      Reply

      Hi, I’ve same error on some of domain of my plesk account, for example:

      Failed to Execute: ‘/usr/local/psa/bin/pleskbackup’ domains-id –output-file=’/usr/local/psa/var/modules/dropbox-backup/katodo.com.tar’ 2 2>&1 Output: Runtime error: Unknown error from pmmcli

      Have you any idea about a possible solution?

  • Lynn Kasdorf
    Reply

    I had to re-image my server (plesk v. 12.0.18) and now I’m trying restore backups that were created with dropbox backup.
    Whenever I try to restore or import a backup, I always get a failure: “Unable to import file as dump. The file you are trying to upload is not a valid backup file”.
    However, I am able to restore the backup if I download it locally, then upload in the backup manager.
    When I try the “import” option from dropbox backup, I get a slightly different failure: “Failed to import backup with code 1023”.
    The usr partion is 36gb so space is not an issue. The backup that I restored was 9.5 mb, and I was able to easily download and upload into backup manager to restore. It would not restore directly through dropbox-backup.
    Any idea what might be going wrong here?

  • Tom Kolodotschko
    Reply

    Hey Eugene,

    Great work with this. Its exactly what I have been waiting for.

    A little quirk that I have noticed. To get a full server backup running from the Server Admin Panel I had to click on Server Repository in just a single domain. This has now enable it in the SAP view. For some reason I wasn’t able to click the “Server Repository” button.

    Keep up the great work!

    Tom

  • leon
    Reply

    Does this do incremental backups does anybody know ? thanks

  • Guillermo
    Reply

    Hello, thank you very much for this great Dropbox extension.

    I have a issue in my server. It has a backup job that I run and then canceled by killing the processes. The problem is after that backup job it still appears in the task list and does not leave. I have done “plesk db “delete from ModuleSettings where name = ‘managerTaskId'” (deleted 1 row) an reboot server but the task still remains at task list.

    Can you bring some help to solve this please?

    Thank’s in advance, and keep up this great job!

    • Guillermo
      Reply

      Hi!

      I think I solved this issue:

      I edited sqlite database (I have made a copy before):
      /opt/psa/var/modules/dropbox-backup/dropbox-backup.sqlite3

      Then deleted a row from “tasks” table. I found the right record by timestamp field. Also I decremented by one ‘seq’ value for “tasks” name in “sqlite_sequence” table as I have supposed it’s the task counter value for the extension.

      I hope I have not broken anything with it and can serve as a solution to other users until the extension is updated and it resolved things by itself.

      Regards

  • Guillermo
    Reply

    Another thing that would be great is that backups can be scheduled weekly rather than daily, because for heavy weighs domains, copy them every day is too much (I have 2 that exceed 30GB). And to be perfect, do this within an interface where appear weekly scheduler for all domains.

    I’ve solved this by changing the root crontab tasks to run only one day. The problem is that after editing crontab, synchronization with the extension is lost and reprogramming from plesk create a new task instead of modifying the one already assigned. But at least it is better than nothing and I can use the extension to automate heavy domains backups.

    Is just a suggestion intended to contribute with ideas to improve your fantastic work.

    Bye!

    • Eugene Kazakov
      Reply

      Hello Guillermo,
      Thanks for sharing your experience!
      That’s great suggestion, we should definitely improve scheduling with different periods!

  • Andrew
    Reply

    Before installing this extension I’d like to find out if it possible to continue using the existing back-up provided with Plesk alongside or if the Dropbox extension completely overrides this? Ideally it would be useful to keep a local back-ups of a domain, but then also keep a weekly on Dropbox.

    If so is scheduling independent of the Plesk Back-up?

    Any help/insight from those using the extension would be really useful before I deploy onto a live server.

    • Eugene Kazakov
      Reply

      Yes, you can schedule Plesk’s backup and Dropbox independently.
      Unfortunately, there is no ‘weekly’ period for Dropbox backup, but we’re going to implement it in further versions.
      Also you can follow the advice above by Guillermo.

  • Bernardo
    Reply

    Hello there…just installed version 2.1 on three different servers I have that run Plesk and I’m having the identical issue on all of them. On all I was able to do an initial backup for a domain. I then scheduled it to happen once a day, and on all three of them it did just fine and backed up. Now, however, the backups all stopped, and they all say “Failed (Internal Server Error).” It seems to be that the backup is taking place, the TAR file is being created, but it fails at the end of uploading the file (or attempting to upload the file) to Dropbox. When I look at the log on all three machines, I get the same error, which looks something like: 2015-04-30T11:38:49-04:00 DEBUG (7): Internal Server Error.

    Now, even when I delete the backups on Dropbox, or I uninstall and reinstall the extension, it does not do a backup…no matter what I do.

    Is there a better log I can look at that will tell me what kind of error might be getting generated by the Dropbox API? The regular log file is too generic, stating only “Internal Server Error”, which is not very useful.

    Is anyone else also having these types of errors?

  • RM
    Reply

    Hi, I accidentally deleted the scheduled task that the extension creates automatically (not the scheduled backups task, but the “general” one…).
    Obviously the extension is not working neither i’m able to reinstall it.
    Could you please tell me what the line was?
    Thanks

    • Eugene Kazakov
      Reply

      Command:
      /usr/local/psa/admin/bin/php -c ‘/usr/local/psa/admin/conf/php.ini’ -dauto_prepend_file=sdk.php ‘/usr/local/psa/admin/plib/modules/dropbox-backup/scripts/plesk-task-manager.php’

  • RM
    Reply

    Thank you very much: so we have two scheduled task, not just one!
    Could you please tell me also the cron rules (eg. every day, every half an hour…)?
    I do really do appreciate your support!
    Thank you

    • Eugene Kazakov
      Reply

      The “general” task is that one. It should be executed every minute (five asterisks in crontab).
      Other tasks are scheduled backups (with plesk-scheduler.php script).

  • Peter
    Reply

    This is great – thanks for making it.
    I’d love to see an option for custom names or auto-adding a date after before the .tar suffix. This would ensure previous backups aren’t overwritten.

  • RM
    Reply

    Hi Eugene,
    thanks for replying: i added the “general” task, but backups are not been proccessed anyway.
    I therefore tried to delete and reinstall the extension, but i’m getting following error:

    Unable to remove the Dropbox Backup extension: Executing /usr/local/psa/admin/plib/modules/dropbox-backup/scripts/pre-uninstall.php failed: Object not found: 0x0824565174442989322c4c6a6d6fff45

    Any ideas?
    THanks

    • Karel
      Reply

      I have the same problem, the backups are not made, i cant uninstall with the same error,
      have some solution?

  • Peter
    Reply

    Think I’ve found a security hole with this DropBox extension.

    I gave a client CP access to their own webspace. It’s a pretty limited Role with basic functionality but they can still see the Dropbox Backup link on the right hand of the page. That’s acceptable enough BUT clicking on this brings up a complete list of other backups across my whole VPS.

    From here, they can obviously restore other webspaces and backup spaces they should not have access too.
    Would you look into locking down Dropbox backups on a per-webspace basis only?

    • Peter
      Reply

      Hi Eugene

      Any plans to address this? It means we can’t use the extension when a customer has access to their own web space 🙁

      Many thanks

        • Juanca
          Reply

          Hi…

          Is necesary to do something especial to activate these changes besides copy files to folders indicated on GitHub?. Any Role with access in the CP to the “Websites and domains” tab continue watching the DropBox button.

          Thks.

          • Juanca

            Hi… the github code solved the access problem. (to Plesk 12.0.18)

            Thks a lot,
            Juanca

  • Bryony
    Reply

    My dropbox backups stopped and now have a list of ‘Planned’ backups for about two weeks on each of the domains. I don’t know why they stopped but I did a plesk update and the first ‘Planned’ one now says ‘Running…’ but it doesn’t seem to be doing anything. How can I reset these or remove them and get the backups running again?

    I have other important crons running on my server so I don’t want to wipe these. Thanks

    • Eugene Kazakov
      Reply

      To drop all planing tasks run: sqlite3 /usr/local/psa/var/modules/dropbox-backup/dropbox-backup.sqlite3 “select * from Tasks where status = 0”
      To kill running task find the process: ps aux | grep dropbox-backup
      You should have 2 processes:
      plesk-task-manager.php – it is master process, it is waiting for worker process.
      plesk-backup.php – it is worker, it could execute plesk CLI utilities.
      Kill the worker process with SIGTERM

      • Bryony
        Reply

        Thank you for your reply. I haven’t managed to drop the tasks, only view them.

        I managed to show the processes. This is what I have in there.

        [[email protected] dropbox-backup]# ps aux | grep dropbox-backup
        root 1100 0.0 0.0 103252 804 pts/0 S+ 02:40 0:00 grep dropbox-backup
        root 27087 0.0 0.5 352952 25924 ? Ss Aug13 0:00 /usr/bin/sw-engine -c /usr/local/psa/admin/conf/php.ini -c /usr/local/psa/admin/conf/php.ini -dauto_prepend_file=sdk.php /usr/local/psa/admin/plib/modules/dropbox-backup/scripts/plesk-task-manager.php
        root 27094 0.0 1.2 396388 60308 ? S Aug13 1:26 /usr/bin/sw-engine -c /usr/local/psa/admin/conf/php.ini -c /usr/local/psa/admin/conf/php.ini -dauto_prepend_file=sdk.php /usr/local/psa/admin/plib/modules/dropbox-backup/scripts/plesk-backup.php 67
        root 31902 0.0 0.0 114560 1740 pts/0 T 02:32 0:00 sqlite3 dropbox-backup.sqlite3

        I also don’t know how to ‘Kill the worker process with SIGTERM’

        • Eugene Kazakov
          Reply

          Run: kill -15 27094

          • Bryony

            Thank you, backups are running again but still not sure why they stopped but at least I am able to control it if it happens again. Thank you

  • Michael
    Reply

    Hello,

    we like to set the backup job to weekly or monthly, not every day. but the user cannot set it.

    we see only /opt/psa/admin/bin/php -c ‘/opt/psa/admin/conf/php.ini’ -dauto_prepend_file=sdk.php ‘/opt/psa/admin/plib/modules/dropbox-backup/scripts/plesk-task-manager.php’
    in the task list.

    how can we do this?

    thanx

  • Mark
    Reply

    Great module. I want to use this instead of the normal Plesk backup. But can you please add the Maximum number of backups in the repository option? Backups are more than 5 gb and my Dropbox space is going down rapidly.

    Thanks!

  • Javier Ocampos
    Reply

    First of all I apologize because English is not my native language.

    I am using Plesk 12.0.18 in CentOS 6.7, the plugin version is 2.2 and now, when you make a backup of the entire server I get the following error:

    Failed to Execute: ‘/ usr / local / psa / bin / pleskbackup’ server –output-file = ‘/ usr / local / psa / var / modules / dropbox-backup / server.u17367212.onlinehome-server.com.tar ‘2> & 1 Output: Runtime error: Runtime errror from pmmcli

    This error does not occur when I perform backups for domain by domain, that’s how I’m doing right now. I need to schedule them to be done automatically and daily backup is excessive, I’ve read the comments and seen how to make are made weekly but future versions would not hurt to do it from the same control panel of the extension, like solve the problem with frames, even to schedule backups from the list of backups Plesk with FTP repository option, that way I feel would be more integrated with Plesk.

    Anyway I congratulate you and thank you for the great work they have done with this plugin, you can use my Dropbox account to support my work is a great help.

  • Tomaž
    Reply

    This extension uses /opt/psa/admin/conf/php.ini for processing this dropbox backup:

    max_execution_time = 600
    max_input_time = 600
    memory_limit = 256M

    So in my case if the backup does not finish in 10 minutes or consumes more than 256M memory it will fail.

  • Brandmeir Gerhard
    Reply

    Hello

    i have a Problem with Version 2.2

    Failed to Execute: ‘/opt/psa/bin/pleskbackup’ domains-id –output-file=’/opt/psa/var/modules/dropbox-backup/a-mf.de.tar’ 120 2>&1
    Output: Runtime error: Invalid task id

    What happend, what can i do ?

    • Mike Fallows
      Reply

      I’m also having the same issue:

      Failed to Execute: ‘/usr/local/psa/bin/pleskbackup’ domains-id –output-file=’/usr/local/psa/var/modules/dropbox-backup/abc.com.tar’ 17 2>&1
      Output: Runtime error: Invalid task id

      • Mike Fallows
        Reply

        ps. this is after updating from Plesk 12.0 to 12.5 (still using Dropbox Backup 2.2)

  • Juanca
    Reply

    Hi…

    Would be possible to add a password (only to administrator level) to the generated .tar backup to protect the possibility that other VPS users can access the contents of the copy if this is downloaded?. This password always would be applied in a manual backup.

  • Nico
    Reply

    Hiya,
    I have recently Plesk 12.5
    When i try to restore it says: file is corrupt or Plesk is newer.
    What can i do?

  • Tony
    Reply

    Hi all, i have Plesk 12.5 and DropBox Backup 2.2 on Debian 7.9…i planned server backup (36 GB) but i see:

    Backup of the server Planned 2016-02-07 22:00:02
    Backup of the server Planned 2016-02-06 22:00:02
    Backup of the server Planned 2016-02-05 22:00:02
    Backup of the server Done 2016-02-05 11:47:01
    Backup of the server Planned 2016-02-05 08:21:41

    Any ideas?
    Ty

  • Betty
    Reply

    Check out Backup & Restore Dropbox plugin on WordPress for backing up your Dropbox files and for restoring your lost data. It has unlimited storage and it is easy to use.
    https://wordpress.org/plugins/dropbox-backup/

  • Andrea
    Reply

    I need to schedule the backup weekly and monthly

    How to do? Thanks

  • Matthew Carleton
    Reply

    Does anyone know if you need to make a copy of the backup on plesk first? I have very little space left on my server and making a copy will exceed the space available. I’m trying to figure out if this extension makes a copy directly on dropbox or not?

    • Andreas
      Reply

      I am just guessing that it first creates the backup locally and then upload so you must have at least the compressed size available.

  • Andreas Vitouladitis
    Reply

    The extension works perfect on Onyx & Cent OS 7 for me, missing weekly schedule , you can only setup daily backup, also the extension is accessed by customers and resellers using the same account as the admin’s and displays the server repository backups with the ability to restore by the final client. am I missing something ? is it only intended for use by a single domain installation and “must not be used” on plesk web host edition.

    Regards

  • Alexander Garzon
    Reply

    Bug found:

    Function collides with the official phpPgAdmin, trying to open the phpPgAdmin (https://xxx.xxx:8443/domains/databases/phpPgAdmin/index.php?action=pleskLogin) , shows:

    ERROR: Cannot redeclare value() (previously declared in /usr/local/psa/admin/plib/modules/dropbox-backup/vendor/tightenco/collect/src/Illuminate/Support/helpers.php:26) (decorator.inc.php:72)

    Confirmed in Onyx and Centos 6 and Centos 7

Leave a Comment