How do I permanently unset an environment variable in Linux?

Đạt Michio

New member
How do I permanently unset an environment variable in Linux?
Answer
Once removing the line from the file, log out, and log back in (if in a terminal, just close the terminal and reopen it). If it was in /etc/environment then
consider rebooting the system first
. With the export line gone, the variable will be ‘permanently unset’ until the line is readded to one of those files.
 

Tìm kiếm

Back
Top