[ 
https://issues.apache.org/jira/browse/IMPALA-9145?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17060482#comment-17060482
 ] 

Shant Hovsepian commented on IMPALA-9145:
-----------------------------------------

On some newer systems like Ubuntu /etc/localtime is a symlink to another 
symlink which points to posixrules.

TimezoneDatabase::LocalZoneName() can be modified to use the relative path of 
the symlink via readlink instead of realpath to handle this case.

Similar to the fix hereĀ 
[https://github.com/HowardHinnant/date/commit/5f49afc1e913cdd95443a840c2cf1f22353c88c3]

A workaround is to set the TZ environment variable on the system to the proper 
timezone so /etc/localtime isn't checked.

> Compute stats fails with invalid timezone
> -----------------------------------------
>
>                 Key: IMPALA-9145
>                 URL: https://issues.apache.org/jira/browse/IMPALA-9145
>             Project: IMPALA
>          Issue Type: Bug
>    Affects Versions: Impala 3.3.0
>            Reporter: Aman Sinha
>            Priority: Major
>
> On my Ubuntu machine with latest Impala build I get the following error:
> {noformat}
> [localhost:21000] tpch> compute stats lineitem;
> Query: compute stats lineitem
> ERROR: Invalid timezone name 'posixrules'. {noformat}
> This causes a bunch of unit tests that rely on stats to fail. 
> After setting the TIMEZONE explicitly, this works: 
> {noformat}
> localhost:21000] tpch> set TIMEZONE=America/Los_Angeles;
> TIMEZONE set to America/Los_Angeles
> [localhost:21000] tpch> compute stats lineitem;
> Query: compute stats lineitem
> +------------------------------------------+
> | summary                                  |
> +------------------------------------------+
> | Updated 1 partition(s) and 16 column(s). |
> +------------------------------------------+
> {noformat}
> My /etc/timezone has a valid timezone:
> {noformat}
> $ cat /etc/timezone
> America/New_York
> {noformat}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to