Error "Cannot open socket"

ManiaControl, the completely new designed and easy to use controller managing all your Maniaplanet server.

Moderators: Jocy, Wabbitface, steeffeen, NADEO

ybconcept
Posts: 7
Joined: 14 Dec 2019, 17:18

Error "Cannot open socket"

Post by ybconcept »

Hello !

When I launch the ManiaControl bash script from my server i've an error

Code: Select all

[ERROR] Couldn't connect to the server: 'Cannot open socket'
I've the game on Pterodactyl with ports 2350, 3450 and 500 allocated

A part of my dedicated_cfg.txt

Code: Select all

<force_ip_address>.........</force_ip_address>
		<server_port>2350</server_port>
		<server_p2p_port>3450</server_p2p_port>
		<client_port>0</client_port>
		<bind_ip_address></bind_ip_address>
		<use_nat_upnp></use_nat_upnp>

..

		<xmlrpc_port>5000</xmlrpc_port>
		<xmlrpc_allowremote>False</xmlrpc_allowremote>
And my file server.xml for ManiaControl running on the dedicated Ubutnu server

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>

<maniacontrol>

        <!-- Configure Your ManiaPlanet Server -->
        <server>

                <!-- Server Connection Details -->
                <host>localhost</host>
                <port>5000</port>

                <!-- XmlRpc Login Details -->
                <user>SuperAdmin</user>
                <pass>password</pass>

        </server>

        <!-- Configure the MySQL Database used by ManiaControl -->
        <database>

                <!-- MySQL Server -->
                <host>localhost</host>
                <port>3306</port>

                <!-- MySQL User -->
                <user>trachmania</user>
                <pass>password*</pass>

                <!-- Database Name -->
                <name>trackmania_db</name>

        </database>
...
</maniacontrol>
and the log file

Code: Select all

[14-Dec-2019 15:59:23 UTC] Starting ManiaControl...
[14-Dec-2019 15:59:23 UTC] Checking for minimum required PHP-Version 5.4 ... 7.2.24-0ubuntu0.18.04.1 OK!
[14-Dec-2019 15:59:23 UTC] Checking for installed MySQLi ... FOUND!
[14-Dec-2019 15:59:23 UTC] Checking for installed cURL ... FOUND!
[14-Dec-2019 15:59:23 UTC] Checking for installed PHP ZIP ... FOUND!
[14-Dec-2019 15:59:23 UTC] Checking for installed Zlib ... FOUND!
[14-Dec-2019 15:59:23 UTC] Checking for installed mbstring ... FOUND!
[14-Dec-2019 15:59:23 UTC] Loading ManiaControl v0.232 ...
[14-Dec-2019 15:59:23 UTC] Starting ManiaControl v0.232!
[14-Dec-2019 15:59:23 UTC] Connecting to Server at localhost:5000...
[14-Dec-2019 15:59:23 UTC] [ERROR] Couldn't connect to the server: 'Cannot open socket'
[14-Dec-2019 15:59:23 UTC] Quitting ManiaControl!
Have you any idea ?

FYI i've tried to change the ip in ManiaControl settings with my server ip and with the "local" ip 127.0.0.1 and i^ve the same result
User avatar
TMarc
Posts: 15441
Joined: 05 Apr 2011, 19:10
Location: Europe
Contact:

Re: Error "Cannot open socket"

Post by TMarc »

Did you check which ports are already in use on your system?
If the ports are already occupied, this would explain the error.
ybconcept
Posts: 7
Joined: 14 Dec 2019, 17:18

Re: Error "Cannot open socket"

Post by ybconcept »

Thank you for your reply.

The port 5000 seem free before allocated in the pterodactyl panel.

I’ve try with the 5001 and i’ve the same error
User avatar
TMarc
Posts: 15441
Joined: 05 Apr 2011, 19:10
Location: Europe
Contact:

Re: Error "Cannot open socket"

Post by TMarc »

There are other ports as well, what about the port for the database server?

Did you check if the Maniaplanet dedicated is basically running alone by itself, without controller?
ybconcept
Posts: 7
Joined: 14 Dec 2019, 17:18

Re: Error "Cannot open socket"

Post by ybconcept »

I just try with the port 27031 (used for another remote control on the past) and i've the same result.

The ManiaPlanet Dedicated works good. I can play on
User avatar
TMarc
Posts: 15441
Joined: 05 Apr 2011, 19:10
Location: Europe
Contact:

Re: Error "Cannot open socket"

Post by TMarc »

what about that allowremote setting in the cfg? it is set to false, this could also simply block connections to the management port.
ybconcept
Posts: 7
Joined: 14 Dec 2019, 17:18

Re: Error "Cannot open socket"

Post by ybconcept »

It's set on True

Code: Select all

		<xmlrpc_port>27031</xmlrpc_port>
		<xmlrpc_allowremote>true</xmlrpc_allowremote>
User avatar
TMarc
Posts: 15441
Joined: 05 Apr 2011, 19:10
Location: Europe
Contact:

Re: Error "Cannot open socket"

Post by TMarc »

Not that one.

This here in your dedicated cfg.txt

Code: Select all

<xmlrpc_port>5000</xmlrpc_port>
<xmlrpc_allowremote>False</xmlrpc_allowremote>
ybconcept
Posts: 7
Joined: 14 Dec 2019, 17:18

Re: Error "Cannot open socket"

Post by ybconcept »

i've change from false to true and try again. Same result on the two cases
reaby
Posts: 1032
Joined: 29 Dec 2010, 23:26
Location: Eastern Finland
Contact:

Re: Error "Cannot open socket"

Post by reaby »

<force_ip_address>.........</force_ip_address>
i think you're forced the ip address for the server ?
then there's no loopback adapter available for localhost

dedicated_cfg.txt

Code: Select all

<force_ip_address>*hostIPaddress*</force_ip_address>
<xmlrpc_port>5000</xmlrpc_port>
<xmlrpc_allowremote>*hostIPaddress*</xmlrpc_allowremote>
you could as well put allowremote to True, but that would open it for all incoming connections, if so, make sure you have strong password.
so better to keep it "localhost" only, when you're more free to choose weak ones as well :)

maniacontrol config

Code: Select all

<host>*hostIPaddress*</host>
<port>5000</port>
should work if i'm not totally wrong.
Post Reply

Return to “ManiaControl”

Who is online

Users browsing this forum: No registered users and 1 guest