TeslaMate.Api => Error: unknown => Mint.TransportError{reason: :nxdomain} #588
Comments
|
There appears to be an issue with DNS resolution on your machine. NXDOMAIN means that the lookup of the required DNS entry returned a response of "domain does not exist" |
|
@ngardiner Thank you for the prompt reply. Since this may be a DNS resolution problem, what is the domain the API is using to do the lookup for? |
|
There are multiple hostnames TeslaMate would need to resolve to work correctly, |
|
Thank you @ngardiner Do you know where the full list of servers are in the code, so I can test them all? P.S. I did a ping on the server to the one you gave me and it resolved:
|
|
Here are a few more domains that the car talks to - I don't think Teslamate talks to all of these but these are the ones I am aware of. But at the end of the day you might want to figure out the DNS issues. Maybe try the dig command (if you are on Linux) and then see what happens.
|
The server itself may be able to resolve the record, but I would be testing this inside of the TeslaMate docker container which needs to be able to resolve these. Given the way docker networking works, the issue is likely only present for containers rather than for the host. |
|
Thanks @ngardiner that may be it. I temporarily bypassed login with the API Key, but would like to solve it for regular login. OK, so I used: So DNS resolved inside the container! At a loss now... |
|
This may or may not be related, but the Docker version you're using is from 2017. It might be a good idea to update it to the latest version. |
|
Thanks @adriankumpf for noticing and pointing that out, brilliant! Updated Client & Server Docker Engine from v1.13.1 to v19.03.8 built March 2020
Quick Q: How does Tesla credentials caching work in TeslaMate? A) Originally I had managed to inject the API Tokens to bypass the login, but they expire in 45 days. I assume I have to re-do the process and update them ongoing in the DB every 45 days? B) Also, since I managed to get the login to work by upgrading Docker, do I have to re-login on some cadence to ensure TeslaMate can always poll the vehicle? Thanks again! |
I thought that "refresh_token": "YOURREFRESHTOKEN" is for that, to refresh the token, I might be wrong of course. |
|
Yup, that's what the refresh token is for
That's not necessary. As long as it's running, data is being recorded. |
|
I'm having similar issues on my Synology NAS. This has Docker |
|
For reference, it's working on my Synology DS415+. My problem was that I have my NAS configured to use a DNS service. This allowed only queries for my local subnet but not for the subnets of the various docker networks. The solution was to add Although I tried adding DNS entries in the |
Hey @ramonsmits, I'm having the same issue on my Synology. I'm pretty new to all of this. Would it be possible to explain where to add the /12 to the allowed subnets? Not sure if this should be done somewhere in the network configuration on the Synology or with the .yml file or somewhere else entirely. |
|
To extend my previous response. Tonight I helped resolve this issue for another Synology user by following the instructions from this blog post: https://robinwinslow.uk/fix-docker-networking-dns It involves creating the file {
"dns": ["10.0.0.2", "8.8.8.8"]
}This was not needed on my Synology NAS. If you use Synology DNS then please ensure you use the correct subnet if you have limited the access to the service. You can locate the IP range via the Synology Docker Networks. Open the corresponding network and copy the correct subnetmask. |

**SOLVED!!** Solution was to update Client & Server Docker Engine from v1.13.1 to v19.03.8..........................................................................................
There seems to be a bug that references TeslaMate.Api
Once authenticated at https://teslamate.domain.com on port 4000 and proxied to the docker container, the initial login page requiring the Tesla official credentials puts out a "Error: unknown" message when using confirmed valid Tesla credentials.
Logs were monitored using: docker logs --follow
Logs include the following line repeating with each Tesla official credentials login attempt:
Operating environment
The text was updated successfully, but these errors were encountered: