# Failed to create a new Beat

**URL:** https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675
**Category:** Beats
**Created:** [January 24, 2017, 5:05pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675 "2017-01-24T17:05:57Z")
**Posts on this page:** 15
**Page:** 1

<div class="post-metadata">

### Author: ![romain.dequidt](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/romain.dequidt/32/11809_2.png) [@romain.dequidt](https://discuss.elastic.co/u/romain.dequidt)
#### Post date: [January 24, 2017, 5:05pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/1 "2017-01-24T17:05:57Z")

</div>

Hi,

I tried to follow the instructions from:  
[https://www.elastic.co/guide/en/beats/libbeat/current/newbeat-generate.html](https://www.elastic.co/guide/en/beats/libbeat/current/newbeat-generate.html)

I executed the following command:  
`cookiecutter $GOPATH/src/github.com/elastic/beats/generate/beat`

First time, i got the following error:  
`A valid repository for "$GOPATH/src/github.com/elastic/beats/generate/beat" could not be found in the following locations: $GOPATH/src/github.com/elastic/beats/generate/beat $GOPATH/go/src/github.com/elastic/beats/generate/beat`

So I created a cookiecutter.json file in the "$GOPATH/src/github.com/elastic/beats/generate/beat" directory with few information (i.e. full\_name, email, project\_name...)

And I got another error:  
`cookiecutter.exceptions.NonTemplatedInputDirException`

This error is meaningless for me.

Why does cookiecutter do not prompt information as written in your documnetation?

May you test this procedure?

Version:  
Cookiecutter 1.5.0 from /home/user/.local/lib/python2.7/site-packages (Python 2.7)

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [January 24, 2017, 8:41pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/2 "2017-01-24T20:41:04Z")

</div>

There is something wrong in the documentation. It should state that you have to check out branch 5.1, but I couldn't find it anymore ☹ Have to check what went wrong here.

We remove cookiecutter very recently and are still actively working on making changes. Here is the most recent guide: [https://www.elastic.co/guide/en/beats/libbeat/master/newbeat-generate.html](https://www.elastic.co/guide/en/beats/libbeat/master/newbeat-generate.html)

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [January 24, 2017, 8:47pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/3 "2017-01-24T20:47:27Z")

</div>

Thanks for reporting this. I opened [https://github.com/elastic/beats/pull/3457](https://github.com/elastic/beats/pull/3457) to fix this issue.

Let me know if you have other issues creating a beat.

---

<div class="post-metadata">

### Author: ![romain.dequidt](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/romain.dequidt/32/11809_2.png) [@romain.dequidt](https://discuss.elastic.co/u/romain.dequidt)
#### Post date: [January 25, 2017, 3:25pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/4 "2017-01-25T15:25:28Z")

</div>

> [@ruflin](#):
>
> It should state that you have to check out branch 5.1, but I couldn't find it anymore ☹

It's not in the guide but in the blog:

> **[Build your own Beat](https://www.elastic.co/blog/build-your-own-beat)**

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [January 26, 2017, 12:34pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/5 "2017-01-26T12:34:45Z")

</div>

Yeah, I backported the change to the 5.2 branch but missed the 5.1 branch. Will do that as soon as I get the time for it.

---

<div class="post-metadata">

### Author: ![newcoder99](https://avatars.discourse-cdn.com/v4/letter/n/f475e1/32.png) [@newcoder99](https://discuss.elastic.co/u/newcoder99)
#### Post date: [January 29, 2017, 4:24am UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/6 "2017-01-29T04:24:40Z")

</div>

Hi Ruflin,

There is one point I need to mention regarding the link that you have mentioned to generate new beat.  
As mentioned by your team in the reference URL that we need to execute [beat.py](http://beat.py) to create custom beat, but before executing the python script they need to make one modification based on the python version.

In [helper.py](http://helper.py), they are taking user input using raw\_input method which has become obsolete if you are using Python3.x.

So, before proceeding beat generation, end user should check the [helper.py](http://helper.py) and make necessary modifications based on Python version.

Thanks

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [January 30, 2017, 2:07pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/7 "2017-01-30T14:07:45Z")

</div>

@newcoder99 Thanks for reporting this issue. Could you open a Github issue for that? Our docs state that Python 2.7 is required but we try to keep it compatible with 3.x as obviously lots of people are using 3.x. I hope we can find a fix here that works for 2.7 and 3.x

---

<div class="post-metadata">

### Author: ![Jul\_Kipli](https://avatars.discourse-cdn.com/v4/letter/j/e99b99/32.png) [@Jul\_Kipli](https://discuss.elastic.co/u/Jul_Kipli)
#### Post date: [February 3, 2017, 12:46am UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/8 "2017-02-03T00:46:30Z")

</div>

Make Setup is not working with new version of creating new beat . I have followed below link,  
[https://www.elastic.co/guide/en/beats/libbeat/master/newbeat-generate.html](https://www.elastic.co/guide/en/beats/libbeat/master/newbeat-generate.html)

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [February 3, 2017, 7:26am UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/9 "2017-02-03T07:26:10Z")

</div>

What error do you get?

---

<div class="post-metadata">

### Author: ![Jul\_Kipli](https://avatars.discourse-cdn.com/v4/letter/j/e99b99/32.png) [@Jul\_Kipli](https://discuss.elastic.co/u/Jul_Kipli)
#### Post date: [February 3, 2017, 1:16pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/10 "2017-02-03T13:16:08Z")

</div>

Getting below error, when I do the Make Setup  
usage: cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source\_file target\_file  
cp [-R [-H | -L | -P]] [-fi | -n] [-apvX] source\_file ... target\_directory  
make: \*\*\* [copy-vendor] Error 64

please verify Make file. thanks.

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [February 3, 2017, 2:54pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/11 "2017-02-03T14:54:52Z")

</div>

@Jul_Kipli What is your operating system?

---

<div class="post-metadata">

### Author: ![Jul\_Kipli](https://avatars.discourse-cdn.com/v4/letter/j/e99b99/32.png) [@Jul\_Kipli](https://discuss.elastic.co/u/Jul_Kipli)
#### Post date: [February 3, 2017, 9:02pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/12 "2017-02-03T21:02:01Z")

</div>

Mac OS

---

<div class="post-metadata">

### Author: ![Jul\_Kipli](https://avatars.discourse-cdn.com/v4/letter/j/e99b99/32.png) [@Jul\_Kipli](https://discuss.elastic.co/u/Jul_Kipli)
#### Post date: [February 4, 2017, 2:53pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/13 "2017-02-04T14:53:41Z")

</div>

It is working after i have installed "virtualenv" in on Mac OS.

How do we generate new Beat in Windows environment ? if yes please share me setup or guideline link. thanks.

---

<div class="post-metadata">

### Author: ![ruflin](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ruflin/32/3116_2.png) [@ruflin](https://discuss.elastic.co/u/ruflin)
#### Post date: [February 5, 2017, 6:24pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/14 "2017-02-05T18:24:50Z")

</div>

Glad to hear you got it working.

For the Windows environment, as you realised you can't use the Makefile commands. But the basic structure of a beat is mostly generated by python. What you require afterwards is to call the commands like `go build` manually. Best check out the commands which are executed by the Makefile and see if you can execute them manually on Windows.

It would be nice if we could offer the beat generator in the future also for Windows, so if you go forward with this it would be interesting to hear which roadblocks you hit.

---

<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: [February 14, 2017, 5:05pm UTC](https://discuss.elastic.co/t/failed-to-create-a-new-beat/72675/15 "2017-02-14T17:05:58Z")

</div>

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