# Remote Nakama Server

**URL:** <https://forum.heroiclabs.com/t/remote-nakama-server/1037>\
**Category:** Local Setup\
**Created:** [October 9, 2020, 2:33am UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037 "2020-10-09T02:33:06Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![tranthor](https://avatars.discourse-cdn.com/v4/letter/t/57b2e6/32.png) [@tranthor](https://forum.heroiclabs.com/u/tranthor)\
**Post date:** [October 9, 2020, 2:33am UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/1 "2020-10-09T02:33:06Z")

</div>

Hi,  
I just finished my first real-time multiplayer game. So far I was testing running nakama server locally (and everything worked/works), but now, I’ve to test a connection to a remote server.

I’ve a Virtual Machine and I’ve running cockroach & nakama, like I did locally.  
The problem is, when I change the local IP to my remote IP in my game-client, I get a connection error:

```
NClientParameters parameters;
parameters.serverKey = "defaultkey";
parameters.host = "40.122.xx.xxx"; //virtual machine public ip
parameters.port = DEFAULT_PORT;
m_client = NCocosHelper::createDefaultClient(parameters);

```

It’s running in a Windows Server and I already tested turning off the Firewall.  
What could be happening?

Thanks

---

<div class="post-metadata">

**Author:** ![lugehorsam](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.heroiclabs.com/lugehorsam/32/314_2.png) [@lugehorsam](https://forum.heroiclabs.com/u/lugehorsam)\
**Post date:** [October 9, 2020, 4:05am UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/2 "2020-10-09T04:05:00Z")

</div>

Hey @tranthor, could you share the error message that you receive when you try to connect?

---

<div class="post-metadata">

**Author:** ![tranthor](https://avatars.discourse-cdn.com/v4/letter/t/57b2e6/32.png) [@tranthor](https://forum.heroiclabs.com/u/tranthor)\
**Post date:** [October 9, 2020, 12:23pm UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/3 "2020-10-09T12:23:35Z")

</div>

Hi @lugehorsam  
Sure.

This is the error:

 ![Screen Shot 2020-10-09 at 09.23.00](https://us1.discourse-cdn.com/flex020/uploads/heroiclabs/original/1X/fed3ea1f1c8583ef34028d1e0821c17fae171d33.png)

---

<div class="post-metadata">

**Author:** ![lugehorsam](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.heroiclabs.com/lugehorsam/32/314_2.png) [@lugehorsam](https://forum.heroiclabs.com/u/lugehorsam)\
**Post date:** [October 10, 2020, 2:50pm UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/4 "2020-10-10T14:50:15Z")

</div>

@tranthor I’d check the network settings on the software you are using to administer the VM. You are using a public IP but it is possible that your VM is only accessible over a private network.

---

<div class="post-metadata">

**Author:** ![tranthor](https://avatars.discourse-cdn.com/v4/letter/t/57b2e6/32.png) [@tranthor](https://forum.heroiclabs.com/u/tranthor)\
**Post date:** [October 10, 2020, 5:35pm UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/5 "2020-10-10T17:35:53Z")

</div>

@lugehorsam  
Doing a port scan I’m sure that the port **7349** is open. Maybe Nakama uses other ports as default?

---

<div class="post-metadata">

**Author:** ![tranthor](https://avatars.discourse-cdn.com/v4/letter/t/57b2e6/32.png) [@tranthor](https://forum.heroiclabs.com/u/tranthor)\
**Post date:** [October 10, 2020, 6:02pm UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/6 "2020-10-10T18:02:53Z")

</div>

Fixed 😉  
I forgot that Nakama uses other ports too.  
7348, 7349, 7350 and 7351.

Thanks guys.

---

<div class="post-metadata">

**Author:** ![erlend\_sh](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.heroiclabs.com/erlend_sh/32/335_2.png) [@erlend\_sh](https://forum.heroiclabs.com/u/erlend_sh)\
**Post date:** [December 4, 2020, 11:48am UTC](https://forum.heroiclabs.com/t/remote-nakama-server/1037/7 "2020-12-04T11:48:34Z")

</div>


