# Libbeat syntax error logger.go

**URL:** <https://discuss.elastic.co/t/libbeat-syntax-error-logger-go/131704>\
**Category:** Beats\
**Created:** [May 14, 2018, 9:29am UTC](https://discuss.elastic.co/t/libbeat-syntax-error-logger-go/131704 "2018-05-14T09:29:45Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![gourmax](https://avatars.discourse-cdn.com/v4/letter/g/eb9ed0/32.png) [@gourmax](https://discuss.elastic.co/u/gourmax)\
**Post date:** [May 14, 2018, 9:29am UTC](https://discuss.elastic.co/t/libbeat-syntax-error-logger-go/131704/1 "2018-05-14T09:29:45Z")

</div>

I'm trying to install a package from beat community but I encounter a syntax error in some file from the github folder of elastic.

According to example on the elastic page, I cloned the elastic/beats directory.  
I try to install metricbeat (the error is the same for other package) with:

go install [github.com/elastic/beats/metricbeat](http://github.com/elastic/beats/metricbeat)

But I receive the following error

> [github.com/elastic/beats/libbeat/logp/logger.go:8:](http://github.com/elastic/beats/libbeat/logp/logger.go:8:) syntax error: unexpected = in type declaration

I don't know how what is the right declaration of this variable in logger.go.

---

<div class="post-metadata">

**Author:** ![adrisr](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/adrisr/32/25423_2.png) [@adrisr](https://discuss.elastic.co/u/adrisr)\
**Post date:** [May 14, 2018, 10:38am UTC](https://discuss.elastic.co/t/libbeat-syntax-error-logger-go/131704/2 "2018-05-14T10:38:45Z")

</div>

The version of Go that you are using is too old. You need at least Go 1.9.

You can check your go version with the `go version` command.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [June 11, 2018, 9:29am UTC](https://discuss.elastic.co/t/libbeat-syntax-error-logger-go/131704/3 "2018-06-11T09:29:52Z")

</div>

This topic was automatically closed after 28 days. New replies are no longer allowed.
