-
-
Notifications
You must be signed in to change notification settings - Fork 290
Description
Describe the problem
This is a working record content for testmachine.test.lan LUA record:
AAAA "dblookup('testmachine.dyn6.test.lan', pdns.AAAA)"
I'm unable to push that content in the add new record. I have the error:
""" LUA record in implicit return mode should be a valid function call or function definition with "function" and "end" keywords. """ Seems that last is wrong...
To push it, I need to use AAAA ("dblookup('testmachine.dyn6.test.lan', pdns.AAAA)") and powerdns don't like that:
Exception building answer packet for test.test.lan/AAAA (Parsing record content (try 'pdnsutil check-zone'): Data field in DNS should start with quote (") at position 5 of 'AAAA ("dblookup('testmachine.dyn6.test.lan', pdns.AAAA)")') sending out servfail.
And to bypass any "why you use that" question: This is the only way I found to push ipv4 and ipv6 coming from two dynamic dns domains (dyn6.test.lan and dyn4.dns.lan). It seems that ipv4 zone and ipv6 zone don't like to share same DHCID, so I need to use two zone. To have one dns for both addresses I cannot use CNAME or ALIAS: you can just put one CNAME and powerdns is just using the last ALIAS record if they are many. I cannot use direct A and AAA records, they are dynamic DNS. So i use two records:
testmachine.test.lan LUA AAAA "dblookup('testmachine.dyn6.test.lan', pdns.AAAA)"
testmachine.test.lan LUA A "dblookup('testmachine.dyn4.test.lan', pdns.A)"
If you don't have time to reprogram a validation for that type (seems tricky), just remove it. It's LUA, user needs a basic "I know what I am doing" skills to use that. By the side thanks for the CNAME cannot have the same name validation, that helps me. Thanks a lot.
Steps to reproduce
Add a new record, put any name, put LUA type and put: AAAA "dblookup('test6.test.lan', pdns.AAAA)" in the content.
Result: """ LUA record in implicit return mode should be a valid function call or function definition with "function" and "end" keywords. """
Poweradmin version
4.0.1
Database
MariaDB
Additional information (optional)
Workarround: Push something working and use phpmyadmin to fix the record...
PowerDns version: 4.9.7
Anything I can do for you?