This guide describes how to configure and use the email notification feature in EthStorage's mining process. This feature is useful for storage providers or es-node operators who want to receive timely notifications about proof submissions and their results.
If enabled, storage providers will receive email notifications for the following mining events:
When the es-node is started and each of the local data shards is ready to mine. Note that on first startup, the node's local storage must synchronize via P2P to catch up with the network.
When a storage proof is generated and submitted to the smart contract as a mining transaction.
SMTP Service Preparation
You must have access to a working SMTP service to use the email notification feature.
If you do not already have an SMTP account, you need to apply for one yourself. Below are two common options:
You can use your Gmail account as an SMTP sender.
SMTP Host: smtp.gmail.com
SMTP Host: in-v3.mailjet.com
For other providers, refer to their documentation for SMTP host, port, and credential setup.
Email Configuration
You can configure email notifications via CLI flags or environment variables. The most common way is to pass parameters to your node startup scripts where storage mining is enabled (e.g., run.sh or run-l2.sh):
Then execute the script with the SMTP password, miner address, and private key as environment variables:
Quick Test for Your Email Configuration
You can run the es-node email command with your email configuration to quickly verify your email settings, as shown in the following example:
You will receive an email like the following if everything is correct:
Parameter Reference
CLI Flag
Environment Variable Name
Description
ES_NODE_MINER_EMAIL_ENABLED
Enable email notification for miner (default: false)
SMTP password or API secret
SMTP server host (default: smtp.gmail.com)
SMTP server port (default: 587)
Recipient(s), repeated flags supported
Notes:
Keep your SMTP credentials secure.
It is recommended to use the environment variable (ES_NODE_EMAIL_PASSWORD) for the password.
If your password contains spaces, enclose it in double quotes.
To specify multiple recipients, separate addresses with commas for the value of --email.to.
To disable email notifications, either remove the flag --miner.email-enabled, or set --miner.email-enabled=false.
The --email.from value must be a valid email address (no display name or angle brackets).
Example Email Contents
Start Mining Notification
Subject: EthStorage Mining Task Started: Shard 1
A new mining task has been initiated for shard 1 on the es-node at 10.20.30.40.
Miner: 0xabc123... Threads per shard: 12 Minimum profit: 0
Sent at: Fri, 18 Jul 2025 11:14:25 +0800
Transaction Confirmed and Success
Proof Dropped Due to Low Profit
Transaction Submission Failed
Transaction Submitted but Hash is Empty
Transaction Confirmed but Failed
Transaction Confirmation Timeout
Transaction Receipt Not Found