Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feature request: to trigger backup manually #75

Closed
MeCias opened this issue Feb 14, 2015 · 22 comments
Closed

feature request: to trigger backup manually #75

MeCias opened this issue Feb 14, 2015 · 22 comments
Milestone

Comments

@MeCias
Copy link

MeCias commented Feb 14, 2015

Hi guys,

In situations where you have to update manually (from OC7 to OC 8) it would be great to trigger a backup manually as well.
At the moment - I think - there is just the automatic update for minor updates like 7.0.3 to 7.0.4.

Thanks in advance for considering

Cheers

@rakekniven
Copy link

Fully support feature request.
Would be nice to have something like a backup task with schedule and called by cron.
Next step would be a selection on what to backup:

  • config
  • install
  • themes
  • data
  • ...

@te-online
Copy link
Contributor

@MeCias Well, that shouldn't be magic to add a button that does a backup only. In other words: It's easily possible but needs some lines of code to add an interface for it. I'll see what I can do to add this.

@rakekniven I'm not sure whether further optimization in terms of the backup function may heavily speak for the need to put them into a new app. To create and maintain this new app would of course produce a significant amount of extra work.

Another thing: To backup the core is what happens now in the updater app and could also be made selectable (config, install, themes etc.) in the future (in my opinion). To backup the data folder, I think, we need some more programming logic. Imagine users with terrabytes of data in their owncloud. Probably they don't want this data in one single zip-file (if that's even possible), besides maybe the free space is not big enough to backup all the data. A sophisticated backup-script for the data-part would be great, but also means a lot of planning, thinking and testing (correct me if that's wrong).

Central point is the question how users would like to backup their data. Maybe they like to use rsync to transfer their whole owncloud to another server every hour (which wouldn't need a backup-app at all). But maybe they want to download a zip-file from the interface each week, because they only have 150 mb of data. Maybe they want to have another folder on their server where each hour a zip-file of every folder from their owncloud-data is created. Or maybe they want something else.

Problem is that we can only speculate about use-cases. Best way would be to evaluate the backup-question (e.g. with a survey) before starting to add something complex, I think. What do you think?

Maybe @VicDeo wants to say something about the general idea ;-)?

te-online added a commit that referenced this issue Feb 25, 2015
Details:
Adds a button, some messages and the function to do a backup like it would be done when updating.
Fixes the sorting of the list of backups to be ordered by filedate.
@te-online
Copy link
Contributor

I added a button to do a manual backup at any time. This backup is the same backup that would be created on update.
Additionally, backups are now sorted by filedate to have the latest file on top.

bildschirmfoto 2015-02-25 um 22 40 49

I will create a pull request that reflects this change and the changes mentioned in #40 and see what @jancborchardt and @VicDeo think about this. :-)

@MeCias
Copy link
Author

MeCias commented Feb 26, 2015

Hi,

I like it already. Thanks a lot te-online.

@jancborchardt
Copy link
Member

@te-online looks great! :) Only thing is that I would put the »Delete« button to the right of the list, and make the »Sicherung« column aligned left with the rest of the text above (The Sicherungsverzeichnis and the button).

And, as mentioned in the other pull request, better separate the two changes.

@te-online
Copy link
Contributor

@jancborchardt Okay, I see your point.

I intentionally moved the trash-button to the left, because it needs a very long mouse-movement to delete an entry if you're sitting in front of a wide screen.
On the other hand, the 1st important task might be to download the file (»Sicherung«-column) and the 2nd important task is to remove a file.

So what about the trash in between the first two columns? Doesn't sound good, either, does it?
Maybe we should keep it to the right then? :D
Or we could set a max-width...

I'm not sure whether one of the solutions is a good one:

1 bildschirmfoto 2015-02-26 um 16 49 58

2 bildschirmfoto 2015-02-26 um 16 50 35

3 bildschirmfoto 2015-02-26 um 16 51 43

4 bildschirmfoto 2015-02-26 um 16 55 22

@jancborchardt
Copy link
Member

@te-online making the whole table narrower looks good! Also, with ownCloud 8 the admin area has a sidebar on the left, so it will look less strange (less whitespace on the right). :)

@te-online
Copy link
Contributor

@jancborchardt okay, so you prefer number 3 or number 4? I can't decide ;-)
(Besides, personally I think, we are missing some more interface-styleguides in general).

@jancborchardt
Copy link
Member

@te-online definitely number 4. :)

Yeah you’re right, we are missing those. However the general style already looks good by using the proper CSS. And defining a style for these special cases is what we have to do first before we can build a styleguide.

@te-online
Copy link
Contributor

@jancborchardt okay, thanks for your answer :-)
Considering the two given opinions, I will implement the 4th option for now (in the manual-update branch).

@jancborchardt
Copy link
Member

Thank you!

te-online added a commit that referenced this issue Mar 5, 2015
…ussion in #75.

Details:
Adds a max-width for backup list and note-container.
Adds a pointer-cursor to backup list entries.
Changes caption of the backup button.
te-online added a commit that referenced this issue Mar 24, 2015
Set a max width for backups table and note container.
Set the cursor to pointer for the clickable backups entries.
Change the order of the table columns.
@te-online
Copy link
Contributor

@jancborchardt I added the small visual changes into another branch, so that we can merge them while I still want to improve the code quality of the manual backup option.

@jancborchardt
Copy link
Member

@te-online good stuff! :)

VicDeo added a commit that referenced this issue Mar 30, 2015
Make visual changes according to #75.
@enoch85
Copy link
Member

enoch85 commented May 6, 2015

Love this! Any update?

@te-online
Copy link
Contributor

Forgot about that, sorry! Give me a moment for the try of a pull request 😄

@te-online
Copy link
Contributor

Okay, it's all there in the manual-backup branch. But I will need some time to adapt that to the code changes that were made in the meantime. Additionally, my approach is a bit hacky right now – I just copied the methods from the update-mechanism and removed everything I think is not necessary for the backup task.

Give me some days and will have another look at it 😉

@enoch85
Copy link
Member

enoch85 commented May 7, 2015

@te-online 🍻

@te-online
Copy link
Contributor

Wow, a few days became a month now. It was close to be right on top of my todo list multiple times, but I didn't have time to do it, yet. I am very sorry! I will definitely come back to this and it won't take another month. 😉

te-online added a commit that referenced this issue Jun 20, 2015
@te-online
Copy link
Contributor

Well, I did a fix to my previous approach (route disappeared) and it works now.

However, it doesn't work with any of the stable owncloud versions, I think, because updater introduced \OCP\Util::getChannel() which can't be found in the stable releases, when I try.

Note: the feature only backups core and no data or settings!
And again, I like someone to check code quality because I am not quite up-to-date with the coding standards here.

@enoch85 try it out. If you're trying with a stable version and receive
Call to undefined method OCP\Util::getChannel() at /Applications/MAMP/htdocs/ocdev8.1/apps/updater/lib/channel.php#42
just comment out that line. Updates won't work than.

@enoch85
Copy link
Member

enoch85 commented Jun 21, 2015

@te-online Notcied. Don't have a test VM setup now.

@VicDeo
Copy link
Member

VicDeo commented Feb 6, 2016

9.0 only
sudo -u wwwrun php /path/to/owncloud/updater/application.php upgrade:checkpoint --create
to your root crontab

or
php /path/to/owncloud/updater/application.php upgrade:checkpoint --create
to the crontab of the oc files owner

@VicDeo VicDeo added this to the 9.0-current milestone Feb 6, 2016
@VicDeo
Copy link
Member

VicDeo commented Feb 16, 2016

use CLI command sudo -u wwwrun php /path/to/owncloud/updater/application.php upgrade:checkpoint --create
or this button in the Web UI
btn

Closing as done for 9.0

@VicDeo VicDeo closed this as completed Feb 16, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants