- install guide
Update system packages
After connecting to the server, you want to ensure that the system is up-to-date and secure. Run the following commands to update the system packages upgrade any existing packages, and remove those that are no longer needed:
Configure the firewall
To ensure your Ethereum node can communicate with the network while staying secure, you need to configure the firewall to allow specific ports. In this step, you'll open the ports needed by Geth and Prysm, and enable the firewall on your server:
Generate authentication secret
For Geth (the execution client) and Prysm (the consensus client) to communicate securely, they need a shared secret, known as a JSON Web Token (JWT). This token ensures that only authorized clients can interact with each other.
Before generating the secret, it's a good practice to create dedicated users for each client. This minimizes the risk of one client affecting the other and isolates their files and processes.
Start by creating the users and assigning them to a common group:
Next, create a directory to store the JWT secret, set the necessary permissions, and generate the secret:
Then set permissions on the secret file so that only the root user and the clients' users have access to it:
Create data directories
Install and configure execution client (Geth)
Create a Systemd Service for Geth:
Add the following configuration to the file:
Start and Enable the Geth Service:
After saving the service file, reload the systemd daemon to apply the changes, start the Geth service, and enable it to start on boot:
Check the Status of the Geth Service:
Verify that Geth is active running correctly by checking its status:
To view the logs, run the command:
Configure consensus client (Prysm)
Now that Geth is up and running, the next step is to set up the Prysm Beacon Chain client, which acts as the consensus client.
Download and Prepare the Prysm Script:
First, create a directory for the Prysm script, download it and make it executable:
Create a Systemd Service for Prysm:
Similar to how you configured Geth, you'll create a systemd service file for Prysm beacon client.
Open the service file in a text editor:
Add the following configuration to the file:
The --execution-endpoint=http://127.0.0.1:8551 flag points Prysm to the local Geth client.
The --jwt-secret=/var/lib/secrets/jwt.hex flag allows Prysm to authenticate its communication with Geth using the shared JWT secret.
The --suggested-fee-recipient=YourWalletAddress flag should be replaced with your Ethereum wallet address to receive potential rewards.
Start and Enable the Prysm Service:
After saving the service file, reload the systemd daemon to apply the changes, start the Prysm service, and enable it to start on boot:
Check the Status of the Prysm Service:
Verify that Prysm is running correctly by checking its status:
You can check the logs using: