|
| 1 | +# Quick Start |
| 2 | + |
| 3 | +The easiest way to start with Parca is to obtain the pre-built statically-linked binary or the container. |
| 4 | +You can download the latest release of the binary from the Parca GitHub release pages ([Server](https://github.com/parca-dev/parca/releases) and [Agent](https://github.com/parca-dev/parca-agent/releases)). |
| 5 | +Alternatively, you can use the Parca container image from [the GitHub Container Registry](https://github.com/orgs/parca-dev/packages). |
| 6 | + |
| 7 | +Once you have the binary or the container, you can start profiling your applications with Parca. |
| 8 | + |
| 9 | +:::info Please select your environment and use the following commands to quickly get started |
| 10 | +::: |
| 11 | + |
| 12 | +import Tabs from "@theme/Tabs"; |
| 13 | +import TabItem from "@theme/TabItem"; |
| 14 | +import WithVersions from '@site/src/components/WithVersions'; |
| 15 | +import CodeBlock from '@theme/CodeBlock'; |
| 16 | + |
| 17 | + |
| 18 | +<Tabs groupId="environment" queryString> |
| 19 | +<TabItem value="binary" label="Binary" default> |
| 20 | + |
| 21 | +**Server** |
| 22 | + |
| 23 | +1. Download the binary specific to your OS and architecture |
| 24 | +<WithVersions language="bash"> |
| 25 | + { versions => |
| 26 | + <CodeBlock className="language-bash"> |
| 27 | + curl -sL https://github.com/parca-dev/parca/releases/download/{versions.server}/parca_{versions.server.substring(1)}_`uname -s`_`uname -m`.tar.gz | tar xvfz - |
| 28 | + </CodeBlock> |
| 29 | + } |
| 30 | +</WithVersions> |
| 31 | + |
| 32 | +2. Run Parca and access the Web UI on port 7070 |
| 33 | + ```bash |
| 34 | + # Get basic configuration |
| 35 | + curl -sL https://raw.githubusercontent.com/parca-dev/parca/main/parca.yaml > parca.yaml |
| 36 | + # Run Parca and access the Web UI on port 7070 |
| 37 | + ./parca --config=parca.yaml |
| 38 | + ``` |
| 39 | + |
| 40 | +**Agent** |
| 41 | + |
| 42 | +1. Download the binary specific to your architecture (only works on Linux) |
| 43 | +<WithVersions language="bash"> |
| 44 | + { versions => |
| 45 | + <CodeBlock className="language-bash"> |
| 46 | + curl -sL https://github.com/parca-dev/parca-agent/releases/download/{versions.agent}/parca-agent_{versions.agent.substring(1)}_`uname -s`_`uname -m`.tar.gz | tar xvfz - |
| 47 | + </CodeBlock> |
| 48 | + } |
| 49 | +</WithVersions> |
| 50 | + |
| 51 | +2. Run Parca Agent and access the Web UI on port 7071 (assumes Parca is running on localhost:7070) |
| 52 | + ```bash |
| 53 | + ./parca-agent --node=test --remote-store-address=localhost:7070 --remote-store-insecure |
| 54 | + ``` |
| 55 | + |
| 56 | +<br /> |
| 57 | + |
| 58 | +:::danger [Parca from Binary - Tutorial 5min ⏱️](/docs/binary) |
| 59 | +::: |
| 60 | +</TabItem> |
| 61 | +<TabItem value="container" label="Container"> |
| 62 | + |
| 63 | +**Server** |
| 64 | + |
| 65 | +Run Parca and access the Web UI on port 7070 |
| 66 | +<WithVersions language="bash"> |
| 67 | + { versions => |
| 68 | + <CodeBlock className="language-bash"> |
| 69 | + docker run --rm -it ghcr.io/parca-dev/parca:{versions.server} /parca |
| 70 | + </CodeBlock> |
| 71 | + } |
| 72 | +</WithVersions> |
| 73 | + |
| 74 | +**Agent** |
| 75 | + |
| 76 | +Run Parca Agent (requires privileged more) and access the Web UI on port 7071 (assumes Parca is running on localhost:7070) |
| 77 | +<WithVersions language="bash"> |
| 78 | + { versions => |
| 79 | + <CodeBlock className="language-bash"> |
| 80 | + docker run --rm -it --privileged ghcr.io/parca-dev/parca-agent:{versions.agent} /bin/parca-agent --node=docker-test |
| 81 | + </CodeBlock> |
| 82 | + } |
| 83 | +</WithVersions> |
| 84 | + |
| 85 | +<br /> |
| 86 | + |
| 87 | +:::danger [Parca from Binary - Tutorial 5min ⏱️](/docs/binary) |
| 88 | +::: |
| 89 | + |
| 90 | +</TabItem> |
| 91 | +<TabItem value="kubernetes" label="Kubernetes"> |
| 92 | + |
| 93 | +:::tip |
| 94 | + |
| 95 | +To quickly try out the Parca and Parca Agent with Kubernetes, you create a [minikube](https://minikube.sigs.k8s.io/docs/) cluster with an actual virtual machine, e.g. Virtualbox: |
| 96 | + |
| 97 | +```shell |
| 98 | +minikube start --driver=virtualbox |
| 99 | +``` |
| 100 | +::: |
| 101 | + |
| 102 | +1. Create the namespace (not strictly necessary but prevents a race with the next commands) |
| 103 | + ``` |
| 104 | + kubectl create namespace parca |
| 105 | + ``` |
| 106 | + |
| 107 | +**Server** |
| 108 | + |
| 109 | +2. Use to deploy Parca Server (API and UI) |
| 110 | +<WithVersions language="bash"> |
| 111 | + { versions => |
| 112 | + <CodeBlock className="language-bash"> |
| 113 | + kubectl apply -f https://github.com/parca-dev/parca/releases/download/{versions.server}/kubernetes-manifest.yaml |
| 114 | + </CodeBlock> |
| 115 | + } |
| 116 | +</WithVersions> |
| 117 | + |
| 118 | +**Agent** |
| 119 | + |
| 120 | +3. Use to deploy Parca Agent for all nodes |
| 121 | +<WithVersions language="bash"> |
| 122 | + { versions => |
| 123 | + <CodeBlock className="language-bash"> |
| 124 | + kubectl apply -f https://github.com/parca-dev/parca-agent/releases/download/{versions.agent}/kubernetes-manifest.yaml |
| 125 | + </CodeBlock> |
| 126 | + } |
| 127 | +</WithVersions> |
| 128 | +<br /> |
| 129 | + |
| 130 | +:::danger [Parca in Kubernetes - Tutorial 5min ⏱️](/docs/kubernetes) |
| 131 | +::: |
| 132 | +</TabItem> |
| 133 | +</Tabs> |
0 commit comments