xcat2 / xcat-core

Code repo for xCAT core packages
Eclipse Public License 1.0
360 stars 171 forks source link

Support SRV records in DNS #6312

Open CJCShadowsan opened 5 years ago

CJCShadowsan commented 5 years ago

Hi,

We have a use case that requires SRV records within DNS.

Is this possible to be added to xCAT, a little like the alias functionality?

Say, specify a group within xCAT to a table, say... 'dns' - which then loops through those items within makedns and creates SRV records for them?

This would enable true service discovery.

CJCShadowsan commented 5 years ago

So - the DNS table could have:

name, ip, group, type

And then for instance if the name was:

_serviceA,,servicegroup,srv

With a group called servicegroup with say 100x nodes?

_serviceA.cluster.local would be a SRV record with 100x A records.

CJCShadowsan commented 5 years ago

It could also then support specific DNS entries for A records using:

woo,10.0.0.30,,A

Instead of having to create a node definition.

immarvin commented 5 years ago

hi @CJCShadowsan , sorry for late response.

Would you please provide more background information or detailed description of the use case for this requirement? we need to decide whether this requirement is valid for xCAT

CJCShadowsan commented 5 years ago

We have a large estate of servers on a customers site, and xCAT controls the DNS for the cluster.

However, for monitoring purposes certain pieces of software use service discovery to simplify configuration files. As opposed to having a configuration file with 500+ nodes defined in it? You would only need one SRV DNS record, pointing to the A records of the 500+ nodes.

As these 500+ nodes are being controlled by xCAT, and the DNS therefore is being controlled by xCAT... xCAT needs to support SRV record types in a similar fashion to the way xCAT supports aliases.

This would be the clean solution, because if it isn't inside xCATs control as soon as makedns is ran after inserting a SRV record manually, it will be overwritten.

CJCShadowsan commented 5 years ago

This is just one of many examples where having specific records being configurable inside a 'dns' table would be advantageous - maybe you want a custom DNS record for a load-balancer inside your cluster for high-availability purposes? With this suggestion, you could do that.

kcgthb commented 4 years ago

I'd like to support that idea: having the possibility to manage DNS SRV records through xCAT would be really useful.

One additional use case: SchedMD just introduced the notion of config-less Slurm, where compute nodes in a cluster don't need to access a Slurm config file anymore, but can directly pull configuration information from the master controller, and get its IP information from a DNS SRV record (the documentation at https://slurm.schedmd.com/archive/slurm-master/configless_slurm.html). That would solve a number of issues for large scale deployments, where configuration files either need to be synchronized everywhere, or reside in NFS shares (or any kind of central storage servers) which are both a bottleneck and a single point of failure.

blixem commented 4 years ago

One additional use case: SchedMD just introduced the notion of config-less Slurm, where compute nodes in a cluster don't need to access a Slurm config file anymore, but can directly pull configuration information from the master controller, and get its IP information from a DNS SRV record (the documentation at https://slurm.schedmd.com/archive/slurm-master/configless_slurm.html).

We are moving to this configuration function with SLURM as well, and found this issue when searching how to add service discovery to named when xCAT is managing it.

Worst case xCAT should have a table or method for including site dns zone information. I see that xCAT now can handle custom zone files via the "namedincludes" directive in the site table, so it shouldn't be unprecedented to do the same for data in the zone file.

blixem commented 4 years ago

Pinging for an update.

CJCShadowsan commented 4 years ago

In the end... I ended up just setting up a DNS forwarder with FreeIPA and using that to manage SRV records - I was already using it for auth so to get it to manage SRV records in DNS was a bit of a no-brainer when I realised this wasn't going to get worked on.

Just so you guys know as an option, I mean it hasn't been picked up since 2019 so...

I could have written code changes and done a pull myself for this, I just didn't have the time with more pressing matters at hand.

Chris

On Thu, 25 Jun 2020 at 18:39, blixem notifications@github.com wrote:

Pinging for an update.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/xcat2/xcat-core/issues/6312#issuecomment-649723255, or unsubscribe https://github.com/notifications/unsubscribe-auth/AD326MGFDWVEKQQYTSKUTV3RYODVFANCNFSM4HMX4UHQ .

tomers007 commented 1 year ago

could any one explain how to do it the site table ? where should i locate the file ? if someone it works for him good ?