[Tutorial] How to Manually Modify the Dashboard Port Number of ZimaOS in CLI

Why This Happens

There are two common scenarios:

  1. Accidental Changes: You or someone else might have mistakenly altered the port number.
  2. Intentional Changes: You modified the port number for specific reasons, but it’s no longer functioning as expected.

Whatever the cause, resetting the port number to 80 can resolve the issue and restore access to your ZimaOS dashboard.


Step-by-Step Guide

Step 1: Physically Connect to ZimaOS

To begin, you’ll need direct access to your ZimaOS machine. Connect a keyboard and monitor to the device.

Step 2: Access the CLI and Switch to root

Press Alt + F3 to switch to the command-line interface (CLI). This will allow you to log in and make the necessary changes. After logging in, you need to switch to root privilege.

sudo -i

Step 3: Modify the Port Number Using VI Editor

Once logged in, use the vi editor to modify the port number. Here’s how:

  1. Open the configuration file:
vi /etc/casaos/gateway.ini
  1. Locate the line that specifies the port number. It might look something like this:
port = 8080  
  1. Change the port number to 80:
port = 80  
  1. Save and exit the editor by pressing Esc, then typing :wq and hitting Enter.

Step 4: Restart the ZimaOS Gateway Service

After making the changes, restart the ZimaOS gateway service to apply the new port number:

systemctl restart zimaos-gateway.service  

Conclusion

By following these steps, you’ve successfully reset the ZimaOS dashboard port number to 80. This should resolve any access issues and allow you to manage your OS seamlessly. If you encounter further problems, don’t hesitate to reach out to us here and in the Discord channel.


Pro Tip: Always double-check configuration changes to avoid accidental modifications. For more ZimaOS tutorials and troubleshooting guides, visit our official documentation.