guides:farming:upgradedb
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
guides:farming:upgradedb [2022/05/17 09:57] – created vleesbanaan | guides:farming:upgradedb [2022/06/21 08:09] (current) – vleesbanaan | ||
---|---|---|---|
Line 1: | Line 1: | ||
===== How to Upgrade the Chia db ===== | ===== How to Upgrade the Chia db ===== | ||
+ | |||
+ | Upgrading the Chia db from v1 to v2 CAN be a very simple process. | ||
+ | However, the reason you are reading this guide is most probably because you want to learn how to upgrade AFTER your drive is full and you don't want to sync from scratch. | ||
+ | |||
+ | We will go through three different ways: | ||
+ | - Upgrading the easy way | ||
+ | - Download v2 from a trusted source and replace v1 | ||
+ | - Using an external SSD | ||
+ | - Using the SpaceFarmer Community Node | ||
+ | |||
+ | |||
+ | ==== 1. Updating the easy way ==== | ||
+ | |||
+ | * in CLI change directory to chia '' | ||
+ | * run '' | ||
+ | * Update your config.yaml under the '' | ||
+ | |||
+ | |||
+ | There are two prerequisites for upgrading the Chia db the easy way. | ||
+ | * enough space on the target directory | ||
+ | * enough space on your temporary directory (often overlooked) | ||
+ | |||
+ | For further reference, see https:// | ||
+ | |||
+ | ==== 2. Download and replace ==== | ||
+ | The advantage of this method is that it is easy and has minimal downtime. The trick is to download the db right after the snapshot, so your node needs to do minimal syncing to catch up with the latest blockheight. The downside is that you need to trust the source from which you download the snapshot. | ||
+ | |||
+ | - Stop all chia processes | ||
+ | - go to '' | ||
+ | - download the v2 db from a source you trust and place it in the folder. Spacefarmers offers a daily snapshot [[guides/ | ||
+ | - in your your config.yaml, | ||
+ | |||
+ | ==== 3. Using an external SSD ==== | ||
+ | |||
+ | * stop all chia processes '' | ||
+ | * [[guides/ | ||
+ | * Make sure your TMP folder has enough space available (size of v1+v2). If not, see the fix under "Error when TMP folder full". | ||
+ | * in CLI change directory to chia '' | ||
+ | * '' | ||
+ | * in your your config.yaml, | ||
+ | * when done, '' | ||
+ | |||
+ | === 3.1 Error when TMP folder full === | ||
+ | The method above doesn' | ||
+ | |||
+ | You will attempt to do so, you get a pop-up with the following window somewhere in the process: | ||
+ | < | ||
+ | Windows was unable to save all the data for the file \chiaDB\blockchain_v2_mainnet.sqlite: | ||
+ | This error may be caused if the device has been removed or the media is write-protected.</ | ||
+ | |||
+ | And in the CLI you will find the following: | ||
+ | < | ||
+ | The target v2 database is left in place (possibily in an incomplete state) D: | ||
+ | |||
+ | If your failure was caused by a full disk, ensure the volumes of your temporary- and target directory have sufficient free space. | ||
+ | Your temporary directory may be '' | ||
+ | you can specify the " | ||
+ | |||
+ | The work-around for this is to change your temporary folder to the new SSD (temporarily), | ||
+ | |||
+ | * Go to Settings and search: edit environmental variables for your account | ||
+ | * Edit the TMP field and change from '' | ||
+ | * In case you already used '' | ||
+ | * '' | ||
+ | |||
+ | after you are done, don't forget to set back your temporary folder back to your original folder! | ||
+ | |||
+ | ==== 4. SpaceFarmer Community Node ==== | ||
+ | It is also possible to farm without running a full node locally. Using the hooks that already exist in Chia 1.3+, we created the [[poolinfo/ |
guides/farming/upgradedb.txt · Last modified: 2022/06/21 08:09 by vleesbanaan