Bug 211506 - bsdinstall on 11.0-BETA3 enabled services don't end up in rc.conf
Summary: bsdinstall on 11.0-BETA3 enabled services don't end up in rc.conf
Status: Closed FIXED
Alias: None
Product: Base System
Classification: Unclassified
Component: conf (show other bugs)
Version: 11.0-BETA3
Hardware: Any Any
: --- Affects Many People
Assignee: Dimitry Andric
URL:
Keywords: install
Depends on:
Blocks:
 
Reported: 2016-08-01 18:22 UTC by Dimitry Andric
Modified: 2016-08-04 17:29 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dimitry Andric freebsd_committer freebsd_triage 2016-08-01 18:22:06 UTC
When installing 11.0-BETA3 (on an amd64 VMware guest), the dialog "Choose the services you would like to be started at boot" does not seem to be functional anymore, in the sense that enabled services do NOT end up in the final rc.conf on the target installation.

For example, if I check sshd, ntpd and dumpdev, the final rc.conf becomes:

hostname="beta3test"
ifconfig_em0="DHCP"
ifconfig_em0_ipv6="inet6 accept_rtadv"
zfs_enable="YES"

Note the missing sshd_enable, ntpd_enable and dumpdev settings.  This also applies to Auto UFS setups, where the only difference is that there is no zfs_enable line.
Comment 1 commit-hook freebsd_committer freebsd_triage 2016-08-01 19:50:36 UTC
A commit references this bug:

Author: dim
Date: Mon Aug  1 19:49:43 UTC 2016
New revision: 303631
URL: https://svnweb.freebsd.org/changeset/base/303631

Log:
  Fix non-functional bsdinstall services dialog.

  The most recent version of bsdinstall does not seem to respect any of
  the checkboxes in the "Choose the services you would like to be started
  at boot" dialog.  None of the chosen services end up in the rc.conf file
  that is installed onto the target system.

  This is caused by the bsdinstall/scripts/hardening script, which
  implements the new hardening options dialog.  The script starts by
  overwriting the previously written rc.conf.services file:

      echo -n > $BSDINSTALL_TMPETC/rc.conf.services

  which is obviously incorrect.  It should clear out rc.conf.hardening
  instead.

  Reviewed by:	allanjude
  PR:		211506
  MFC after:	3 days
  Differential Revision: https://reviews.freebsd.org/D7387

Changes:
  head/usr.sbin/bsdinstall/scripts/hardening
Comment 2 Mark Linimon freebsd_committer freebsd_triage 2016-08-02 21:09:23 UTC
Over to committer for possible MFC.
Comment 3 commit-hook freebsd_committer freebsd_triage 2016-08-04 17:27:35 UTC
A commit references this bug:

Author: dim
Date: Thu Aug  4 17:26:33 UTC 2016
New revision: 303749
URL: https://svnweb.freebsd.org/changeset/base/303749

Log:
  MFC r303631:

  Fix non-functional bsdinstall services dialog.

  The most recent version of bsdinstall does not seem to respect any of
  the checkboxes in the "Choose the services you would like to be started
  at boot" dialog.  None of the chosen services end up in the rc.conf file
  that is installed onto the target system.

  This is caused by the bsdinstall/scripts/hardening script, which
  implements the new hardening options dialog.  The script starts by
  overwriting the previously written rc.conf.services file:

      echo -n > $BSDINSTALL_TMPETC/rc.conf.services

  which is obviously incorrect.  It should clear out rc.conf.hardening
  instead.

  Approved by:	re (kib)
  Reviewed by:	allanjude
  PR:		211506
  Differential Revision: https://reviews.freebsd.org/D7387

Changes:
_U  stable/11/
  stable/11/usr.sbin/bsdinstall/scripts/hardening
Comment 4 Dimitry Andric freebsd_committer freebsd_triage 2016-08-04 17:29:32 UTC
Committed to head and merged to stable/11 in time for 11.0-RELEASE.