Adding subdomain prematurely truncates main domain #1

Closed
opened 2023-04-08 22:25:33 +02:00 by Gunb0atDiplomat · 4 comments

My domain name (obscura.za.net) is successfully added to the local DDNS database, but when adding a subdomain returns the following error:

[user@localhost ~]$ ddns -s mctest.obscura.za.net
Error: Top domain obscura.za does not exist in the DB. Please add it with ddns -t obscura.za.

I can verify that the correct domain obscura.za.net exists in the DB:

[user@localhost ~]$ ddns -d
Domains in database are marked with a [*]
================================================
Name : obscura.za.net [*]
My domain name (obscura.za.net) is successfully added to the local DDNS database, but when adding a subdomain returns the following error: ``` [user@localhost ~]$ ddns -s mctest.obscura.za.net Error: Top domain obscura.za does not exist in the DB. Please add it with ddns -t obscura.za. ``` I can verify that the correct domain ```obscura.za.net``` exists in the DB: ``` [user@localhost ~]$ ddns -d Domains in database are marked with a [*] ================================================ Name : obscura.za.net [*] ```
Owner

Ah!

Thanks for the feedback!

Right now it is a limit of one domain (e.g demo.com).

I can have a look at it down the line - to add the possibility for sub domains of sub domains.

I need to find a middle way to determin how many sub domains to support. The max is 127 with a char limit of 63 for each level but with a max of the whole tree of 253 chars. (Wikipedia)

I can't promise any timeframe for this. But you're wellcom to submit a PR ;-)

[edit]
I see that this will impact users of e.g. co.uk etc. I'll try to have a new version ready to fix this in a weeks time - but no promise on the timeframe 😀

Atb,
Rune

Ah! Thanks for the feedback! Right now it is a limit of one domain (e.g demo.com). I can have a look at it down the line - to add the possibility for sub domains of sub domains. I need to find a middle way to determin how many sub domains to support. The max is 127 with a char limit of 63 for each level but with a max of the whole tree of 253 chars. ([Wikipedia](https://en.wikipedia.org/wiki/Domain_Name_System#Domain_name_formulation)) I can't promise any timeframe for this. But you're wellcom to submit a PR ;-) [edit] I see that this will impact users of e.g. co.uk etc. I'll try to have a new version ready to fix this in a weeks time - but no promise on the timeframe 😀 Atb, Rune
rune referenced this issue from a commit 2023-04-15 17:11:42 +02:00
rune self-assigned this 2023-04-15 17:16:35 +02:00
Owner

Fixed in version 0.5.1

Thanks to @Gunb0atDiplomat for the heads-up!

Rune

Fixed in version 0.5.1 Thanks to @Gunb0atDiplomat for the heads-up! - Rune
rune closed this issue 2023-04-15 17:17:29 +02:00

Related-seeming issue found in v0.5.1:

  1. Adding a listed subdomain from the list also struggles with 3-part top level domains:
[user@localhost ~]$ ddns -k example.za.net [DOMAINID]
Error: Top domain za.net does not exist in the DB. Please add it with ddns -t za.net.

Also found the following error, not sure if related:

  1. Having 4x A records on my DO DNS domain (for round robin DNS eg. Google Hosted Services IPs) seems to make this listing not show up my subdomains:
[user@localhost ~]$ ddns -o example.za.net
Domains in your DigitalOcean account not in ddns DB for obscura.za.net
===================================================================
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]

However, when I deleted all but one of my A records, my other subdomains show up in a listing:

[user@localhost ~]$ ddns -o example.za.net
Domains in your DigitalOcean account not in ddns DB for obscura.za.net
===================================================================
subdomain0.example.za.net               ID : [DOMAINID]
subdomain1.example.za.net               ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]

Possibly the (sub)domain listing function is hiding some domains by limiting the listing.

Related-seeming issue found in v0.5.1: 1. Adding a listed subdomain from the list also struggles with 3-part top level domains: ``` [user@localhost ~]$ ddns -k example.za.net [DOMAINID] Error: Top domain za.net does not exist in the DB. Please add it with ddns -t za.net. ``` Also found the following error, not sure if related: 2. Having 4x A records on my DO DNS domain (for round robin DNS eg. Google Hosted Services IPs) seems to make this listing not show up my subdomains: ``` [user@localhost ~]$ ddns -o example.za.net Domains in your DigitalOcean account not in ddns DB for obscura.za.net =================================================================== @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] ``` However, when I deleted all but one of my A records, my other subdomains show up in a listing: ``` [user@localhost ~]$ ddns -o example.za.net Domains in your DigitalOcean account not in ddns DB for obscura.za.net =================================================================== subdomain0.example.za.net ID : [DOMAINID] subdomain1.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] ``` Possibly the (sub)domain listing function is hiding some domains by limiting the listing.
Owner

Hi!

Yes there was an error adding domains exisiting on Digital Ocean but not in you local db when the domain name was like test.co.uk. I've released a fix in version 0.5.2 for this!

If you want to add the root of the domain to ddns you need to use the @ name.

E.g:

You have 3 domains

[user@localhost ~]$ ddns -o example.za.net
Domains in your DigitalOcean account not in ddns DB for obscura.za.net
===================================================================
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]
@.example.za.net                ID : [DOMAINID]

you need to use ddns -k @.example.za.net [DOMAINID] to add the one(s) you want to add. The one you added will then don't show up in ddns -o example.za.net but it will show up in ddns -l example.za.net.

Hope this helps!

Rune

Hi! Yes there was an error adding domains exisiting on Digital Ocean but not in you local db when the domain name was like *test.co.uk*. I've released a fix in version 0.5.2 for this! If you want to add the root of the domain to ddns you need to use the @ name. E.g: You have 3 domains ``` [user@localhost ~]$ ddns -o example.za.net Domains in your DigitalOcean account not in ddns DB for obscura.za.net =================================================================== @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] @.example.za.net ID : [DOMAINID] ``` you need to use ```ddns -k @.example.za.net [DOMAINID]``` to add the one(s) you want to add. The one you added will then don't show up in ```ddns -o example.za.net``` but it will show up in ```ddns -l example.za.net```. Hope this helps! - Rune
rune locked as Resolved and limited conversation to collaborators 2023-05-02 10:56:41 +02:00
rune closed this issue 2023-09-05 11:39:57 +02:00
Sign in to join this conversation.
No Label
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: rune/ddns#1
No description provided.