Created
December 16, 2010 21:37
-
-
Save paykroyd/744065 to your computer and use it in GitHub Desktop.
curl example of how I ran into problems
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ elastic-mappings | |
| % Total % Received % Xferd Average Speed Time Time Time Current | |
| Dload Upload Total Spent Left Speed | |
| 0 2 0 2 0 0 48 0 --:--:-- --:--:-- --:--:-- 50 | |
| {} | |
| $ curl -XPUT 'http://localhost:9200/twitter/' -d ' | |
| > index : | |
| > number_of_shards : 3 | |
| > number_of_replicas : 2 | |
| > ' | |
| {"ok":true,"acknowledged":true}$ | |
| $ elastic-health | |
| % Total % Received % Xferd Average Speed Time Time Time Current | |
| Dload Upload Total Spent Left Speed | |
| 112 225 112 225 0 0 28709 0 --:--:-- --:--:-- --:--:-- 32142 | |
| { | |
| "active_primary_shards": 3, | |
| "active_shards": 3, | |
| "cluster_name": "elasticsearch", | |
| "initializing_shards": 0, | |
| "number_of_data_nodes": 1, | |
| "number_of_nodes": 1, | |
| "relocating_shards": 0, | |
| "status": "yellow", | |
| "timed_out": false, | |
| "unassigned_shards": 6 | |
| } | |
| $ curl -XPUT 'http://localhost:9200/twitter/tweet/_mapping' -d ' | |
| > { | |
| > "tweet-mapping" : { | |
| > "properties" : { | |
| > "message" : {"type" : "string", "store" : "yes"} | |
| > } | |
| > } | |
| > } | |
| > ' | |
| {"ok":true,"acknowledged":true}$ | |
| $ curl -XPUT 'http://localhost:9200/twitter/tweet/1' -d ' | |
| > { | |
| > "user" : "kimchy", | |
| > "postDate" : "2009-11-15T14:12:12", | |
| > "message" : "trying out Elastic Search" | |
| > } | |
| > ' | |
| {"error":"UnavailableShardsException[[twitter][1] [3] shards, [1] active : Timeout waiting for [1m], request: index {[twitter][tweet][1], source[\n{\n \"user\" : \"kimchy\",\n \"postDate\" : \"2009-11-15T14:12:12\",\n \"message\" : \"trying out Elastic Search\"\n}\n]}]"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| $ rm -rf data/elasticsearch/ | |
| $ bin/elasticsearch -f | |
| [2010-12-16 13:35:29,073][INFO ][node ] [Black King] {elasticsearch/0.13.0}[38765]: initializing ... | |
| [2010-12-16 13:35:29,076][INFO ][plugins ] [Black King] loaded [] | |
| [2010-12-16 13:35:30,394][INFO ][node ] [Black King] {elasticsearch/0.13.0}[38765]: initialized | |
| [2010-12-16 13:35:30,394][INFO ][node ] [Black King] {elasticsearch/0.13.0}[38765]: starting ... | |
| [2010-12-16 13:35:30,454][INFO ][transport ] [Black King] bound_address {inet[/0.0.0.0:9300]}, publish_address {inet[/10.0.1.4:9300]} | |
| [2010-12-16 13:35:33,476][INFO ][cluster.service ] [Black King] new_master [Black King][LmLTF2pnTqChG2DloapU_g][inet[/10.0.1.4:9300]], reason: zen-disco-join (elected_as_master) | |
| [2010-12-16 13:35:33,494][INFO ][discovery ] [Black King] elasticsearch/LmLTF2pnTqChG2DloapU_g | |
| [2010-12-16 13:35:33,502][INFO ][http ] [Black King] bound_address {inet[/0.0.0.0:9200]}, publish_address {inet[/10.0.1.4:9200]} | |
| [2010-12-16 13:35:33,503][INFO ][node ] [Black King] {elasticsearch/0.13.0}[38765]: started | |
| [2010-12-16 13:35:45,827][INFO ][cluster.metadata ] [Black King] [twitter] creating index, cause [api], shards [3]/[2], mappings [] | |
| [2010-12-16 13:35:46,180][INFO ][cluster.metadata ] [Black King] [twitter] created and added to cluster_state | |
| [2010-12-16 13:36:00,640][INFO ][cluster.metadata ] [Black King] [twitter] create_mapping [tweet] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment