title: unknown timezone 'localtime'
body: <p>I think I have done everything right, but why am I getting this:</p>
  
  <pre><code>&gt; Sys.time()
  [1] "2015-11-09 18:51:17 UTC"
  Warning messages:
  1: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'localtime'
  2: In as.POSIXlt.POSIXct(x, tz) : unknown timezone 'localtime'
  &gt; 
  </code></pre>
  
  <p>Operating system is Windows Server 2012 (an Azure VM actually). I have set my timezone to be UTC with the <code>TZ</code> environment variable:</p>
  
  <p><a href="https://i.stack.imgur.com/ivVCO.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/ivVCO.png" alt="enter image description here"></a></p>
  
  <p>The <code>Sys.timezone</code> apparently sees it:</p>
  
  <pre><code>&gt; Sys.timezone()
  [1] "UTC"
  &gt; 
  </code></pre>
  
  <p>And it is even listed in my <code>OlsonNames()</code>:</p>
  
  <p><a href="https://i.stack.imgur.com/Oir2Q.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Oir2Q.png" alt="enter image description here"></a></p>
  
  <p>I get tons of these error messages in my markdown, and it is driving me crazy. Ominously, I noticed the other SO links related to this frequently are unresolved.</p>
  
  <p><strong>Update</strong> - per request I am adding <code>sessionInfo()</code> output:</p>
  
  <pre><code>&gt; sessionInfo()
  R version 3.2.2 (2015-08-14)
  Platform: x86_64-w64-mingw32/x64 (64-bit)
  Running under: Windows Server 2012 x64 (build 9200)
  
  locale:
  [1] LC_COLLATE=English_United States.1252 
  [2] LC_CTYPE=English_United States.1252   
  [3] LC_MONETARY=English_United States.1252
  [4] LC_NUMERIC=C                          
  [5] LC_TIME=English_United States.1252    
  
  attached base packages:
  [1] stats     graphics  grDevices utils     datasets  methods   base     
  
  loaded via a namespace (and not attached):
  [1] htmltools_0.2.6 tools_3.2.2     yaml_2.1.13     rmarkdown_0.8.1
  [5] digest_0.6.8   
  &gt; 
  </code></pre>
  
  <p>and a traceback:</p>
  
  <pre><code>&gt; options(warn=2)
  &gt; Sys.time()
  Error in as.POSIXlt.POSIXct(x, tz) : 
    (converted from warning) unknown timezone 'localtime'
  &gt; traceback()
  13: doWithOneRestart(return(expr), restart)
  12: withOneRestart(expr, restarts[[1L]])
  11: withRestarts({
          .Internal(.signalCondition(simpleWarning(msg, call), msg, 
              call))
          .Internal(.dfltWarn(msg, call))
      }, muffleWarning = function() NULL)
  10: .signalSimpleWarning("unknown timezone 'localtime'", quote(as.POSIXlt.POSIXct(x, 
          tz)))
  9: as.POSIXlt.POSIXct(x, tz)
  8: as.POSIXlt(x, tz)
  7: format.POSIXlt(as.POSIXlt(x, tz), format, usetz, ...)
  6: structure(format.POSIXlt(as.POSIXlt(x, tz), format, usetz, ...), 
         names = names(x))
  5: format.POSIXct(x, usetz = TRUE)
  4: format(x, usetz = TRUE)
  3: print(format(x, usetz = TRUE), ...)
  2: print.POSIXct(x)
  1: function (x, ...) 
     UseMethod("print")(x)
  &gt; 
  </code></pre>
  
  <p><strong>Update</strong> more info:
  <a href="https://i.stack.imgur.com/CsMYa.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/CsMYa.png" alt="enter image description here"></a></p>