Teku

Installing and configuring the Teku Beacon Node.

Teku

Teku is a full Ethereum consensus client designed and built to meet institutional needs and security requirements. Developed by ConsenSys, it is written in Java and maintains Apache 2.0 licensing.


🛡️ Role: Teku is widely used by staking-as-a-service providers due to its robust support for external key managers (like Web3Signer) and its stability in enterprise environments.


1. Install Dependencies (Java)

Like Besu, Teku requires a Java Runtime Environment (JRE). We recommend Java 21 LTS for optimal performance.

# Update repositories
sudo apt update

# Install OpenJDK 21
sudo apt install -y openjdk-21-jre-headless

# Verify Java installation
java -version

2. Download & Install

We will download the latest binary release from the official ConsenSys repository.

A. Create the Application Directory

B. Set Permissions

Ensure the ethereum user owns the directory.


3. Configure Systemd Service

We will configure Teku to run as a background service.

Checkpoint Sync: Teku supports two checkpoint sync methods: --checkpoint-sync-url and --initial-state. We use --checkpoint-sync-url below, which downloads a recent finalized state from a trusted endpoint to sync in minutes. Note: You cannot use both flags simultaneously — pick one.

Create the service file:

Paste the following configuration:

🔍 Flag Explanation:

  • --ee-endpoint: The URL of your local Geth/Nethermind Engine API.

  • --checkpoint-sync-url: Downloads the latest finalized checkpoint state for fast syncing. (Replaces the older --initial-state approach used in previous guides.)

  • --rest-api-enabled: Enables the API (Required if you want to check status or connect a Validator Client later).


4. Start the Service

Reload the systemd daemon and start the beacon node.


5. Verify Status

Check the logs to ensure Teku is initializing correctly.

Expected Output:

  • Eth1 Connection: Switching to the follower execution engine (This is normal at startup, it means it found Geth/Nethermind).

  • Sync: Syncing to checkpoint followed by Remote checkpoint loaded.

  • Head Update: You should start seeing logs like Slot Event or Head updated as it follows the chain.

Last updated