Tdarr icon indicating copy to clipboard operation
Tdarr copied to clipboard

Node cannot connect to server - v2.00.18

Open silverman10 opened this issue 2 years ago • 5 comments

Describe the bug [2022-07-14T10:28:35.903] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266

To Reproduce tdarr server and node on a kubernetes cluster; server and node on different hosts

Expected behavior Node connects to the server

Please provide the following information: Logs from node

Starting Tdarr_Node
[2022-07-14T10:20:41.699] [INFO] Tdarr_Node - /app/configs/Tdarr_Node_Config.json
[2022-07-14T10:20:41.713] [INFO] Tdarr_Node - {
  nodeID: '“node”',
  serverIP: '10.10.0.34',
  serverPort: '8266',
  handbrakePath: '',
  ffmpegPath: '',
  mkvpropeditPath: '',
  pathTranslators: [ { server: '', node: '' } ],
  platform_arch: 'linux_x64_docker_false',
  logLevel: 'INFO'
}
[2022-07-14T10:20:41.799] [INFO] Tdarr_Node - version: 2.00.18
[2022-07-14T10:20:41.799] [INFO] Tdarr_Node - linux_x64_docker_false
[2022-07-14T10:20:41.803] [INFO] Tdarr_Node - Starting Tdarr_Node
[2022-07-14T10:20:41.803] [INFO] Tdarr_Node - Preparing environment
[2022-07-14T10:20:41.898] [INFO] Tdarr_Node - Updating plugins
[2022-07-14T10:20:41.907] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:20:42.024] [INFO] Tdarr_Node - ---------------Binary tests start----------------
[2022-07-14T10:20:42.024] [INFO] Tdarr_Node - handbrakePath:HandBrakeCLI
[2022-07-14T10:20:42.024] [INFO] Tdarr_Node - ffmpegPath:/app/Tdarr_Node/node_modules/@ffmpeg-installer/linux-x64/ffmpeg
[2022-07-14T10:20:42.024] [INFO] Tdarr_Node - mkvpropedit:mkvpropedit
[2022-07-14T10:20:42.025] [INFO] Tdarr_Node - Binary test 1: handbrakePath working
[2022-07-14T10:20:42.025] [INFO] Tdarr_Node - Binary test 2: ffmpegPath working
[2022-07-14T10:20:42.025] [INFO] Tdarr_Node - ---------------Binary tests end-------------------
[2022-07-14T10:20:42.289] [INFO] Tdarr_Node - Cloning plugins
[2022-07-14T10:20:42.578] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:20:42.700] [INFO] Tdarr_Node - Finished downloading plugins!
[2022-07-14T10:20:45.539] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:20:46.122] [INFO] Tdarr_Node - [3835]Plugin update finished
[2022-07-14T10:20:50.545] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:20:55.553] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:21:00.558] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:21:05.562] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:21:10.565] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266

Logs from server


Starting Tdarr_Server
Starting Tdarr_Node
[2022-07-14T10:16:38.094] [INFO] Tdarr_Node - /app/configs/Tdarr_Node_Config.json
[2022-07-14T10:16:38.103] [INFO] Tdarr_Node - {
  nodeID: 'internal',
  serverIP: '10.10.0.34',
  serverPort: '8266',
  handbrakePath: '',
  ffmpegPath: '',
  mkvpropeditPath: '',
  pathTranslators: [ { server: '', node: '' } ],
  platform_arch: 'linux_x64_docker_false',
  logLevel: 'INFO'
}
[2022-07-14T10:16:38.193] [INFO] Tdarr_Node - version: 2.00.18
[2022-07-14T10:16:38.193] [INFO] Tdarr_Node - linux_x64_docker_false
[2022-07-14T10:16:38.198] [INFO] Tdarr_Node - Starting Tdarr_Node
[2022-07-14T10:16:38.198] [INFO] Tdarr_Node - Preparing environment
[2022-07-14T10:16:38.259] [INFO] Tdarr_Server - Reading DB:__________(0%):1:SettingsGlobalJSONDB:/app/server/Tdarr/DB2/SettingsGlobalJSONDB/afdf79ef24e7f6f173693057d0c2f3c07b0d3a3c.json:R/W Accessible
[2022-07-14T10:16:38.261] [INFO] Tdarr_Server - Reading DB:__________(0%):1:SettingsGlobalJSONDB:/app/server/Tdarr/DB2/SettingsGlobalJSONDB/afdf79ef24e7f6f173693057d0c2f3c07b0d3a3c.json:Reading
[2022-07-14T10:16:38.263] [INFO] Tdarr_Server - Reading DB:__________(0%):1:SettingsGlobalJSONDB:/app/server/Tdarr/DB2/SettingsGlobalJSONDB/afdf79ef24e7f6f173693057d0c2f3c07b0d3a3c.json:Adding
[2022-07-14T10:16:38.264] [INFO] Tdarr_Server - Reading DB:>>>>>>>>>>(100%):1:SettingsGlobalJSONDB::Reading done
[2022-07-14T10:16:38.264] [INFO] Tdarr_Server - Reading DB:__________(0%):1:LibrarySettingsJSONDB:/app/server/Tdarr/DB2/LibrarySettingsJSONDB/1e07cb4db97ea895059bf61991fbccaee67010b4.json:R/W Accessible
[2022-07-14T10:16:38.264] [INFO] Tdarr_Server - Reading DB:__________(0%):1:LibrarySettingsJSONDB:/app/server/Tdarr/DB2/LibrarySettingsJSONDB/1e07cb4db97ea895059bf61991fbccaee67010b4.json:Reading
[2022-07-14T10:16:38.266] [INFO] Tdarr_Server - Reading DB:__________(0%):1:LibrarySettingsJSONDB:/app/server/Tdarr/DB2/LibrarySettingsJSONDB/1e07cb4db97ea895059bf61991fbccaee67010b4.json:Adding
[2022-07-14T10:16:38.266] [INFO] Tdarr_Server - Reading DB:>>>>>>>>>>(100%):1:LibrarySettingsJSONDB::Reading done
[2022-07-14T10:16:38.266] [INFO] Tdarr_Server - Reading DB:__________(0%):1:NodeJSONDB:/app/server/Tdarr/DB2/NodeJSONDB/9f33a7c798af6fd6abb28049d9c1b3edfa2fd24a.json:R/W Accessible
[2022-07-14T10:16:38.266] [INFO] Tdarr_Server - Reading DB:__________(0%):1:NodeJSONDB:/app/server/Tdarr/DB2/NodeJSONDB/9f33a7c798af6fd6abb28049d9c1b3edfa2fd24a.json:Reading
[2022-07-14T10:16:38.268] [INFO] Tdarr_Server - Reading DB:__________(0%):1:NodeJSONDB:/app/server/Tdarr/DB2/NodeJSONDB/9f33a7c798af6fd6abb28049d9c1b3edfa2fd24a.json:Adding
[2022-07-14T10:16:38.268] [INFO] Tdarr_Server - Reading DB:>>>>>>>>>>(100%):1:NodeJSONDB::Reading done
[2022-07-14T10:16:38.268] [INFO] Tdarr_Server - Reading DB:__________(0%):1:StatisticsJSONDB:/app/server/Tdarr/DB2/StatisticsJSONDB/3d18b2ea89fa5357cf6423b4e6985b46fa10195e.json:R/W Accessible
[2022-07-14T10:16:38.268] [INFO] Tdarr_Server - Reading DB:__________(0%):1:StatisticsJSONDB:/app/server/Tdarr/DB2/StatisticsJSONDB/3d18b2ea89fa5357cf6423b4e6985b46fa10195e.json:Reading
[2022-07-14T10:16:38.269] [INFO] Tdarr_Server - Reading DB:__________(0%):1:StatisticsJSONDB:/app/server/Tdarr/DB2/StatisticsJSONDB/3d18b2ea89fa5357cf6423b4e6985b46fa10195e.json:Adding
[2022-07-14T10:16:38.270] [INFO] Tdarr_Server - Reading DB:>>>>>>>>>>(100%):1:StatisticsJSONDB::Reading done
[2022-07-14T10:16:38.301] [INFO] Tdarr_Node - Updating plugins
[2022-07-14T10:16:38.318] [ERROR] Tdarr_Node - Node connection error to :10.10.0.34:8266
[2022-07-14T10:16:38.432] [INFO] Tdarr_Server - /app/configs/Tdarr_Server_Config.json
[2022-07-14T10:16:38.445] [INFO] Tdarr_Server - {
  serverPort: '8266',
  webUIPort: '8265',
  serverIP: '10.10.0.34',
  handbrakePath: '',
  ffmpegPath: '',
  logLevel: 'INFO'
}
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - ---------------Binary tests start----------------
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - handbrakePath:HandBrakeCLI
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - ffmpegPath:/app/Tdarr_Node/node_modules/@ffmpeg-installer/linux-x64/ffmpeg
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - mkvpropedit:mkvpropedit
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - Binary test 1: handbrakePath working
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - Binary test 2: ffmpegPath working
[2022-07-14T10:16:38.464] [INFO] Tdarr_Node - ---------------Binary tests end-------------------
[2022-07-14T10:16:38.887] [INFO] Tdarr_Server - version: 2.00.18
[2022-07-14T10:16:38.887] [INFO] Tdarr_Server - linux_x64_docker_false
[2022-07-14T10:16:38.887] [INFO] Tdarr_Server - Preparing environment
[2022-07-14T10:16:39.300] [INFO] Tdarr_Server - Tdarr started.
[2022-07-14T10:16:39.301] [INFO] Tdarr_Server - Tdarr documents folder:/app/server
[2022-07-14T10:16:39.301] [INFO] Tdarr_Server - Checking directories
[2022-07-14T10:16:39.303] [INFO] Tdarr_Server - Tdarr_Server listening at http://10.10.0.34:8266
[2022-07-14T10:16:39.303] [TRACE] Tdarr_Server - 
    --------------------------------------------------------------------------
    --------------------------------------------------------------------------
    
    Tdarr_WebUI running at http://localhost:8265
    
    --------------------------------------------------------------------------
    --------------------------------------------------------------------------
      
[2022-07-14T10:16:39.325] [INFO] Tdarr_Node - Cloning plugins
[2022-07-14T10:16:39.722] [INFO] Tdarr_Server - Node internal registered
[2022-07-14T10:16:39.724] [INFO] Tdarr_Node - Node connected & registered
[2022-07-14T10:16:39.752] [INFO] Tdarr_Node - Finished downloading plugins!
[2022-07-14T10:16:40.759] [INFO] Tdarr_Server - ---------------Binary tests start----------------
[2022-07-14T10:16:40.760] [INFO] Tdarr_Server - handbrakePath:HandBrakeCLI
[2022-07-14T10:16:40.760] [INFO] Tdarr_Server - ffmpegPath:/app/Tdarr_Server/node_modules/@ffmpeg-installer/linux-x64/ffmpeg
[2022-07-14T10:16:40.760] [INFO] Tdarr_Server - mkvpropedit:mkvpropedit
[2022-07-14T10:16:40.760] [INFO] Tdarr_Server - Binary test 1: handbrakePath working
[2022-07-14T10:16:40.761] [INFO] Tdarr_Server - Binary test 2: ffmpegPath working
[2022-07-14T10:16:40.761] [INFO] Tdarr_Server - ---------------Binary tests end-------------------
[2022-07-14T10:16:40.761] [INFO] Tdarr_Server - ---------------Scanner tests start----------------
[2022-07-14T10:16:40.762] [INFO] Tdarr_Server - Scanner test: Scanning file start
[2022-07-14T10:16:43.178] [INFO] Tdarr_Node - [3854]Plugin update finished
[2022-07-14T10:16:44.046] [INFO] Tdarr_Server - Scanner test: Scanning file end
[2022-07-14T10:16:44.047] [INFO] Tdarr_Server - Scanner test 1: FFprobe working
[2022-07-14T10:16:44.047] [INFO] Tdarr_Server - Scanner test 2: Exiftool working
[2022-07-14T10:16:44.047] [INFO] Tdarr_Server - Scanner test 3: Mediainfo working
[2022-07-14T10:16:44.047] [INFO] Tdarr_Server - Scanner test 4: CCExtractor working
[2022-07-14T10:16:44.047] [INFO] Tdarr_Server - ---------------Scanner tests end----------------
[2022-07-14T10:16:44.062] [INFO] Tdarr_Server - Database has finished initialising
[2022-07-14T10:16:44.195] [INFO] Tdarr_Server - Updating plugins
[2022-07-14T10:16:44.215] [INFO] Tdarr_Server - Turning folder watch on for:/movies
[2022-07-14T10:16:44.215] [INFO] Tdarr_Server - 300
[2022-07-14T10:16:44.252] [INFO] Tdarr_Server - Watcher Ccjrr5gE_ launched
[2022-07-14T10:16:44.308] [INFO] Tdarr_Server - Job report history size is within limit. Limit:10240 MiB, Size:1 MiB
[2022-07-14T10:16:44.637] [INFO] Tdarr_Server - Ccjrr5gE_: Creating folder watch for library:/movies
[2022-07-14T10:16:44.768] [INFO] Tdarr_Server - Cloning plugins
[2022-07-14T10:16:45.073] [INFO] Tdarr_Server - Ccjrr5gE_: Initial scan complete. Ready for changes
[2022-07-14T10:16:45.135] [INFO] Tdarr_Server - Finished downloading plugins!
  • OS: Linux/Kubernetes

Additional context Checked for any possible firewall/port issue, curl from the node to the server works, but comes back with a redirect message

root@tdarr-node-77d59f8bdf-j7mhr:/# curl 10.10.0.34:8266
Found. Redirecting to http://10.10.0.34:8265/root@tdarr-node-77d59f8bdf-j7mhr:/#

silverman10 avatar Jul 14 '22 10:07 silverman10

Do you also get a continual node registration error? I'm trying to run a seperate server and node on kubernetes too and I get

Node registration error: - nodeID 'tdarr-node-0' is already taken. Please set a different ID in Tdarr_Node_Config.json or through environment variables

From what I can gather this is a misnomer and it's to do with connectivity between the server and node from what others online say, but by server and node ports are accessible via the service I've created.

Edit: to be clear I'm not trying to hijack, just curious if it's related.

Edit 2: I fixed this by making sure the server manifest actually stated the server address, previously only the node had this variable set. Unless this helps solve your issue then disregard this.

2fst4u avatar Jul 19 '22 07:07 2fst4u

Hi, I do not get a node registration error. only the connection error from the node. nothing on the server. My server manifest does have the server ip in it; loadbalancer, so its one of the IPs. the connection is okay as far as I can tell (as checked with a curl from node to server)

silverman10 avatar Jul 19 '22 09:07 silverman10

Both your server and node/s will be seperate pods, correct? And in the same namespace? If so, are you using a service with the required ports declared?

The loadbalancer IP might be what's stopping it from working. I connect my server and nodes via the service name, that way they don't lose connection when the pods get recreated.

2fst4u avatar Jul 19 '22 09:07 2fst4u

Stupid me. Just as I thought I had a handle on how they needed to connect mine seems to not be working again. There must be more than just the service required.

2fst4u avatar Jul 19 '22 19:07 2fst4u

I think its a node thing. I ran the server on a separate system on docker and the node still didn't connect; came back with the same errors. I dont know what to check as the connection is okay as evidenced from the curl command working okay.

silverman10 avatar Jul 20 '22 07:07 silverman10

Can you share your deployment and service files?

agilob avatar Feb 24 '23 19:02 agilob

Please try 2.00.19 and reopen if needed thanks.

HaveAGitGat avatar Feb 25 '23 12:02 HaveAGitGat

Hello. I think I have a similar situation. My tdarr version is 2.00.20. I have 2 macbooks, on both are docker with container for tdarr. One of them is the Server and another is the Node. So I can't connect Node to the Server. I got this error:

[2023-05-20T22:16:14.318] [ERROR] Tdarr Node - Node connection error to :192.168.1.43:8266 (2023-85-20722:16:14.322] [ERROR] Tdarr Node - Error: timeout at Timeout. ‹anonymous> (/snapshot/node/node_modules/socket.io-client/build/cjs/manager.js:173:38) at list0nTineout (internal/timers. Js:557:17) at processTimers (internal/timers. js:500:7) [2023-05-20122:16:21.567] [ERROR] Tdarr Node - Failed to contact server, retrying...

When I tried to go from macbook with Node to the Server by the url http://192.168.1.43:8266/api/v2/status I had a response ("status": "good", "isProduction" itrue, "os" :"linux", "version": "2.00.20", "uptime": 2610)

Also when I did telnet from host machine (where container with Node) to server on port 8266 - I had connection. But if I doing telnet inside Node container telnet can't access server..
Here is the docker-compose of server:

services:
  tdarr:
    container_name: tdarr
    image: ghcr.io/haveagitgat/tdarr:latest
    restart: unless-stopped
    environment:
      TZ: Europe/London
      PUID: 1000
      PGID: 1000
      UMASK_SET: 002
      serverIP: 0.0.0.0
      serverPort: 8266
      webUIPort: 8265
      internalNode: true
      inContainer: true
      nodeName: MAC1
      volumes:
      - server:/app/server
      - configs:/app/configs
      - logs:/app/logs
      - transcode_cache:/temp
      - media:/media
    networks:
      media:
    ports:
      - 8265:8265 # webUI port
      - 8266:8266 # server port
      - 8267:8267 # Internal node port
      - 8268:8268 # Example extra node port
 networks:
  media:
    external: true

Here is the docker-compose of node:

version: '3.9'
services:
  tdarr-node:
    container_name: tdarr-node
    image: ghcr.io/haveagitgat/tdarr_node:latest
    restart: unless-stopped
    environment:
      TZ: Europe/London
      PUID: 1000
      PGID: 1000
      UMASK_SET: 002
      nodeName: Mac2
      serverIP: 192.168.1.43
      serverPort: 8266
      inContainer: true
    volumes:
      - configs:/app/configs
      - logs:/app/logs
      - transcode_cache:/temp
      - media:/media

Do you have an idea what could be a problem?

deimjons avatar May 20 '23 21:05 deimjons

you dont have networks: media:in the node

agilob avatar May 21 '23 06:05 agilob

you dont have networks: media:in the node

it is 2 different computers. If network not setuped docker will make bridge type of network. So I should be able to go via host computer to lan. I don't think that is the case.

deimjons avatar May 21 '23 06:05 deimjons