Project

General

Profile

Actions

Bug #6557

closed

nanobsd upgrades may fail from lacking resolv.conf

Added by Chris Buechler over 5 years ago. Updated about 5 years ago.

Status:
Resolved
Priority:
High
Category:
Upgrade
Target version:
Start date:
06/28/2016
Due date:
% Done:

100%

Estimated time:
Plus Target Version:
Release Notes:
Affected Version:
2.3.x
Affected Architecture:

Description

resolv.conf may not exist or be populated in the chroot of nanobsd upgrades on 2.3.x+. pkg uses that for fetching the files, so in that case, the upgrade will fail by being unable to fetch the pkg files.

Actions #1

Updated by Chris Buechler over 5 years ago

The situation where they fail is where DNS Forwarder or Resolver are not bound to localhost. If resolv.conf doesn't exist, FreeBSD uses 127.0.0.1. Thanks to cjl for tracking that down.

Actions #2

Updated by Renato Botelho over 5 years ago

  • Status changed from Confirmed to Feedback
  • % Done changed from 0 to 100
Actions #3

Updated by Renato Botelho over 5 years ago

  • Assignee set to Renato Botelho
Actions #4

Updated by Chris Buechler over 5 years ago

  • Target version changed from 2.3.1-p6 to 2.3.2
Actions #5

Updated by Chris Buechler over 5 years ago

  • Status changed from Feedback to Resolved

confirmed fixed on multiple upgrades

Actions #6

Updated by Andrew Hotlab about 5 years ago

Sorry, but it seems not to be solved. I just upgraded from 2.3.2 to 2.3.2-p1 (NanoBSD) and the procedure still hangs on the resolv.conf problem.

I solved with the following lines:

local _resolv_conf=$(readlink -f /etc/resolv.conf)
_exec "unlink ${chroot_dir}/etc/resolv.conf" mute ignore_result
_exec "cp -f ${_resolv_conf} ${chroot_dir}/etc/resolv.conf" \
"Copying resolv.conf to upgrade partition" mute ignore_result

Actions

Also available in: Atom PDF