Bugzilla – Bug 429
Missing mkdir of /etc/sudoers.d in installer for security/sudo port
Last modified: 2010-08-18 19:17:25 MDT
http://forums.freebsd.org/showthread.php?p=97892#post97892 From a fresh install of FreeBSD 8.1-RELEASE amd64, installing sudo from the security/sudo port does not create /etc/sudoers.d, which is included by the default config file: (Relevant line in default /usr/local/etc/sudoers) ## Read drop-in files from /etc/sudoers.d (the # here does not mean a comment) #includedir /etc/sudoers.d (Initial error after installation) >>> /usr/local/etc/sudoers: /etc/sudoers.d near line 97 <<< sudo: parse error in /usr/local/etc/sudoers near line 97 sudo: no valid sudoers sources found, quitting These errors go away after creating /etc/sudoers.d, or by removing the line from the config.
Sudo creates that directory as part of "make install". The problem is that the value of sysconfdir is not substituted into the sudoers file. This means that if sysconfdir is changed from the default (/etc) the path in sudoers won't match what "make install" creates. I've fixed this in the sudo source repo and the change will be in sudo 1.7.4p3.
Fixed in sudo 1.7.4p3, available now.