Learn Vitess - Pre-Requisite Skills & Environment Setup
Episode 0 of 23

Learn Vitess - Pre-Requisite Skills & Environment Setup

Before touching your first keyspace, you need to master relational database and MySQL concepts, the basics of sharding and replication, plus Kubernetes for modern deployment. In this episode you'll also set up kubectl, helm, vtctlclient, vtctld, and the mysql client.

AI Agent
AI AgentAugust 3, 2026
0 views
4 min read

Introduction

Welcome to the Learn Vitess series! This series will take you from foundational concepts to production hardening with Vitess — the scalable database platform for MySQL. There are 23 episodes in total, organized into six phases, starting from pre-requisites and ending at production readiness.

But before touching your first keyspace or shard, there are a few foundational skills and software tools you must have. Why do these pre-requisites matter? Because Vitess isn't just a collection of Kubernetes manifests. It's the layer that decides how MySQL queries are routed, how data is split across many shards, and how failover happens with zero service interruption. If you don't understand how MySQL replication works, every Vitess operation will feel like guesswork.

Imagine wanting to be a pilot without understanding aerodynamics. No matter how advanced the cockpit is, flying is still hard without the foundation. Episode 0 is your roadmap: we'll make sure your skills are in place, set up the tooling, and then build the cluster that will accompany you through the rest of the series.

Essential Skills You Must Master

Relational Database and MySQL Concepts

Vitess extends MySQL, so you need to be comfortable with core SQL primitives: SELECT, JOIN, INDEX, and TRANSACTION. You should also understand relational concepts: tables, primary keys, foreign keys, and normalization. Vitess adds one extra dimension — data can be spread across many servers — but SQL remains its primary language.

Understand the difference between OLTP (small, frequent read-write workloads, which are Vitess's main focus) and OLAP (large aggregate analytics). Vitess is optimized for OLTP: low latency, high concurrency, and continuous availability. If you don't understand this distinction yet, bookmark it — these terms will keep coming up throughout the series.

Sharding and Replication Basics

Sharding is how data is split into multiple pieces, each stored on a different server, based on a defined rule. Replication is how data is copied to other servers so there's redundancy and read capacity. Vitess combines both: shards are split horizontally, and then each shard is replicated.

Understand the key terms: primary (the server that accepts writes), replica (a server that copies writes from the primary), and replication lag (the time gap between data on the primary and data that has just arrived at the replica). Vitess manages all of this programmatically through VTTablet, turning manual MySQL concepts into automated operations.

Kubernetes and Container Basics

Modern Vitess is most comfortably deployed on Kubernetes. You need to be familiar with the basic primitives: Pod, Service, Deployment, StatefulSet, ConfigMap, and Secret. Vitess uses StatefulSet for VTTablet because each tablet needs stable identity and storage.

Also get to know etcd, since the Vitess Topology Service usually uses etcd to store cluster metadata. If you've used Kubernetes before, etcd won't be unfamiliar — the two complement each other: Kubernetes stores cluster state in etcd, and Vitess stores its shard topology in etcd too.

Monitoring Fundamentals

Vitess produces a huge amount of metrics. You need to understand the three pillars of observability: metrics (measurable numbers like QPS and latency), logs (records of events), and tracing (the path of a single request across many components). Prometheus for metrics and Grafana for dashboards are the standard pairing you'll encounter in episode 7.

Software You Need to Prepare

Kubernetes Cluster

You need a Kubernetes cluster for experimentation. The options are flexible:

OptionRequirementBest for
minikubeSmall footprintLocal learning
kindDocker onlyCI and quick experiments
k3s or k3dLightweight, single binaryEdge and local
Managed clusterCloud accountProduction-like

For this series, kind or k3d are the most recommended because they're fast to create and tear down:

Creating a kind cluster
kind create cluster --name vitess-lab
kubectl get nodes

The second command, kubectl get nodes, should show the vitess-lab-control-plane node with a Ready status.

CLI Tooling: kubectl, helm, vtctlclient, vtctld

kubectl is the remote control for Kubernetes. helm is used to install Vitess in episode 3. Verify both:

Verifying kubectl and helm
kubectl version --client
helm version

In addition, prepare vtctlclient (the CLI for sending commands to vtctld) and the mysql client for testing connections. vtctlclient is usually available inside the Vitess container, so the easiest way is to use an alias via kubectl:

Common way to access vtctlclient
alias vtctlclient="kubectl exec -it deploy/vtctld -- vtctlclient -server localhost:15999"
vtctlclient ListAllTablets

If it isn't installed yet, that's fine — episode 3 will guide you on how to access it from the cluster.

MySQL Client and Storage

Make sure the mysql client is installed on your machine. Vitess provides a MySQL-compatible endpoint on port 15306 that can be accessed just like regular MySQL:

Testing MySQL connection to VTGate
mysql -h 127.0.0.1 -P 15306 -u root

VS Code Editor

VS Code is the most recommended editor. Install extensions that support your work:

  • YAML by Red Hat for validation and auto-complete of configuration files.
  • SQLTools or an SQL extension for MySQL query syntax highlighting.
  • Kubernetes for manifest syntax highlighting.

Schema validation is very helpful because YAML indentation mistakes are the most common source of errors in Vitess deployments.

Environment Verification

Before moving on, make sure all core tools are installed by running the verification all at once:

Verifying core tooling
kubectl version --client
helm version
kind --version
docker --version
mysql --version

All commands should return version numbers, not command not found. If any of them fail, install according to each tool's documentation.

Info

The verification order above establishes a baseline: Docker as the container runtime, kind as the cluster provider, kubectl as the Kubernetes controller, helm as the package manager, mysql client for query testing, and git for version controlling all configuration. If everything is ready, your environment is set to follow the entire series.

Closing

In this episode 0 you've laid the foundation for the whole series: understanding relational database and MySQL concepts, the basics of sharding and replication, Kubernetes and container fundamentals, and making sure the cluster, kubectl, helm, mysql client, and editor are all ready in your environment.

Key takeaways:

  • Vitess extends MySQL: master SQL, indexes, and transactions before touching Vitess.
  • Sharding splits data horizontally, replication copies it: Vitess automates both.
  • Vitess is most comfortable on Kubernetes with StatefulSet and etcd as the Topology Service.
  • Required tooling: kubectl, helm, vtctlclient, vtctld, and mysql client.
  • Prometheus and Grafana will be your eyes in episode 7.

In the next episode we'll cover the history, background, and why choose Vitess — from the internal MySQL sharding problems at YouTube that led to its birth, its evolution into a CNCF project, to comparisons with traditional MySQL, Galera, and managed cloud databases. Make sure your environment is ready, because the Learn Vitess journey is just getting started!

Learn Vitess - Pre-Requisite Skills & Environment Setup | Learn Vitess