Bug 907

Summary: "sudo -i" without pam support emits "sudo: /etc/environment: No such file or directory"
Product: Sudo Reporter: Lars Wendler <polynomial-c>
Component: SudoAssignee: Todd C. Miller <Todd.Miller>
Status: RESOLVED FIXED    
Severity: normal    
Priority: low    
Version: 1.8.29   
Hardware: PC   
OS: Linux   

Description Lars Wendler 2019-11-06 09:32:19 MST
If you build sudo-1.8.28 or greater without pam support, "sudo -i" emits the following message:

  ~ $ sudo -i
  sudo: /etc/environment: No such file or directory

Of course this only happens on a system without linux-pam package being installed which provides the /etc/environment file (required for the pam_env module).

See Gentoo downstream bug report: https://bugs.gentoo.org/698946
Comment 1 Todd C. Miller 2019-11-06 09:55:47 MST
I just committed a fix for this: https://www.sudo.ws/repos/sudo/rev/f85ff5ee2caf
Comment 2 Lars Wendler 2019-11-07 04:22:29 MST
Our downstream bug reporter has confirmed the fix works and thus we have closed the downstream bug.
Comment 3 Todd C. Miller 2019-12-31 15:08:05 MST
Fixed in sudo 1.8.30