You have been subscribed to a public bug by Eric Desrochers (slashd): This is the same issue reported in https://bugs.launchpad.net/ubuntu/+source/preseed/+bug/1452202 However that is marked as 'Fix Released' and the issue is still occurring so it seems best to just open a new bug according to Eric's comment.
The present hostname preseed regex looks like: if ! echo "$RET" | grep -q 'ubuntu'; then ... /bin/sed -i "s/$CURRENT_HOSTNAME/$NETCFG_HOSTNAME/" /etc/hosts ... fi There are still multiple problems with them according to Peter's comment (https://bugs.launchpad.net/ubuntu/+source/preseed/+bug/1452202/comments/64) and Mathieu's comment (https://bugs.launchpad.net/ubuntu/+source/preseed/+bug/1452202/comments/93). - The default hostname is 'ubuntu', and is the value you will get if nothing is preseeded -- we *do* need to skip it in this case, although the grep may need to be more precise. A name like 'ubuntuxenial' should match this grep. - The sed needs to be fixed to more appropriately catch for the exact string, rather than any substring -- ie. it should not match 'ipv6-allnodes' if the name received from DHCP was 'node'. It should only match and replace for 'node'. So the fix will try to: 1) Keep the if statement and add the -w option to grep to be more robust 2) Modify the sed cmd with word boundaries (\b) to be more robust as well. ** Affects: preseed (Ubuntu) Importance: Medium Assignee: Hua Zhang (zhhuabj) Status: Confirmed ** Affects: preseed (Ubuntu Trusty) Importance: Medium Assignee: Hua Zhang (zhhuabj) Status: Confirmed ** Affects: preseed (Ubuntu Xenial) Importance: Medium Assignee: Hua Zhang (zhhuabj) Status: Confirmed ** Affects: preseed (Ubuntu Bionic) Importance: Medium Assignee: Hua Zhang (zhhuabj) Status: Confirmed ** Tags: sts -- Reinforce hostname preseed regex https://bugs.launchpad.net/bugs/1745531 You received this bug notification because you are a member of STS Sponsors, which is subscribed to the bug report. -- Mailing list: https://launchpad.net/~sts-sponsors Post to : [email protected] Unsubscribe : https://launchpad.net/~sts-sponsors More help : https://help.launchpad.net/ListHelp

