{"id":678,"date":"2011-05-31T22:44:31","date_gmt":"2011-06-01T02:44:31","guid":{"rendered":"http:\/\/hstore.cs.brown.edu\/?page_id=678"},"modified":"2012-03-14T11:52:47","modified_gmt":"2012-03-14T15:52:47","slug":"cluster-file","status":"publish","type":"page","link":"https:\/\/hstore.cs.brown.edu\/documentation\/configuration\/cluster-file\/","title":{"rendered":"Cluster Configuration File"},"content":{"rendered":"

\u00ab<\/B> Site Parameters<\/a><\/div>
Debugging<\/a> \u00bb<\/B><\/div>
<\/div><\/p>\n

The H-Store<\/b> cluster configuration file defines what nodes will be used in a benchmark run for the database. H-Store assumes that each of these nodes has passwordless SSH logins enabled<\/a>. Note that the cluster configuration file is different from where the benchmark clients will run.<\/p>\n

By default, hstore-prepare<\/tt> creates a catalog with a cluster of only one host (global.defaulthost<\/a>) two sites, each with two partitions. You can create a custom specification file that defines the host\/site\/partition layout of the target cluster. This specification file should be a plain text file, where each line contains a triplet HOSTNAME:SITE#:PARTITION#<\/tt>. The following is an example of how to create a cluster configuration with two hosts (i.e., host0.cs.brown.edu<\/tt> and host1.cs.brown.edu<\/tt>), where host0.cs.brown.edu<\/tt> only has one site with two partitions and host1.cs.brown.edu<\/tt> has two sites each with one partition:<\/p>\n

\r\nhost0.cs.brown.edu:0:0\r\nhost0.cs.brown.edu:0:1\r\nhost1.cs.brown.edu:1:2\r\nhost1.cs.brown.edu:1:3\r\nhost1.cs.brown.edu:2:4\r\nhost1.cs.brown.edu:1:5\r\nhost1.cs.brown.edu:2:6\r\nhost1.cs.brown.edu:2:7\r\n<\/pre>\n

Alternatively, you can specify the partitions at each site using non-overlapping ranges or comma-delimited lists:<\/p>\n

\r\nhost0.cs.brown.edu:0:0-1\r\nhost1.cs.brown.edu:1:2,3,5\r\nhost1.cs.brown.edu:2:4,6-7\r\n<\/pre>\n

Note that both the site numbers and partition numbers start at zero. The partition number should always be unique. This file can now be passed in as the using hosts<\/tt> parameter to hstore-prepare<\/tt>. You can also use hstore-jar<\/tt> to update an existing catalog with the new cluster layout:<\/p>\n

\r\nant hstore-prepare<\/tt> -Dproject=$BENCHMARK -Dhosts=\/path\/to\/cluster.txt\r\n<\/pre>\n

Instead of using a file, the cluster configuration can be passed as a semi-colon delimited list using the hosts<\/tt> parameter. It is important that you wrap the value portion of the parameter in quotation marks to ensure proper escaping:<\/p>\n

\r\nant hstore-jar<\/tt> -Dproject=$BENCHMARK \\\r\n    -Dhosts=\"host0.cs.brown.edu:0:0-1;host1.cs.brown.edu:1:2,3,5;host1.cs.brown.edu:2:4,6-7\"\r\n<\/pre>\n

You can view the cluster configuration in the project jar using either the catalog viewer tool<\/a>, or the catalog-info<\/tt> task:<\/p>\n

ant catalog-info<\/tt> -Dproject=tpcc<\/pre>\n

Sample Output:<\/p>\n

\r\nCatalog File:    tpcc.jar\r\n# of Hosts:      2\r\n# of Sites:      3\r\n# of Partitions: 8\r\n----------------------------------------------------------------------\r\nCluster Information:\r\n\r\n[00] HOST host0.cs.brown.edu \u2503 [01] HOST host1.cs.brown.edu\r\n     \u2514 SITE H00: [0, 1]      \u2503      \u251c SITE H01: [2, 3, 5]  \r\n                             \u2503      \u2514 SITE H02: [4, 6, 7]<\/pre>\n

\u00ab<\/B> Site Parameters<\/a><\/div>
Debugging<\/a> \u00bb<\/B><\/div>
<\/div><\/p>\n","protected":false},"excerpt":{"rendered":"

The H-Store cluster configuration file defines what nodes will be used in a benchmark run for the database. H-Store assumes that each of these nodes has passwordless SSH logins enabled. Note that the cluster configuration file is different from where the benchmark clients will run. By default, hstore-prepare creates a catalog with a cluster of […]<\/p>\n","protected":false},"author":2,"featured_media":0,"parent":624,"menu_order":0,"comment_status":"closed","ping_status":"open","template":"","meta":[],"_links":{"self":[{"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/pages\/678"}],"collection":[{"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/comments?post=678"}],"version-history":[{"count":14,"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/pages\/678\/revisions"}],"predecessor-version":[{"id":1507,"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/pages\/678\/revisions\/1507"}],"up":[{"embeddable":true,"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/pages\/624"}],"wp:attachment":[{"href":"https:\/\/hstore.cs.brown.edu\/wp-json\/wp\/v2\/media?parent=678"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}