# Node name setting

**URL:** <https://discuss.elastic.co/t/node-name-setting/11754>\
**Category:** Elasticsearch\
**Created:** [April 30, 2013, 8:04pm UTC](https://discuss.elastic.co/t/node-name-setting/11754 "2013-04-30T20:04:33Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![brian\_yoder](https://avatars.discourse-cdn.com/v4/letter/b/f1d935/32.png) [@brian\_yoder](https://discuss.elastic.co/u/brian_yoder)\
**Post date:** [April 30, 2013, 8:04pm UTC](https://discuss.elastic.co/t/node-name-setting/11754/1 "2013-04-30T20:04:33Z")

</div>

The node name can be set, but the value of the node parameter seems to be  
assigned to a long random string. Is it possible to change that also?

When adding the following string to the elasticsearch startup ES\_JAVA\_OPTS,  
I am able to assign a node name to the host name (without domain  
information if present):

"-Des.node.name=$(uname -n | cut -d'.' -f1)"

So, for example, using ElasticSearch Head, I see the host names (very nice)  
but also a long random-looking routing name for each node:

testdev12 lt-8dXstR7CM\_ILIyRcv7w  
inet[/192.168.200.222:9200]

testdev29 _SO7tHyTsQqGZC0lh5fb1AA_  
inet[/192.168.200.241:9200]

testdev33 0ONh96ZpQyueFWqNoEgpeQ  
inet[/192.168.200.133:9200]

And for shard 0 on testdev29, I see the following:

{  
routing: {  
state: STARTED  
primary: false  
_node: SO7tHyTsQqGZC0lh5fb1AA_  
relocating\_node: null  
shard: 0  
index: lidb  
}  
state: STARTED  
index: {  
size: 2.4mb  
size\_in\_bytes: 2534149  
}  
translog: {  
id: 1367266032434  
operations: 0  
}  
docs: {  
num\_docs: 5232  
max\_doc: 5232  
deleted\_docs: 0  
}  
merges: {  
current: 0  
current\_docs: 0  
current\_size: 0b  
current\_size\_in\_bytes: 0  
total: 0  
total\_time: 0s  
total\_time\_in\_millis: 0  
total\_docs: 0  
total\_size: 0b  
total\_size\_in\_bytes: 0  
}  
refresh: {  
total: 0  
total\_time: 0s  
total\_time\_in\_millis: 0  
}  
flush: {  
total: 4  
total\_time: 2ms  
total\_time\_in\_millis: 2  
}  
}

Is there some way to get node: SO7tHyTsQqGZC0lh5fb1AA to display as node:  
{hostname} or node: {IP} or some other unique but more easily identifiable  
string?

--  
You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
For more options, visit [https://groups.google.com/groups/opt\_out](https://groups.google.com/groups/opt_out).

---

<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:** [July 6, 2017, 2:39am UTC](https://discuss.elastic.co/t/node-name-setting/11754/2 "2017-07-06T02:39:00Z")

</div>


