# openBalena Local server set-up and raspberry device sync failied

**URL:** <https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932>\
**Category:** openBalena\
**Created:** [January 8, 2019, 6:43am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932 "2019-01-08T06:43:42Z")\
**Posts on this page:** 12\
**Page:** 1

<div class="post-metadata">

**Author:** ![pei](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@pei](https://forums.balena.io/u/pei)\
**Post date:** [January 8, 2019, 6:43am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/1 "2019-01-08T06:43:42Z")

</div>

Hi,

I have setup a openBalena server in my ubuntu18.04 laptop, I followed the instructions [https://www.balena.io/open/docs/getting-started/](https://www.balena.io/open/docs/getting-started/). I am partially successful, I could create app myAPP and list it.  
I have raspberryPi 3, I followed instructions to flash image after configuring. I am able to see the Raspi is booting perfect but when I run command ‘balena devices’ on balena cli I am not seeing the entry.

Installed balena CLI on VM. So, openBalena server and balena CLI are on different machines in same network.  
All instructions are run with login supplied while creating config folder for openBalena server.  
Any points where I am missing ?

---

<div class="post-metadata">

**Author:** ![richbayliss](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/richbayliss/32/1054_2.png) [@richbayliss](https://forums.balena.io/u/richbayliss)\
**Post date:** [January 8, 2019, 8:10am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/3 "2019-01-08T08:10:02Z")

</div>

Hi @pei

Firstly, did you use the `openbalena.local` domain? This uses mDNS to resolve and I have had issues on some network setups. If you have the ability to setup using a different domain, one which you can control the DNS entries for verbatim, that might be helpful.

Secondly, did you use a development image on your Pi? If so then could you pull the logs for the resin-supervisor service and put them here. To do so:

1. SSH to the Pi on port 22222, e.g. `ssh root@{Pi IP address} -p 22222`
2. run `journalctl -u resin-supervisor -n100 --no-pager`

This should show what’s going on from the Pi’s perspective.

---

<div class="post-metadata">

**Author:** ![pei](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@pei](https://forums.balena.io/u/pei)\
**Post date:** [January 8, 2019, 8:52am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/4 "2019-01-08T08:52:42Z")

</div>

Hello @richbayliss,

1. Yest domain is set to openbalena.local w/o it CLI was not able to connect.
2. I am using development version of Raspberry image.
3. Bellow is the log of the command. **_Event: Device bootstrap failed_** is coming, dont know the reason, have I made any mistake?  
Fullo Log:  
 ![image](https://global.discourse-cdn.com/balena/original/2X/9/9974669df09bc2ea7048cb31c1da01cbcbf92e11.png)

---

<div class="post-metadata">

**Author:** ![richbayliss](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/richbayliss/32/1054_2.png) [@richbayliss](https://forums.balena.io/u/richbayliss)\
**Post date:** [January 8, 2019, 9:06am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/5 "2019-01-08T09:06:22Z")

</div>

Could you also try running, on the Pi:

```
curl -ik https://api.openbalena.local/ping

```

and see if you get back `OK`?

---

<div class="post-metadata">

**Author:** ![pei](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@pei](https://forums.balena.io/u/pei)\
**Post date:** [January 8, 2019, 9:13am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/6 "2019-01-08T09:13:19Z")

</div>

No. “Could not resolve host: api.openbalena.local”.  
I see there are no entries for for openbalena.local.

---

<div class="post-metadata">

**Author:** ![richbayliss](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/richbayliss/32/1054_2.png) [@richbayliss](https://forums.balena.io/u/richbayliss)\
**Post date:** [January 8, 2019, 9:24am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/7 "2019-01-08T09:24:19Z")

</div>

OK well now we know the cause of the problem then; without it being able to curl the API it cannot register and receive instruction.

Personally I don’t use the `.local` domain in my setup, so I will reach out to someone who might be able to offer some debug advice.

In the meantime, if you can add host entries to your networks’ DNS resolver, then I would setup again using something like `openbalena.lan` and have entries for `api.`, `vpn.`, `registry.` and `s3.` all pointing to the IP of your setup.

---

<div class="post-metadata">

**Author:** ![richbayliss](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/richbayliss/32/1054_2.png) [@richbayliss](https://forums.balena.io/u/richbayliss)\
**Post date:** [January 8, 2019, 9:59am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/11 "2019-01-08T09:59:13Z")

</div>

Could you also try running `avahi-browse -a -r` and post the results here too?

---

<div class="post-metadata">

**Author:** ![pei](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@pei](https://forums.balena.io/u/pei)\
**Post date:** [January 8, 2019, 11:10am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/48 "2019-01-08T11:10:41Z")

</div>

root@47e3be4:~# avahi-browse -a -r  
-sh: avahi-browse: command not found

avahi-daemon is running.

---

<div class="post-metadata">

**Author:** ![dfunckt](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/dfunckt/32/56_2.png) [@dfunckt](https://forums.balena.io/u/dfunckt)\
**Post date:** [January 14, 2019, 3:43pm UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/49 "2019-01-14T15:43:03Z")

</div>

@pei open-balena currently isn’t advertising addresses on the network so you’ll need to configure DNS properly. If you’re deploying locally, it might be as simple as adding appropriate routes to your router so that devices will be able to resolve the open-balena hostnames. However, by far the easiest way to get a working installation is to setup an instance on a public host following the Getting Started guide.

---

<div class="post-metadata">

**Author:** ![pei](https://avatars.discourse-cdn.com/v4/letter/p/a698b9/32.png) [@pei](https://forums.balena.io/u/pei)\
**Post date:** [January 16, 2019, 8:26am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/50 "2019-01-16T08:26:23Z")

</div>

@dfunckt Thank you. I will try.

---

<div class="post-metadata">

**Author:** ![fruloops](https://avatars.discourse-cdn.com/v4/letter/f/e47774/32.png) [@fruloops](https://forums.balena.io/u/fruloops)\
**Post date:** [February 27, 2019, 2:05pm UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/51 "2019-02-27T14:05:33Z")

</div>

I have a similar problem as OP had (Device bootstrap fails, curl returns an error), so I’m curious, if the solution is still the same as @dfunckt proposed (configuring DNS) or is there some other solution to this issue?

---

<div class="post-metadata">

**Author:** ![richbayliss](https://sea2.discourse-cdn.com/balena/user_avatar/forums.balena.io/richbayliss/32/1054_2.png) [@richbayliss](https://forums.balena.io/u/richbayliss)\
**Post date:** [February 28, 2019, 10:27am UTC](https://forums.balena.io/t/openbalena-local-server-set-up-and-raspberry-device-sync-failied/4932/52 "2019-02-28T10:27:01Z")

</div>

If you’re using a `.local` domain then yes; it is better to use a real domain and have DNS configured for it 👌
