You are not logged in.

#1 2016-03-19 08:25:34

geekinthesticks
Member
From: England
Registered: 2011-09-21
Posts: 143
Website

[solved] mythmote Unable to Connect.

Mythmote is an Android app that allows you to control a MythTV frontend through the frontend's raw text-based TCP socket interface. It relies on being able to connect to port 6546 in the frontend you are trying to control. I am having problems connecting to the frontend.

Logged into the frontend via ssh:

[ian@myth2 ~]$ netcat localhost 6546 -vv
Notice: Real hostname for localhost [127.0.0.1] is localhost.localdomain
Notice: Real hostname for localhost [127.0.0.1] is localhost.localdomain
localhost [127.0.0.1] 6546 open
MythFrontend Network Control
Type 'help' for usage information
---------------------------------
# exit
Total received bytes: 102
Total sent bytes: 5

From another computer:

(ianbarton)localhost ~/devel » netcat 192.168.0.183 6546 -vv
netcat: connect to 192.168.0.183 port 6546 (tcp) failed: Connection refused
(ianbarton)localhost ~/devel » netcat myth2.bantercat.co.uk 6546 -vv                                                                                               1 ↵
netcat: connect to myth2.bantercat.co.uk port 6546 (tcp) failed: Connection refused

So the frontend is refusing connections that are not from localhost. I cant work out why this is happening. The frontend doesn't have a firewall installed. Any suggestions on how to work out why it's blocking connections to port 6546 gratefully received!

Last edited by geekinthesticks (2016-03-21 13:09:25)

Offline

#2 2016-03-19 10:15:45

x33a
Forum Fellow
Registered: 2009-08-15
Posts: 4,587

Re: [solved] mythmote Unable to Connect.

Run a port scan on the frontend from some other computer.

# nmap -A 192.168.0.183

Offline

#3 2016-03-21 13:23:28

geekinthesticks
Member
From: England
Registered: 2011-09-21
Posts: 143
Website

Re: [solved] mythmote Unable to Connect.

x33a wrote:

Run a port scan on the frontend from some other computer.

# nmap -A 192.168.0.183

Thanks it turns out that by default mythfrontend only listens for connection on 127.0.0.1. I found the solution at: http://askubuntu.com/questions/127445/m … ing-on-all

For the benefit of other people who may have the same problem:

Edit ~/.mythtv/config.xml  and add your host ip address.

"<LocalHostName>"enter your local ip here"</LocalHostName>"

Add the following rules to iptables:

iptables -I INPUT -p tcp --dport 6546 -i [+] -j ACCEPT
iptables -I INPUT -p tcp --dport 6546 -i use your ip here -j ACCEPT

Check the "Allow remote connections" in the Setup part of mythfrontend. Now uncheck it an exit the frontend. Restart the frontend, check the box and finally exit and restart the frontend. It should now work.

Oh and finally it will only continue to work if your frontend has a fixed ip address.

Last edited by geekinthesticks (2016-03-21 13:25:18)

Offline

Board footer

Powered by FluxBB