Accessing Erpnext remotely on Ubuntu Server 20.04

Good Day Erpnext Community.

I recently purchased an HP Proliant Microserver to run Erpnext for my client and have successfully installed Erpnext V13. I am able to access it via my localhost but am unable to connect to it remotely.

I have opened up my ports 80, 22 & 443 on my router just like I did when I ran it on Oracles VM.

I as well set up my DNS hosting on my router.

I am still unable to connect to my erpnext remotely and not on my local network.

I don’t know if the problem is with MySQL, MariaDB, or Nginx.

Any help would be highly appreciated!

If you can access ERPNext via localhost? Then you can rule out MariaDB/MySQL. If those had problems, ERPNext would not start at all.

Can you remotely connect using SSH? If not, the problem is almost-certainly firewall or DNS.

Assuming the above are okay, here are some ideas for troubleshooting:

  1. Verify that ERPNext is running in “production mode”.

    • If ERPNext was started using ‘bench start’, then most-likely, Nginx isn’t configured to reverse proxy from port 8000 to 80/443.
  2. Verify your firewall isn’t blocking traffic. Check the log files on Linux.

  3. Verify that Nginx is indeed running as a background daemon.

  4. Assuming the above is okay, try adding a ‘server’ or ‘location’ block to your Nginx configuration, and point at a static HTML file. Can you access -that- web page remotely over HTTP?

    • If yes, this indicates that Nginx is working correctly, in a general way. And that port 80 is indeed open.
  • If you’ve reached this point, then the problem might be the specific Nginx configuration for ERPNext.

Thank you so much for the fast response. I will go through everything you suggested and report with feedback!

Kind Regards

Hi.

I’ve done this by port forwarding through my router, I used 8080, 8089 since port 80 is probably blocked by ISP, it works for a minute then time out.

Also used this command to change port numbers off my sites:

bench --site site_name serve --port port_number

then will prompt nginx dialoge, type ‘y’ to overwrite configuration.

Finally, installed noip in my vm server and works well, I can access it remotely.

Good day Mohammed.

Thanks for the response.

I have followed the steps on noip to set up the DUC. But still no luck.

Do you have any other suggestions?

Regards

Thanks,

May I have a look on your configuration? Also what’s your subscription line? is it land line or 4g-5g subscription?

@Michael_Creevy, can you clarify your situation?

  • Is this HP Microserver at your client’s office, and you’re trying to connect Your Office → Theirs?

or

  • The HP Microserver is located in your office. You’re hosting ERPNext. And the outside world is trying to connect to -you-?

@brian_pond Thank you so much for the suggestions!

It was in fact my Firewall and DNS hostings on my server. I installed Webmin and configured my DNS through that, i then did what @mohammad_mousa recommended by setting up https://www.noip.com/ to get a hosted domain.

A big thank you to yourself and @mohammad_mousa for the quick and helpful response

1 Like