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

Enable Node Map doc #2775

Merged
merged 2 commits into from
Mar 29, 2018
Merged

Enable Node Map doc #2775

merged 2 commits into from
Mar 29, 2018

Conversation

Amruta-Ranade
Copy link
Contributor

@Amruta-Ranade Amruta-Ranade commented Mar 24, 2018

As discussed, breaking up the Node Map doc PR:
Phase 1: Added content for enabling the Node Map.

@vilterp @couchand You have reviewed the content before, but I have reworked it based on Thursday's meeting. You might want to take a look at the revised content.

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Contributor

@jseldess jseldess left a comment

Choose a reason for hiding this comment

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

@Amruta-Ranade, I haven't had the chance to review the whole page yet, but I have some preliminary comments for you.

### Step 5. View the Node Map

[Navigate to the **Overview page**](admin-ui-overview.html) to view the **Node Map**.
Copy link
Contributor

Choose a reason for hiding this comment

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

Since we use Navigate in the next step, let's use something else here, e.g,:

Open the Overview page...

<div id="toc"></div>

To enable the **Node Map**, you need to start the cluster with the correct `--locality` flags and assign the latitudes and longitudes for each locality.
Copy link
Contributor

Choose a reason for hiding this comment

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

This content, right below the TOC and without its own section heading, is very likely to get lost/skipped. I'd suggest revising the intro to the page to incorporate this content:

The **Node Map** visualizes the geographical configuration of a multi-regional cluster by plotting the node localities on a world map. The **Node Map** also provides real-time cluster metrics, with the ability to drill down to individual nodes to monitor and troubleshoot the cluster health and performance.

This page walks your through the process of setting up and enabling the **Node Map**.

{{site.data.alerts.callout_info}}The <b>Node Map</b> is an <a href="enterprise-licensing.html">enterprise-only</a> feature. However, you can <a href="https://www.cockroachlabs.com/pricing/request-a-license/">request a trial license</a>  to try it out. {{site.data.alerts.end}}

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Reworked it a bit (not sure if it's enough).

{{site.data.alerts.callout_info}}The <b>Node Map</b> won't be displayed until <i>all</i> nodes are started with the correct <code>--locality</code> flags and all localities are assigned the corresponding latitudes and longitudes. {{site.data.alerts.end}}

## Example
Copy link
Contributor

Choose a reason for hiding this comment

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

It feel strange to frame this whole procedure as an example. Let's remove this and mention the scenario before showing the cockroach start commands in the next step. That would mean making all of the steps h2 headings.

If not, [upgrade to CockroachDB v2.0](upgrade-cockroach-version.html).

### Step 2. Start (or Restart) the Nodes with the Correct `--locality` Flags
Copy link
Contributor

Choose a reason for hiding this comment

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

Based on our conversation, what are the recommendations we want to make about the locality level to set? That's not really indicated anywhere.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

We had decided to add it as a troubleshooting item. I have added the guidance to the troubleshooting section as per our conversation.

To get the latitudes and longitudes of common AWS/Azure/GC regions, see [Locations Coordinates for Reference](#location-coordinates-for-reference).

### Step 5. View the Node Map
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Node Map available by default not implemented. Need to specify they need to navigate to it after configuring.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

Copy link
Contributor

@couchand couchand left a comment

Choose a reason for hiding this comment

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

Looks good from my end (other than the shell code snippet type). Thanks!

~~~

If not, [upgrade to CockroachDB v2.0](upgrade-cockroach-version.html).
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe first have a sentence with something about what you're supposed to see?

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, let's put this as a second code block showing the response:

~~~
Build Tag:   {{page.release_info.version}}
Build Time:  {{page.release_info.build_time}}
Distribution: CCL
Platform:     darwin amd64
Go Version:   go1.8.3
C Compiler:   4.2.1 Compatible Clang 3.8.0 (tags/RELEASE_380/final)
Build SHA-1:  5b757262d33d814bda1deb2af20161a1f7749df3
Build Type:   release
~~~

Copy link
Contributor

Choose a reason for hiding this comment

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

Following that, I'd write out the sentence a bit more explicitly, e.g.:

If any node is running an earlier version, upgrade it to CockroachDB v2.0.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added and updated to match 2.0 release requirements (Go version, SHA)


{% include copy-clipboard.html %}
~~~ sql
Copy link
Contributor

Choose a reason for hiding this comment

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

this should be shell

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

~~~

Insert the latitudes and longitudes of each region into the `system.locations` table:
Copy link
Contributor

Choose a reason for hiding this comment

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

Just had a thought, maybe we should sprinkle the word "approximate" or something when we talk about lat/long, to emphasize that it doesn't need to be perfect?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

### Step 2. Start (or Restart) the Nodes with the Correct `--locality` Flags

If you have a cluster running without the `--locality` flags set, restart the nodes with the correct `--locality` flags(add link to rolling restart page once it's created).
Copy link
Contributor

Choose a reason for hiding this comment

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

Oh, just noting this TODO item...

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Punting to post-2.0

Copy link
Contributor

@jseldess jseldess left a comment

Choose a reason for hiding this comment

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

Looking good, @Amruta-Ranade. Just a handful more suggestions.

Also, you need to add (Enterprise) to the title and add this to the sidenav. I'd suggest adding it to the Deploy section for visibility, perhaps below Define Table Partition (Enterprise).

This page walks you through the process of setting up and enabling the **Node Map**.

{{site.data.alerts.callout_info}}The <b>Node Map</b> is an <a href="enterprise-licensing.html">enterprise-only</a> feature. However, you can <a href="https://www.cockroachlabs.com/pricing/request-a-license/">request a trial license</a> to enable the <b>Node Map</b>. {{site.data.alerts.end}}
Copy link
Contributor

Choose a reason for hiding this comment

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

I'd still prefer an slightly altered second sentence here:

However, you can request a trial license to try it out.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.


{% include copy-clipboard.html %}
~~~ sql
Copy link
Contributor

Choose a reason for hiding this comment

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

sql > shell

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

### Step 5. View the Node Map

[Open the **Overview page**](admin-ui-overview.html) and select **Node Map** from the **View** drop-down menu to view the **Node Map**.
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's remove to view the **Node Map**.

Also, admin-ui-overview.html doesn't seem like the right link. Where do you want to send people?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Fixed link.

### Step 6. Navigate the Node Map

Let's say you want to navigate to Node 2, which is in datacenter `us-east-1a` in the `us-east-1` region. To navigate to Node 2:
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove To navigate to Node 2: and end the first sentence with a colon.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

Let's say you want to navigate to Node 2, which is in datacenter `us-east-1a` in the `us-east-1` region. To navigate to Node 2:

1. Click on map component marked as **region=us-east-1** on the **Node Map**. The datacenter view is displayed.
Copy link
Contributor

Choose a reason for hiding this comment

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

on map component > on the map component

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

<div id="toc"></div>

## Setting Up and Enabling the Node Map
Copy link
Contributor

Choose a reason for hiding this comment

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

I think we can remove this entire section and just move the scenario details to step 2. That would let us promot all of the steps to h2s.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Not sure what you mean here. Let's discuss this in office tomorrow.

### Unable to Assign Latitude/Longitude Coordinates to Localities

You won't be able to assign latitude/longitude coordinates to localities is if the components of your localities have the same name. For example, consider the following partial configuration:
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove is in is if the components.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

The **Node Map** is displayed only for the locality levels that have latitude/longitude coordinates assigned to them:

- If you assign the latitude/longitude coordinates at the region level, the **Node Map** shows the regions on the world map. However, when you drill down to the datacenter and further to the individual nodes level, the world map disappears and the datacenters/nodes are be plotted in a circular layout.
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove level in individual nodes level.

Copy link
Contributor

Choose a reason for hiding this comment

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

Remove be in are be plotted.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.


- If you assign the latitude/longitude coordinates at the region level, the **Node Map** shows the regions on the world map. However, when you drill down to the datacenter and further to the individual nodes level, the world map disappears and the datacenters/nodes are be plotted in a circular layout.
- If you assign the latitude/longitude coordinates at the datacenter level, the **Node Map** shows the regions with single datacenters at the same location assigned to the datacenter, while regions with multiple datacenters are shown at the center of the datacenter coordinates in the region. When you drill down to the datacenter levels, the **Node Map** shows the datacenter at their assigned coordinates. Further drilling down to individual node levels shows the nodes in a circular layout.
Copy link
Contributor

Choose a reason for hiding this comment

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

center of the datacenter coordinates > average of the datacenter coordinates?

Copy link
Contributor

Choose a reason for hiding this comment

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

fwiw the precise term is "centroid"

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Centroid of datacenter coordinates? (Sounds weird, but technically accurate I guess)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@jseldess @couchand What do we want to use here? Centroid, center, average?

## Location Coordinates for Reference

| **Location** | **SQL Statement** |
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove the bolding. Not needed in a header row.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

Copy link
Contributor

@jseldess jseldess left a comment

Choose a reason for hiding this comment

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

LGTM, with some final requests.

~~~

If not, [upgrade to CockroachDB v2.0](upgrade-cockroach-version.html).
Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, let's put this as a second code block showing the response:

~~~
Build Tag:   {{page.release_info.version}}
Build Time:  {{page.release_info.build_time}}
Distribution: CCL
Platform:     darwin amd64
Go Version:   go1.8.3
C Compiler:   4.2.1 Compatible Clang 3.8.0 (tags/RELEASE_380/final)
Build SHA-1:  5b757262d33d814bda1deb2af20161a1f7749df3
Build Type:   release
~~~

~~~

If not, [upgrade to CockroachDB v2.0](upgrade-cockroach-version.html).
Copy link
Contributor

Choose a reason for hiding this comment

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

Following that, I'd write out the sentence a bit more explicitly, e.g.:

If any node is running an earlier version, upgrade it to CockroachDB v2.0.

To start a new cluster with the correct `--locality` flags:

In a new terminal, start Node 1:
Copy link
Contributor

Choose a reason for hiding this comment

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

Remove "In a new terminal" for each of the node commands. You'd be running these on separate machines.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.

<div id="toc"></div>

## Setting Up and Enabling the Node Map
Copy link
Contributor

Choose a reason for hiding this comment

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

On another look, I'm fine with leaving this as-is, but let's change the heading to Set Up and Enable the Node Map to match the form of Troubleshoot the Node Map.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done

@@ -1,7 +1,200 @@
---
title: Enable the Node Map
title: Enable the Node Map (Enterprise)
Copy link
Contributor

Choose a reason for hiding this comment

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

Just realized that we don't put (Enterprise) in the title for BACKUP/RESTORE. Let's also remove that from this page as well as the Table Partitioning page. However, please leave it in the sidenav and in the callouts.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed from this page. Made a note to remove from the partitioning doc.

### **Capacity Used** Value Displayed is More Than Configured Capacity

If you are running multiple nodes on a single machine (not recommended), the **Capacity Used** value may be incorrect. This is because when multiple nodes are running on a single machine, the machine's hard disk is treated as separate stores for each node, while in reality, only one hard disk is used for all nodes. The **Capacity Used** value is then displayed as the hard disk capacity used multiplied by the number of nodes on the machine.
Copy link
Contributor

Choose a reason for hiding this comment

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

Rich created an include with this message. Let's use it here: https://github.com/cockroachdb/docs/blob/master/_includes/available-capacity-metric.md

However, I'd like you to make a few minor changes to the include content to make it work in all contexts.

Instead of:

the Capacity Used metric in the Summary panel and the available capacity shown in the Capacity graph in the Admin UI are incorrect.

Please use:

capacity metrics in the Admin UI are incorrect.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done.


| Location | SQL Statement |
| ------ | ------ | ------ | ------ |
Copy link
Contributor

Choose a reason for hiding this comment

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

There are two extra columns here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Gah..fixed.

The **Node Map** visualizes the geographical configuration of a multi-regional cluster by plotting the node localities on a world map. The **Node Map** also provides real-time cluster metrics, with the ability to drill down to individual nodes to monitor and troubleshoot the cluster health and performance.
Copy link
Contributor

Choose a reason for hiding this comment

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

Add the "new in v2.0" callout to the beginning of this paragraph. Please do that same on the Table Partitioning page.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Added to this doc. Made note to add it to the partitioning PR.

@jseldess jseldess changed the title [WIP] Enable Node Map doc Enable Node Map doc Mar 29, 2018
@jseldess
Copy link
Contributor

After your final edits, it'd be great if you could squash all of your commits down into one. It should be as easy as:

  1. Make sure your master is up-to-date.
  2. git rebase -i master
  3. Press i.
  4. For all commits but the first, change pick to f.
  5. Press esc then shift + : then wq! then enter.

We can do this together tomorrow, if you prefer.

@Amruta-Ranade Amruta-Ranade merged commit 53eadd7 into master Mar 29, 2018
@Amruta-Ranade Amruta-Ranade deleted the enable_node_map branch March 29, 2018 16:45
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.

4 participants