info Xen Orchestra cli cmd
-
Hello,
I'm not sure to understand the use case. Are you actually using the replicated disk on destination? (at least I suppose a copy of it, because if you just boot or use the replicated disk directly, this will change the blocks and corrupt it on next sync).
If this is your use case, it's probably not the right way to do so (rsync would be probably better in that case).
To answer about
xo-cli
, all commands can be displayed viaxo-cli --list-commands
. See https://xen-orchestra.com/docs/architecture.html#xo-cli-cli for more details. -
I use continuous replication on a production VM.
This is done over internet, it is slow.
Local I have this copy of VM, but I want to make a copy of copy.
And if continuous replication is enabled when I made a copy, I get a continuous replication brake chain if it starts when copying is in progress, as you said.
On the xo-cli --list-commands I couldn't find a way to disable this continuous replication and when I finish to enable again.For now I disable the sync on web gui manually , start the copy and then enable again.
And now wat I want is to automate this process because it happens periodically.
And all I missing is the right command line to disable and enable this continuous replication task on XOCE -
So the use case is making a copy of the CR VM? (so you have a backup of the backup?)
-
Yes but in an automatic way not by hand
-
Why not replicating twice to 2 different SR directly in the backup job?
-
I don't think we're on the same page.
The scenario is like this:
The real VM is in another site and has two disks (system and database).
I have a copy of it, with the help of CR, on my site.
From the copy on my site I want to use only one disk (database).
The idea I started from is to make a copy on the whole VM and then use only disk 2.
Only for this copy I need 20 hours + and CR is done every 2 hours.
All I want now is to disable CR job when I make the copy to not break the CR.
And after I finish the copy to enable the CR job.For now, as I said, I'm taking the following steps:
- I disable the CR job
- start copying
- enable the CR job
Everything manual and CR job does not break.
All i want is to find a way through xo-cli to be able to temporarily disable this CR job.
-
What do you mean with:
From the copy on my site I want to use only one disk (database).
What do you mean by "use only one disk"? What "use"? Make another copy but just of this DB disk?
The term "use" is very unclear to me, what do you want to do with it?
-
I hope this is more clear.
I use ssh copy because is more faster that VM copy over XOCE.
Over ssh copy I get 200 Mbps and over XOCE I get max 65 Mbps.
All VM discks are VHD over EXT SR. -
So there is no way to send a deactivation or activation request to xo-cli?
-
@Gheppy I'm not sure if xo-cli supports job interactions, @olivierlambert may have to inquire with the xo-cli dev @julien-f . For your niche use case, you could solve it in the meantime by running your XO instance from your house (or wherever this CR destination and DB test server are). Then, you can set the CR job to replicate to two remotes, your main CR destination, and then your test pool you've been manually copying to. Since these are now both local to XOA, it won't use up extra internet bandwidth, XOA will still only be pulling one stream from the production server out on the internet, then once it's inside your network on XO, it duplicates and writes to both local CR destinations
-
- use
backupNg.getAllJobs
to list the all the jobs and find theid
of the job you want to manage - use
schedule.getAll
to list all schedules and find the ones which reference your job via thejobId
property schedule.set id=<schedule id> enabled=json:false
schedule.set id=<schedule id> enabled=json:true
- use
-
Thanks for the guidance, that's all I need.
It's all working now.Thank you