Set environment variable globally

Gunnar Hjalmarsson gunnarhj at
Fri Mar 31 15:28:24 UTC 2017

On 2017-03-24 22:19, Andrew Martin wrote:
> I recently saw this blog post regarding performance when the TZ
> environment variable is not set:
> I have noticed this problem when stracing running daemons on my
> systems and would like to fix it. I reviewed the official Ubuntu
> documentation for where to define environment variables:
> I tried defining TZ in /etc/environment and in
> /etc/profile.d/, but I cannot get this environment variable to
> be available in all cases (e.g. if I just execute bash without
> --login or if I run the sample c program provided in the above
> article). How can I make the TZ environment variable defined
> completely system-wide?

Also asked at <>.

Gunnar Hjalmarsson

More information about the Ubuntu-devel-discuss mailing list