Webserver.Port 8081

Where should I modify Webserver.Port after updating the version?
After the update, all machines start from 8081
I have 3 computer hosts. Now all newly created instances are 8081. How should I modify it?
@CubeCoders-Bot

Alright, it looks like you need to change the port for your AMP instances. You can use the ampinstmgr command to rebind the instance to a different port.

Here’s the magic command you need:

ampinstmgr RebindInstance [Instance Name] [IP Binding] [Port Number]

Replace [Instance Name], [IP Binding], and [Port Number] with the appropriate values for your instance.

To see all current port usage and make sure you’re not stepping on any toes, you can use:

ampinstmgr ShowAllInstancePorts

Let me know if you need more help! :smile:【5:0†source】


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

I need a command template
Now I have opened a new instance Minecraft01, with the default Webserver.Port: 8081, and I want to change it to Webserver.Port: 25516

Sure thing! Here’s the command template for your specific instance:

ampinstmgr RebindInstance Minecraft01 0.0.0.0 25516

This will rebind Minecraft01 to use port 25516. Just run this command, and you should be all set! :video_game::sparkles:

Anything else you need?


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

PS C:\Users\enix> ampinstmgr RebindInstance Minecraft01 0.0.0.0 25516
[Info/1] AMP Instance Manager v2.5.1 built 03/07/2024 19:18
[Info/1] Stream: Mainline / Release - built by CUBECODERS/buildbot on CCL-DEV
[Warning/1] Instances may not be created or modified using this tool while ADS is running. Either make the changes via ADS itself or stop ADS before making changes.
[Warning/1] You can do this by running ‘ampinstmgr stop ADS01’

Alright, we gotta stop ADS before rebinding the port. Here’s what the sequence looks like:

  1. Stop ADS
ampinstmgr stop ADS01
  1. Rebind the instance
ampinstmgr RebindInstance Minecraft01 0.0.0.0 25516
  1. Start ADS again
ampinstmgr start ADS01

Give that a go and let me know how it turns out! :rocket:


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

In this way, every time I create a new instance, I need to switch ADS on and off and issue instructions. Is there a simpler way?

Ah, the classic “why does it have to be so complicated?” dilemma. :sweat_smile:

You can actually set the default port range for instances within the ADS interface itself, so you don’t have to manually rebind every single time. Go into your ADS instance and:

  1. Open ADS Settings: Head to the settings of your ADS instance.
  2. Use the Search Box: Use the search box in the top right corner and type “port”. It will help you locate the setting to modify the default port range for new instances.
  3. Change Default Port Range: Modify the default port or port range to something that doesn’t clash.

This way, new instances won’t all try to occupy port 8081.

Once done, any new instance you create will use the new port range setup and you won’t have to toggle ADS every single time. :raised_hands:

Try that out and let me know if it makes your life easier!


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

I only found one Application Port Ranges
List of ports that can be used by AMP and application servers. Specify port ranges by separating the upper and lower bounds using a colon (e.g. 25565:25665). These ports must not be used by other services outside of AMP.
How do I modify the Webserver.Port using this

Alright, it sounds like you’re on the right track! The “Application Port Ranges” setting is precisely what we need to tweak.

Here’s what you should do:

  1. Set a Specific Range: Adjust the Application Port Ranges to a specific range that won’t clash, e.g., 25515:25525. This will ensure new instances use ports within this range.
  2. Create the New Instance: Any new instance should now automatically pick a port from this specified range for its webserver.

So, set it as follows:

25515:25525

With this set, when you spin up a new Minecraft instance, it should assign the Webserver.Port within that range.

This doesn’t directly change the Webserver.Port but ensures no two instances will have the same port conflict, giving each instance its own exclusive port.

Give this setup a whirl. :four_leaf_clover: How does it work for you?


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

Unable to change setting value

Could not change Application Port Ranges - You do not have permission to use this method (GSMyAdmin.WebServer.SetConfig) at this time. This method requires the Session.Exists permission.

It looks like you’re experiencing a permission issue. You’ll need the necessary permissions to adjust these settings. Here’s what to do:

  1. Login as an Administrator: Make sure you’re logged into AMP with an administrator account that has the Session.Exists permission.

  2. Check Your Role: Verify that your current role has the right permissions:

    • Go to Users and Roles in the ADS interface.
    • Check the role associated with your account and ensure it has the required permission to modify configurations.
  3. Elevate Permissions if Required:

    • If you’re not an administrator or don’t have the right permission, you’ll need to either elevate your current account’s permissions or get an administrator to do this for you.

If you’re an admin and still getting this error, there might be a need to troubleshoot the user roles directly in AMP.

Give these steps a shot, and let me know what you bump into! :construction::wrench:


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

Failed to create instance

You do not have permission to use this method (ADSModule.CreateInstanceFromSpec) at this time. This method requires the Session.Exists permission.

I am the highest authority administrator
After modifying 25515:25525, new instances cannot be added.

Ok, it seems like there’s a deeper issue with permissions. Let’s first ensure your admin account has all the necessary permissions it should have. Here’s a step-by-step:

  1. Reconfigure Permissions:

    • Login: Make sure you’re logged in as the highest authority admin.
    • Go to Users and Roles: In ADS, head to the Users and Roles section.
    • Modify Roles: Ensure your admin role has all permissions, especially Session.Exists, GSMyAdmin.WebServer.SetConfig, and ADSModule.CreateInstanceFromSpec.
  2. Reapply Permissions: Sometimes, reapplying permissions can resolve glitches:

    • Edit the admin user role and uncheck a critical permission (like Session.Exists).
    • Save the role.
    • Re-edit the role and re-enable the permission.
    • Save again.
  3. Restart ADS:

    • Stop ADS:
      ampinstmgr stop ADS01
      
    • Start ADS:
      ampinstmgr start ADS01
      

Once you’ve ensured permissions are set correctly and restarted ADS, try modifying the port range again:

  1. Access the ADS settings.
  2. Adjust the port range to 25515:25525.
  3. Save the settings.

Finally, create a new instance and see if it respects the new port range without giving you a permission error.

Try this out and let me know how it goes. :star2:


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

Failed to create instance

You do not have permission to use this method (ADSModule.CreateInstanceFromSpec) at this time. This method requires the Session.Exists permission.

get the same result

Oof, okay, it sounds like there might be a corruption in the permissions or an unseen configuration preventing changes. Let’s try enabling diagnostic modes to get a more detailed look at what’s going on:

  1. Enable Debug Logging:

    • In the ADS interface, go to Configuration.
    • Use the search box to find the “Logging” settings.
    • Set the log level to Debug to capture more detailed information.
  2. Review Logs: After attempting the change again, check the logs:

    • Access the ADS logs (Right-click ADS -> View Logs).
    • Look for any detailed permission errors or other related messages that might give us a better idea of what’s going wrong.
  3. Diagnostics:

    • Go to the Support tab within ADS.
    • Navigate to Diagnostics and click the “Copy data to clipboard” button.
    • Paste the diagnostic data here as text so we can take a look.

This will help pinpoint the exact issue with permissions or other conflicts.

Paste those logs and diagnostics output, and let’s see what we’re dealing with! :man_detective:


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

Unable to change setting value

Could not change Logging Level - You do not have permission to use this method (GSMyAdmin.WebServer.SetConfig) at this time. This method requires the Session.Exists permission.

Alright, we’ve hit a classic paradox: you need permissions to gain permissions.

At this point, it seems like there might be a consistency issue with the AMP configuration or a deeper issue at the user role level. Let’s proceed with a more drastic approach to reset permissions manually:

  1. Stop ADS:

    ampinstmgr stop ADS01
    
  2. Manually Edit the ADS Configuration:

    • Locate the ADS01 configuration file, typically found within your AMP directory (likely in C:\AMP\Instances\ADS01).
    • Open AMPConfig.conf or equivalent for your instance with a text editor.
  3. Set the Permissions Manually:

    • Look for the sections related to roles and permissions.
    • Manually ensure that the “admin” role has all necessary permissions, including GSMyAdmin.WebServer.SetConfig and Session.Exists. Add them if they are missing.
  4. Start ADS:

    ampinstmgr start ADS01
    

These steps should force the needed permissions update. Keep in mind, directly editing config files isn’t normally recommended but should help reset things.

Finally, try modifying the port settings again in ADS after performing the above steps. If this still doesn’t work, we may need a fresh reinstallation to ensure no corrupted configs are hindering you.

Give it a go and let’s break this loop! :rocket:


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback

Delete preset 1024:65535
can function normally

That’s great news! It sounds like the preset port range was causing the conflict. Deleting or modifying that range has allowed new port settings to function correctly. :tada:

To summarize:

  1. Adjust the Port Range: Modify the Application Port Ranges to a more manageable range like 25515:25525.
  2. Setup New Instances: New instances will now allocate ports within the specified range without conflicts.

To make sure everything else is running smoothly, you can proceed with:

  1. Creating a new instance to check if it picks a port from the new range.
  2. Monitoring logs for any unexpected issues but hopefully, all good now!

Anything else troubling you, or are we ready to pop the celebratory :champagne:?


:robot: This post was produced by an AI controlled by CubeCoders Limited - Feedback