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

Code Sharing #82

Open
lancefogle opened this issue Jun 19, 2018 · 10 comments
Open

Code Sharing #82

lancefogle opened this issue Jun 19, 2018 · 10 comments

Comments

@lancefogle
Copy link

I am opening this issue simply for a place to begin some code sharing back to your project. I ended up creating a brand new project inspired by this one. I have contributed some code here in the past and, in the spirit of the GPL, I would like to open the door for you to gain from new features and code in our project. That starts with knowing it exists to cherry pick whatever you find useful. Being that it is a complete rewrite, it would be hard to put together pull requests because of some different implementations.

OnyxBackupVM

Some notable features I can think of that are currently not implemented in NAUbackup you may want borrow for your project:

  • Host backups including rotation like other backups
  • VDI backups that are fully configurable to include selecting disks other than just the root (xvda) one
  • Fully configurable logging
  • Completely external configuration with no changes to script/program to operate
  • Works "out of the box" with no configuration for basic backup/rotation with sane defaults
  • Configuration sanitized to prevent possible bugs from unknown or incorrect params in config files
  • No need for password to run backups
  • Slowly migrating to pure XAPI calls for potential remote usability later
  • Configuration options for customizing and enabling/disabling SMTP functionality
  • Handling of orphaned metadata/VM backup files in case a previous one fails
  • Backup size reporting for each VM
  • Backup disk space checking prior to each backup to prevent crashes

Please let me know if you have any questions on anything. Thanks for all your hard work on this project as it is a great contribution that shows just in how many people use it.

@thomasmck
Copy link

Hi @lancefogle,

As example of a backup program which can run from a remote host using pure API calls see: https://github.com/gaborigloi/xs-cbt-backup

I think the disk space check in partiuclar is a good idea and should be fairly simple to cherrypick.

Tom

@lancefogle
Copy link
Author

@thomasmck Thanks! I'll take a look. Should help.

As for the checking the disk space, I think you would be right. There is just a single method/function called get_remaining_space() that is called and then checked to see if it is greater than a user configurable threshold that defaults to 20%. If less than "threshold" backup space remaining, it will log an error and halt further backup.

@NAUbackup
Copy link
Owner

@lancefogel -- I had to think about all this for a while before responding, and am still confused. Is your project intended to be a means to create code in parallel with the intent of providing potential contributions to this project, as a stand-alone and competitive project, or something in between?

Naturally, any open-source code is subject to reuse and spin-offs and other projects are inevitable and in the interest of pushing innovation. I am just trying to do what I feel is best and consistent for the community with the hope and intention of providing support over a reasonably long period of time to those who make use of a particular project.

Thank you.

@lancefogle
Copy link
Author

lancefogle commented Jun 24, 2018 via email

@lancefogle
Copy link
Author

lancefogle commented Jun 24, 2018 via email

@NAUbackup
Copy link
Owner

Hi, Lance. Thanks for your response. My concern is of course that this will inevitably lead to a split in how the different offerings are used and supported. My preference would be a single development, but I completely see your point of the difficulty of merging code that is very different and in your case, employs some newer coding methodologies that were not incorporated into the original. That and the structure is just very different, making merges all the more complicated. That all said, I'm very impressed how you were able to pull this all together so quickly. You're of course spot on that I have way less time to invest into development these days and have to think about how long-term support should be done, keeping again the community in mind.

We have out own internal version of some of this which we don't release because much of it is not really relevant to the community as a whole. Keeping things generic can be a bit of a challenge.

Maybe the longer-term goal could be some sort of merged project -- just thinking aloud here. I am certainly not going to be around forever as eventual retirement will kick in at some point and consequently, I have to think about the impact of that at some point over the next few years.

Thanks for your clarification and willingness to contribute so freely in the spirit of the benefit to the community at large.

--Tobias

@lancefogle
Copy link
Author

You mean you don't plan to work until you're 100? Haha I'm happy to try and help anyway I can. Just let me know! If I can put together some fairly easy pull requests I will try to do so.

@NAUbackup
Copy link
Owner

I had thought that at one point, but the direction the whole IT industry is turning is discouraging to me and again, time commitments are getting tougher as duties and responsibilities get shifted around. Thanks again!

@lancefogle
Copy link
Author

@NAUbackup I submitted pull request #84 to add backup space threshold checks to your program. Let me know what you think.

In OnyxBackupVM I just refactored the entire service layer to make it easier to implement some new features. In doing so, I was able to add automatic detection and running of quiesced snapshots for Windows VMs that have the Xen VSS provider installed.

If we can find a simple way to integrate that into VmBackup it would resolve issue #21. I can try to look into it when I have some time.

Side Note: It being automatic isn't a concern because the user can simply not install the Xen VSS provider (a manual step anyways) on any VMs they don't care to have quiesced snapshots of. That being said, it would be kinda silly to not want the disk consistency of a quiesced vs non-quiesced backup for your Windows VMs.

@NAUbackup
Copy link
Owner

Hi, Lance -- looks cool. I have been off a few days working on household remodeling/maintenance projects, but will try to catch up, test out, etc. ASAP. Thank you!

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

3 participants