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

support lxd clustering #292

Open
bit opened this issue Mar 29, 2018 · 7 comments
Open

support lxd clustering #292

bit opened this issue Mar 29, 2018 · 7 comments

Comments

@bit
Copy link

bit commented Mar 29, 2018

i.e. no way to specify the target host in container.create.
in the rest api this is done by adding ?target=target_id

api extension are document at:
https://github.com/lxc/lxd/blob/master/doc/api-extensions.md#clustering

@ajkavanagh
Copy link
Contributor

Yes, this is a 3.x feature added via the 'clustering' API extension.

The 'clustering' extension affects a number of areas: containers, storage-pools, and networks.

(Note for implementation: remember to check that the 'clustering' API extension exists as a check as to whether to accept this parameter.)

@ghoshanjega
Copy link

Any timeline on when clustering will be supported?

@felix-engelmann
Copy link
Contributor

I also required the clustering features and therefore built the minimum as PR #331
As mentioned, it might fail if the extension is not existent. (To be checked)

@felix-engelmann
Copy link
Contributor

@ghoshanjega there is now an api endpoint for getting cluster and member info. What else would you need?
@bit there is a target parameter for containers now.

@mkowalski
Copy link
Contributor

Hi guys,

I have started using pylxd very recently and the first thing I noticed missing in the cluster supports is creation of networks. Where in the standalone LXD it's enough to do

lxc network create ...

in a clustered environment the process is a bit more complex

lxc network create ... --target node1
...
lxc network create ... --target nodeN
lxc network create ...

Any idea if we could get this supported?

@felix-engelmann
Copy link
Contributor

The addition of a target argument for containers was very lightweight.
To support networks in cluster mode, I need the following information:

  • @stgraber does the lxd api support an undocumented ?target= query parameter for networks like the instance endpoint?
  • @ajkavanagh what is the architecture decision on the abstraction of this library: Make one complex call which manages the network creation on all nodes or leave it up to the user to perform the necessary calls and add a simple target argument?

@stgraber
Copy link
Contributor

@felix-engelmann ?target for networks and storage-pools is supported and lets you create/set the host-specific config ahead of adding a network or storage-pool globally.

That's why you usually need to create a network like:

lxc network create blahbr0 --target a
lxc network create blahbr0 --target b
lxc network create blahbr0 --target c
lxc network create blahbr0

The targeted ones can set keys that are only relevant to a particular member, in the network case, that's pretty much just bridge.external_interfaces.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants