diff options
author | Renato Botelho <renato@netgate.com> | 2016-07-14 12:15:58 -0300 |
---|---|---|
committer | Renato Botelho <renato@netgate.com> | 2016-07-14 12:15:58 -0300 |
commit | e18eadcca2aa608f49364dd78eb9c6fe96a70c09 (patch) | |
tree | f25ca34b90cd7c3c51bf262ba1dd5d32119d4b8f /src/usr/local | |
parent | c323224dac91388e4d9fc237e7c725b2119dc395 (diff) | |
download | pfsense-e18eadcca2aa608f49364dd78eb9c6fe96a70c09.zip pfsense-e18eadcca2aa608f49364dd78eb9c6fe96a70c09.tar.gz |
Ignore cp result for cases when files are the same. Ticket #6557
Diffstat (limited to 'src/usr/local')
-rwxr-xr-x | src/usr/local/sbin/pfSense-upgrade | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/usr/local/sbin/pfSense-upgrade b/src/usr/local/sbin/pfSense-upgrade index 44b0f95..c3d3c73 100755 --- a/src/usr/local/sbin/pfSense-upgrade +++ b/src/usr/local/sbin/pfSense-upgrade @@ -550,7 +550,9 @@ setup_nanobsd_env() { _exec "mount /dev/${_update_partition} ${chroot_dir}" "Mounting second partition to run upgrade" mute # Make sure resolv.conf is present, otherwise upgrade may fail (bug #6557) - _exec "cp -f /etc/resolv.conf ${chroot_dir}/etc" "Copying resolv.conf to upgrade partition" mute + local _resolv_conf=$(readlink -f /etc/resolv.conf) + _exec "cp -f ${_resolv_conf} ${chroot_dir}/etc/resolv.conf" \ + "Copying resolv.conf to upgrade partition" mute ignore_result sed -i '' -e "s,^${_cur_partition},/dev/${_update_partition}," \ ${chroot_dir}/etc/fstab |