Skip to content

Commit

Permalink
updated docs
Browse files Browse the repository at this point in the history
  • Loading branch information
absolutelightning committed Dec 1, 2023
1 parent 61e4ead commit 4d22740
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
2 changes: 2 additions & 0 deletions website/content/commands/troubleshoot/index.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ Subcommands:
proxy Troubleshoots service mesh issues from the current Envoy instance
upstreams Gets upstream Envoy identifiers and IPs configured for the proxy
ports Helps troubleshoot TCP ports by printing if they are open or closed.
```

For more information, examples, and usage about a subcommand, click on the name
of the subcommand in the sidebar or one of the links below:

- [proxy](/consul/commands/troubleshoot/proxy)
- [upstreams](/consul/commands/troubleshoot/upstreams)
- [ports](/consul/commands/troubleshoot/ports)
44 changes: 44 additions & 0 deletions website/content/commands/troubleshoot/ports.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
---
layout: commands
page_title: 'Commands: Troubleshoot Ports'
description: >-
The `consul troubleshoot ports` Helps troubleshoot TCP ports by printing if they are open or closed.
---

# Consul Troubleshoot Upstreams

Command: `consul troubleshoot ports`

The `troubleshoot ports` Helps troubleshoot TCP ports by printing if they are open or closed.

## Usage

Usage: `consul troubleshoot ports [options]`

#### Command Options

- `-host=<value>` - Host name to troubleshoot TCP ports for. Host can also be set by environment variable `CONSUL_HTTP_ADDR`
- `-ports=<value>` - Custom ports to troubleshoot (comma-seperated).

## Examples

Checks for TCP connectivity of default ports of consul in case -ports is not passed as arguments.
Default ports are listed [here](/consul/docs/install/ports)

```shell-session
$ export CONSUL_HTTP_ADDR=localhost
$ consul troubleshoot ports
TCP: Port 8501 on localhost is open.
TCP: Port 8502 on localhost is open.
TCP: Port 8503 on localhost is open.
TCP: Port 8302 on localhost is open.
TCP: Port 8300 on localhost is open.
TCP: Port 8600 on localhost is open.
TCP: Port 8301 on localhost is open.
TCP: Port 8500 on localhost is open.
```

```shell-session
$ consul troubleshoot ports -host hashicorp.com -ports 80
TCP: Port 80 on hashicorp.com is open.
```

0 comments on commit 4d22740

Please sign in to comment.