Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add setup script for elasticsearch, influxdb, redis #7

Merged
merged 4 commits into from
Nov 12, 2016
Merged

Conversation

czheo
Copy link
Collaborator

@czheo czheo commented Nov 12, 2016

Add setup script for elasticsearch, influxdb, redis.
works on Linux only.

# https://hub.docker.com/_/elasticsearch/


sysctl -w vm.max_map_count=262144
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why this is needed? does it require sudo?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, sudo is required.
elasticsearch checks max map count. without this, it won't boot up correctly.
https://www.elastic.co/guide/en/elasticsearch/reference/5.0/_maximum_map_count_check.html

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ideal situation is check max_map_count size before ask sudo to change it just cat /proc/sys/vm/max_map_count will give you the value. though some transformation need to be made in shell. Anyway since *nix won't ask pwd for sudo in same shell, it's not a big deal.


docker run -p 9200:9200 -p 9300:9300 \
-e ES_JAVA_OPTS="-Xms${jvm_mem}m -Xmx${jvm_mem}m" \
elasticsearch
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

specify the version, same as influx and redis, though using latest is not that bad, but I don't want fetch the newest one, a working (most commonly used) one is enough

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fixed.

@at15
Copy link
Member

at15 commented Nov 12, 2016

tested locally

LGTM

@at15 at15 merged commit f001c60 into master Nov 12, 2016
@at15
Copy link
Member

at15 commented Nov 12, 2016

oops, some small problems @czheo

  • update the readme file in script folder
  • are we going to write all the time series logic for redis in our benchmark tool? if so how? following sentry or the redislab tech guide?

Thx

@czheo
Copy link
Collaborator Author

czheo commented Nov 12, 2016

are we going to write all the time series logic for redis in our benchmark tool?

yes. we have to

if so how? following sentry or the redislab tech guide?

depends on what operations you'd like to cover.
Now, we only cover "count" and "moving avg".
count is native in redis.
we need find some sample to implement moving avg. any sample is fine to make a comparison.
Such as:
https://redislabs.com/ebook/redis-in-action/part-2-core-concepts-2/chapter-5-using-redis-for-application-support/5-2-counters-and-statistics/5-2-2-storing-statistics-in-redis
https://www.redisgreen.net/library/runningavg.html

@at15
Copy link
Member

at15 commented Nov 12, 2016

@czheo I think sentry have some existing logic https://github.com/getsentry/sentry/tree/master/src/sentry/tsdb

@at15 at15 mentioned this pull request Nov 12, 2016
8 tasks
@czheo
Copy link
Collaborator Author

czheo commented Nov 12, 2016

@at15 didn't find moving avg in their code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants