# ReST input creation: Address already in use

**URL:** <https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175>\
**Category:** Graylog Central (peer support)\
**Created:** [October 8, 2018, 9:53am UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175 "2018-10-08T09:53:26Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![gianluca-valentini](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gianluca-valentini/32/1592_2.png) [@gianluca-valentini](https://community.graylog.org/u/gianluca-valentini)\
**Post date:** [October 8, 2018, 9:53am UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/1 "2018-10-08T09:53:26Z")

</div>

Hi,  
I’m using Graylog OVA 2.4.3 and when I try to create Input using ReST, Graylog shows the created Inputs marked as Failed: The message that I see is: **Address already in use**.

![image](https://us1.discourse-cdn.com/flex016/uploads/graylog/original/2X/e/e6fc1e02b2b20403f4d21b33fcc4f2788ab0366f.jpeg)

Here the JSon about the related input:

> {
> 
> "title": "test\_6f1c06e2-e27c-4c41-a577-bd17f37c3547",
> 
> "global": true,
> 
> "name": "Beats",
> 
> "content\_pack": "5bbb21bd1838ed2ce0d6524e",
> 
> "created\_at": "2018-10-08T09:22:04.207Z",
> 
> "type": "org.graylog.plugins.beats.BeatsInput",
> 
> "creator\_user\_id": "admin",
> 
> "attributes": {
> 
> "recv\_buffer\_size": 1048576,
> 
> "port": 12202,
> 
> "tls\_key\_file": "",
> 
> "tls\_enable": false,
> 
> "tls\_key\_password": "",
> 
> "tcp\_keepalive": false,
> 
> "tls\_client\_auth\_cert\_file": "",
> 
> "tls\_client\_auth": "disabled",
> 
> "override\_source": "",
> 
> "bind\_address": "0.0.0.0",
> 
> "tls\_cert\_file": ""
> 
> },
> 
> "static\_fields": {
> 
> "ENABLE\_ENRICH": "false",
> 
> "entity\_name": "NONE",
> 
> "tags": "test\_6f1c06e2-e27c-4c41-a577-bd17f37c3547"
> 
> },
> 
> "node": null,
> 
> "id": "5bbb21bc9fb73040f9349195"
> 
> },  
> The port number is **12202**

Executing netstat -plnt I can see the result below

 ![image](https://us1.discourse-cdn.com/flex016/uploads/graylog/original/2X/b/bf637770c2f2961d4eeb7ae7b5198d2a6760bc6d.png)

All seems correct, but Graylog give me the error message.  
Looking the log file we can see the stack trace:

> 2018-10-08\_09:22:51.44381 ERROR [InputLauncher] The [org.graylog.plugins.beats.BeatsInput] input with ID \<5bbb21bc9fb73040f9349195\> misfired. Reason: Address already in use.  
> 2018-10-08\_09:22:51.44430 org.graylog2.plugin.inputs.MisfireException: org.graylog2.plugin.inputs.MisfireException: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:12202  
> 2018-10-08\_09:22:51.44485 at org.graylog2.plugin.inputs.MessageInput.launch(MessageInput.java:158) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.44569 at org.graylog2.shared.inputs.InputLauncher$1.run(InputLauncher.java:84) [graylog.jar:?]  
> 2018-10-08\_09:22:51.44616 at com.codahale.metrics.InstrumentedExecutorService$InstrumentedRunnable.run(InstrumentedExecutorService.java:176) [graylog.jar:?]  
> 2018-10-08\_09:22:51.44721 at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0\_161]  
> 2018-10-08\_09:22:51.44763 at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0\_161]  
> 2018-10-08\_09:22:51.44805 at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0\_161]  
> 2018-10-08\_09:22:51.44877 at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0\_161]  
> 2018-10-08\_09:22:51.44965 at java.lang.Thread.run(Thread.java:748) [?:1.8.0\_161]  
> 2018-10-08\_09:22:51.45498 Caused by: org.graylog2.plugin.inputs.MisfireException: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:12202  
> 2018-10-08\_09:22:51.45539 at org.graylog2.plugin.inputs.transports.NettyTransport.launch(NettyTransport.java:155) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.45600 at org.graylog2.plugin.inputs.MessageInput.launch(MessageInput.java:155) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.45675 … 7 more  
> 2018-10-08\_09:22:51.45721 Caused by: org.jboss.netty.channel.ChannelException: Failed to bind to: /0.0.0.0:12202  
> 2018-10-08\_09:22:51.45793 at org.jboss.netty.bootstrap.ServerBootstrap.bind(ServerBootstrap.java:272) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.46060 at org.graylog2.plugin.inputs.transports.NettyTransport.launch(NettyTransport.java:141) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.46179 at org.graylog2.plugin.inputs.MessageInput.launch(MessageInput.java:155) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.46210 … 7 more  
> 2018-10-08\_09:22:51.46263 Caused by: java.net.BindException: Address already in use  
> 2018-10-08\_09:22:51.46438 at sun.nio.ch.Net.bind0(Native Method) ~[?:1.8.0\_161]  
> 2018-10-08\_09:22:51.46507 at sun.nio.ch.Net.bind(Net.java:433) ~[?:1.8.0\_161]  
> 2018-10-08\_09:22:51.46688 at sun.nio.ch.Net.bind(Net.java:425) ~[?:1.8.0\_161]  
> 2018-10-08\_09:22:51.46744 at sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:223) ~[?:1.8.0\_161]  
> 2018-10-08\_09:22:51.46870 at sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:74) ~[?:1.8.0\_161]  
> 2018-10-08\_09:22:51.47187 at org.jboss.netty.channel.socket.nio.NioServerBoss$RegisterTask.run(NioServerBoss.java:193) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47258 at org.jboss.netty.channel.socket.nio.AbstractNioSelector.processTaskQueue(AbstractNioSelector.java:391) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47336 at org.jboss.netty.channel.socket.nio.AbstractNioSelector.run(AbstractNioSelector.java:315) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47365 at org.jboss.netty.channel.socket.nio.NioServerBoss.run(NioServerBoss.java:42) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47417 at org.jboss.netty.util.ThreadRenamingRunnable.run(ThreadRenamingRunnable.java:108) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47495 at org.jboss.netty.util.internal.DeadLockProofWorker$1.run(DeadLockProofWorker.java:42) ~[graylog.jar:?]  
> 2018-10-08\_09:22:51.47566 … 3 more  
> 2018-10-08\_09:22:51.47672 INFO [InputStateListener] Input [Beats/5bbb21bc9fb73040f9349195] is now FAILED

If I **restart Graylog** the Input become **valid** , without changes!!  
Is there something that I can do to fix this problem?

Why at the first time, Graylog say me that the input is not valid but after restarting the server, the input become good?

Gianluca

---

<div class="post-metadata">

**Author:** ![jan](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/jan/32/11_2.png) [@jan](https://community.graylog.org/u/jan)\
**Post date:** [October 8, 2018, 1:58pm UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/2 "2018-10-08T13:58:20Z")

</div>

Have you tried if that is happening with the latest stable release too?

(2.4.6 at time of writing)

---

<div class="post-metadata">

**Author:** ![gianluca-valentini](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gianluca-valentini/32/1592_2.png) [@gianluca-valentini](https://community.graylog.org/u/gianluca-valentini)\
**Post date:** [October 8, 2018, 2:46pm UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/3 "2018-10-08T14:46:11Z")

</div>

Hi @jan  
currently I cannot upgrade my Graylog env to the last version (2.4.6).  
So I can not give you an answer

---

<div class="post-metadata">

**Author:** ![gianluca-valentini](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gianluca-valentini/32/1592_2.png) [@gianluca-valentini](https://community.graylog.org/u/gianluca-valentini)\
**Post date:** [October 8, 2018, 3:35pm UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/4 "2018-10-08T15:35:01Z")

</div>

Any suggestions to understand what happened?

---

<div class="post-metadata">

**Author:** ![gianluca-valentini](https://sea2.discourse-cdn.com/flex016/user_avatar/community.graylog.org/gianluca-valentini/32/1592_2.png) [@gianluca-valentini](https://community.graylog.org/u/gianluca-valentini)\
**Post date:** [October 9, 2018, 12:12pm UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/5 "2018-10-09T12:12:28Z")

</div>

Hi @jan  
I update the env to the latest version (v 2.4.6) and I have the same problem.

Do you have any suggestions?

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex016/uploads/graylog/original/3X/c/7/c7c09c6b5099570133d6502b83f50ba4430de5b6.png) [@system](https://community.graylog.org/u/system)\
**Post date:** [October 23, 2018, 12:12pm UTC](https://community.graylog.org/t/rest-input-creation-address-already-in-use/7175/6 "2018-10-23T12:12:33Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
