Bug 907 - "sudo -i" without pam support emits "sudo: /etc/environment: No such file or directory"
"sudo -i" without pam support emits "sudo: /etc/environment: No such file or ...
Status: RESOLVED FIXED
Product: Sudo
Classification: Unclassified
Component: Sudo
1.8.29
PC Linux
: low normal
Assigned To: Todd C. Miller
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2019-11-06 09:32 MST by Lars Wendler
Modified: 2019-12-31 15:08 MST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
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