[Tutorial] How to migrate miner nodes #6988
Locked
de-authority
started this conversation in
Tutorials
Replies: 1 comment 1 reply
-
you are not talking about the node but the miner here |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
1: Preparation
If there are fewer sectors, it is recommended to choose a deadline without window post for miner migration, specifically view command as follows
lotus-miner proving deadlines
stop all sealing jobs
Set environment variables
export LOTUS_BACKUP_BASE_PATH=</lotus/backup/basepath>
This item must be set, if not, the error message will be: ERROR: LOTUS_BACKUP_BASE_PATH env var not set
After setting, you need to restart the lotus-miner process to export the backups, and the folder where the backup files are located must be the one pointed to by this variable. Assume that BACKUP_BASE_PATH is set to ~/.lotusminer/backup/
2: Backup miner data and configuration files
lotus-miner backup ~/.lotusminer/backup/backup.cbor
If the Miner program has been stopped, execute.
lotus-miner backup --offline ~/.lotusminer/backup/backup.cbor
cp ~/.lotusminer/config.toml ~/.lotusminer/storage.json ~/.lotusminer/sectorstore.json ~/.lotusminer/backup/
3: Import miner data
Copy the backup folder to the new miner node
lotus-miner init restore backup/backup.cbor
cp backup/config.toml backup/storage.json backup/sectorstore.json ~/.lotusminer
4: Migrate files (If the miner node stores sector files locally)
5: Modify the configuration
If the local ip address changes.
Change <local_ip_address> to the new miner node intranet address
If the public ip address changes.
Modify <remote_ip_address> to be the new miner node public ip address
If the running user is changed,
Modify to be the name of the new user
6: Start the miner
lotus-miner run
7: Check the sector status
lotus-miner proving check [command options] <deadlineIdx>
Check the status of sectors one by one, make sure that all sectors are recognized by miner and the corresponding files can be found.
8: Re-export the api
lotus-miner auth api-info --perm admin
After the migration, the corresponding authorization information will be updated and LotusWorkers will need this token to connect to LotusMiner.
After all workers have been updated, execute
lotus-miner sealing workers
If there are no problems, the migration is complete
Caution.
This tutorial is tested based on the nerpa network. Since we operate in a variety of environments, the tutorial cannot cover all scenarios and the storage provider should adapt the operation to the specific situation
Beta Was this translation helpful? Give feedback.
All reactions