# PYNQ 2.5.1 build: Error in link resolv.conf after chroot

**URL:** <https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238>\
**Category:** Support\
**Created:** [May 8, 2020, 9:53am UTC](https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238 "2020-05-08T09:53:29Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![KVWZ](https://avatars.discourse-cdn.com/v4/letter/k/b5ac83/32.png) [@KVWZ](https://discuss.pynq.io/u/KVWZ)\
**Post date:** [May 8, 2020, 9:53am UTC](https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238/1 "2020-05-08T09:53:29Z")

</div>

Dear,

I am trying to build PYNQ on a custom board (Ultrazed EV) using a Ubuntu 18.04 machine.  
I downloaded the ubuntu sysroot and pynq source distributions.

Running the following

make PYNQ\_SDIST=/home/user/repos/Pynq/sdbuild/pynq-2.5.tar.gz PREBUILT=/home/user/repos/Pynq/sdbuild/bionic.aarch64.2.5.img BOARDS=uz7ev\_evcc

results in a premature exit of the script when a [github.com](http://github.com) cannot be referenced after chroot in the VM.  
When I exit the script, change root by hand and update resolv.conf, [github.com](http://github.com) can be resolved by the git tool.

I tried downloading and decompressing pynq\_rootfs\_aarch64\_v2.5.zip again, but the same results are obtained.

Can you help me on this one?

 ![image](https://us1.discourse-cdn.com/flex019/uploads/pynq1/original/1X/a9208d9f0f940beb6b3a45194bc6252ea39b3214.png)

---

<div class="post-metadata">

**Author:** ![PeterOgden](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/peterogden/32/55_2.png) [@PeterOgden](https://discuss.pynq.io/u/PeterOgden)\
**Post date:** [May 8, 2020, 10:07am UTC](https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238/2 "2020-05-08T10:07:13Z")

</div>

Can you see where `/etc/resolv.conf` links to on the host? The chroot assumes that it links to `/run/resolvconf/resolv.conf` so you might need to create a symlink there to the correct place. Depending on network configuration and Linux version this file appears to move.

Peter

---

<div class="post-metadata">

**Author:** ![KVWZ](https://avatars.discourse-cdn.com/v4/letter/k/b5ac83/32.png) [@KVWZ](https://discuss.pynq.io/u/KVWZ)\
**Post date:** [May 8, 2020, 2:00pm UTC](https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238/3 "2020-05-08T14:00:21Z")

</div>

Hi Peter,

Thank you for pointing this out to me, I did not see it.  
On my host resolv.conf points to …/run/systemd/resolve/stub-resolv.conf

When I \<sudo mkdir /run/resolvconf\> and \<sudo cp /etc/resolv.conf /run/resolvconf/resolv.conf\> after a reboot and attempt again, the build completes.

---

<div class="post-metadata">

**Author:** ![rock](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/rock/32/32_2.png) [@rock](https://discuss.pynq.io/u/rock)\
**Post date:** [May 11, 2020, 7:51pm UTC](https://discuss.pynq.io/t/pynq-2-5-1-build-error-in-link-resolv-conf-after-chroot/1238/4 "2020-05-11T19:51:12Z")

</div>

Yes we have seen that as well. You probably need [PYNQ/setup\_host.sh at master · Xilinx/PYNQ · GitHub](https://github.com/Xilinx/PYNQ/blob/master/sdbuild/scripts/setup_host.sh#L137)

to make it work. We will fix this in next release. Thanks.
