How to remotely control the Minecraft server outside - MCSM panel [port mapping]

Reprinted from the remote penetration article: Public network remote access to connect to Minecraft minecraft server - MCSM control panel

overview

MCSManager is an open source, distributed, lightweight, one-click service management tool that supports most game servers and console programs. Supports Chinese and English languages, and has been providing healthy software support for Minecraft, Terraria, Steam game server administrators, operation and maintenance personnel and enterprises.

The following introduces how to install Mcsmanager in windwos and use the cpolar intranet penetration tool to remotely access the Mcsmanager panel and control the start and stop of the game instance.

1. MCS Manager installation

Download Mcsmanager , we download the windwos version, which does not support the installation of systems below windwos10

image-20230410113506522

After downloading, unzip and open, then click the launcher to start the background program

image-20230410114100144

After starting, it will automatically jump to the browser to open. If there is no jump, you can directly enter: localhost:23333 in the browser. For the first visit, we need to create an account

image-20230410114558169

Then you can enter the panel interface, and the panel interface can see some of our status information

image-20230410162147426

2. Intranet penetration

After the test of remote access in the local area network is successful, we continue to do intranet penetration to achieve remote access in different network environments. No public network IP is required, no need to set up a router, and it is simply achieved through cpolar intranet penetration.

2.1 Install cpolar intranet penetration

cpolar official website: https://www.cpolar.com/

Visit cpolar official website and register an account. Then apply the zip compression package for the Windows platform, get the cpolar installation package after decompression, and then double-click the installation package to install it by default.

![20230419092217](https://images.cpolar.com/img/20230419092217.png#pic_center

After cpolar is successfully installed, visit the local port 9200 [ http://localhost:9200 ] on the browser , and log in with the cpolar account.

20230130105810

Click Tunnel Management on the left dashboard - Create Tunnel, create an http tunnel and point to port 23333:

  • Tunnel name: you can customize the name, be careful not to duplicate the existing tunnel name
  • Protocol: select http
  • Local address: 23333
  • Domain name type: choose a random domain name for free
  • Region: Select China VIP

click创建

image-20230410171831481

After the tunnel is successfully created, click on the status on the left - online tunnel list, view the generated public network address, and then copy the address

image-20230410171906933

3. Access the public network address

Open the browser, we use the above public network address to access, enter the account password to log in

image-20230410172628813

So far, we have successfully published the local MCSManager service to the public network address

image-20230410172724250

4. Fixed public network address

Since the above tunnel created by using cpolar intranet penetration uses a random public network address, it will change randomly within 24 hours, which is not conducive to long-term remote access. Therefore, we can configure a second-level subdomain name for it, which is a fixed address and will not change randomly [ps: cpolar.cn has been filed]

Note that the cpolar package needs to be upgraded to the basic package or above, and the bandwidth corresponding to each package is different.

4.1 Reserve a second-level subdomain

Log in to the cpolar official website, click Reserve on the left, choose to reserve the second-level subdomain name, set a second-level subdomain name, click Reserve, and copy the reserved second-level subdomain name after the reservation is successful

image-20230410173638370

After the reservation is successful, copy the reserved second-level subdomain address

image-20230410173708109

4.2 Configure a fixed second-level domain name

Visit http://127.0.0.1:9200/, log in to the cpolar web UI management interface, click Tunnel Management on the left dashboard - Tunnel List, find the tunnel to be configured, and click Edit on the right

image-20230410173740782

Modify the tunnel information, and configure the successfully reserved second-level subdomain name into the tunnel

  • Domain name type: select a second-level subdomain name
  • Sub Domain: Fill in the reserved sub-domain name

click更新

image-20230410173822539

After the update is complete, open the online tunnel list. At this time, you can see that the public network address has changed, and the address name has also become a reserved second-level subdomain name. Copy its http address

image-20230410180149212

4.3 Access to a fixed public network address

Then use the fixed http address to open the browser to access, enter the account password to log in

image-20230410180233399

5. Set the public network address of the node

The remote panel access is set above, but the instance cannot be accessed. Clicking on our instance will prompt the following error, because the node address is still a local address

image-20230411132648519

So we need to set the public network address of the service, switch to the local address to open the MCSM panel, check the port number of the node, you can see that the port number on my side is 24444

image-20230411133005952

Access the local port 9200 http://127.0.0.1:9200/, log in to the cpolar web UI management interface, click the tunnel management on the left dashboard - create a tunnel, create a tcp tunnel, and point to port 24444

  • Tunnel name: you can customize the name, be careful not to duplicate the existing tunnel name
  • Protocol: select tcp
  • Local address: 24444
  • Domain name type: choose a random domain name for free
  • Region: Select China VIP

click创建

image-20230411133235497

After the tunnel is successfully created, click on the status on the left - online tunnel list to view the generated public network address. This address needs to be remembered and copied

image-20230411133335107

Then open the node list, replace the local address in the node, the port number uses the address port number generated by cpolar, and then click Update

image-20230411133533347

After updating, we use the http public network address we created above again, be careful not to use the https public network address, because the connection to our node does not use the wss protocol, open MCSManager, and then click our instance again

image-20230411133816763

At this point, you can see that the above error will not appear again, and we can open the instance normally and start it

image-20230411133917093

6. Fixed node public network address

It should be noted that the above steps use a random temporary tcp port address, and the generated public network address is a random temporary address, which will change randomly within 24 hours. Next, we configure a fixed TCP port address for it, which will not change, and there is no need to repeatedly modify the server address every day after setting.

To configure a fixed tcp port address, you need to upgrade cpolar to a professional package or above.

6.1 Reserve a fixed tcp address

Log in to the cpolar official website, click on the reservation on the left, find the reserved tcp address, let's reserve a fixed tcp address for Minecraft:

  • Region: Select China VIP
  • Description: It is a note, which can be customized

click保留

image-20230411142359480

After the address is successfully reserved, the system will generate a corresponding fixed public network address and copy it down

image-20230411142431677

6.2 Configure fixed TCP address

Access port 9200 on the browser http://127.0.0.1:9200/, log in to the cpolar web ui management interface, click on the tunnel management on the left dashboard - tunnel list, find the tcp tunnel we created above, and click on the right编辑

image-20230411142533886

Modify the tunnel information and configure the successfully reserved fixed tcp address into the tunnel

  • Port type: modified to fixed tcp port
  • Reserved tcp address: fill in the address successfully reserved on the official website

click更新

image-20230411142612274

After the tunnel is successfully updated, click the status on the left dashboard - the list of online tunnels, and you can see that the public network address has been updated to a fixed tcp address.

image-20230411142842648

Open the node list, we change the previous random address to our fixed tcp address, and then update

image-20230411153527527

Then we use the public network address to remotely access the MCSM panel to access and control the instance normally

image-20230411154635976

Guess you like

Origin blog.csdn.net/weixin_66578482/article/details/130457113