<commit_before>---
title: Segregated Witness Upgrade Guide
name: segwit-upgrade-guide
id: en-segwit-upgrade-guide
type: posts
layout: post
lang: en
permalink: /en/2016/10/27/segwit-upgrade-guide/
version: 1
excerpt: Almost two years of iterative design, development, and testing has gone into the version of segwit being released in Bitcoin Core 0.13.1, with much of the effort over the last year focused on making it as easy as possible for existing Bitcoin users, businesses, developers, and miners to upgrade to segwit.
---
{% include _toc.html %}
{% include _references.md %}

Almost two years of iterative design, development, and testing has gone into the version of segwit being released in Bitcoin Core 0.13.1, with much of the effort over the last year focused on making it as easy as possible for existing Bitcoin users, businesses, developers, and miners to upgrade to segwit.

Initial segwit adoption requires the participation of two groups:

- **[Miners][miners guide]** representing 95% or more of the total Bitcoin network hash rate must signal support for segwit in order to  lock-in segwit’s activation.

- **[Full nodes][node guide]** run by a reasonable number of users and business to validate the payments they receive need to be upgraded to Bitcoin Core 0.13.1 or another segwit-compatible implementation in order to incentivize miners to follow segwit’s rules after segwit activates.  (This is Bitcoin’s normal incentivization mechanism where miners only receive income for generating a block if they follow all of the consensus rules, which will include the new segwit consensus rules once segwit activates.)

The segwit soft fork has been designed to allow individuals in both groups to voluntarily decide whether or not they want to adopt segwit, and guides are provided below for both those who want to adopt segwit and those who don’t.

If enough miners do decide to adopt segwit, it will eventually activate and wallet users will be able to begin creating transactions with segregated witnesses.  The segwit soft fork has also been designed to be both backwards and forwards compatible with all commonly-used wallets, so wallet developers and users can also independently decide whether they want to adopt segwit or continue making transactions without segregated witnesses.  Guides are provided below for both adopting and non-adopting [developers][dev guide] and [users][user guide].

In addition to instructions, the end of each guide section below also provides a short list of recommended places to ask any segwit-related questions you may have.

## Miners

*This section is written for solo miners and mining pool operators.  Pool miners should contact their pool operators for information about what they need to do (if anything) to upgrade or not upgrade to segwit.* 

The BIP9 soft fork deployment mechanism is being used for segwit---the same mechanism used for the BIP 68/112/113 soft fork that activated on 4 July 2016.  Whether you wish to upgrade or not, you should understand the important stages of the upgrade process:

- **Started:** Segwit will be in the *started* stage from the beginning of the first retarget period on or after 15 November 2016 until it either activates or is considered failed (under BIP9’s policy) after one year of not reaching locked-in.  During this time, miners who are willing and able to enforce segwit’s new consensus rules will be signaling their intent to do so by placing bit 1 in the block header versionbits field.

- **Locked-in:** if 95% of blocks during a 2,016-block retarget period signal support for segwit, the segwit soft-fork will be *locked-in* with *activation* scheduled for 2,016 blocks later (about two weeks).

- **Activated:** after the completion of the *locked-in* period, the miners who signaled readiness to enforce segwit will begin producing segwit-style blocks that contain transactions with segregated witnesses.


### Not upgrading

This section describes what you can do as a miner if you don’t want to enforce segwit.

During the *started* phase, if you don’t want to adopt segwit, you may simply refuse to upgrade to a segwit-compatible full node such as Bitcoin Core 0.13.1, as well as avoiding any mining software that assumes you want to set segwit’s versionbit of bit 1.

If segwit reaches *locked-in*, you still don’t need to upgrade, but upgrading is strongly recommended.  The segwit soft fork does not require you to produce segwit-style blocks, so you may continue producing non-segwit blocks indefinitely.  However, once segwit activates, it will be possible for other miners to produce blocks that you consider to be valid but which every segwit-enforcing node rejects; if you build any of your blocks upon those invalid blocks, your blocks will be considered invalid too.

For this reason, after segwit reaches *locked-in*, it is recommended that you either upgrade your full node to Bitcoin Core 0.13.1 or later (or a compatible full node), or that you follow the “not upgrading” instructions in the Full Node section below to use Bitcoin Core 0.13.1 or later as a filter for your pre-segwit software.

### Upgrading

The BIP9 parameters for the segwit soft fork allow miners to begin signaling their support for it at the beginning of the first retarget period on or after 15 November 2016.  To signal support, you will need to
do the following: 

- Upgrade the full node you use for transaction selection and block construction to Bitcoin Core 0.13.1 or another segwit-compatible full node.

- Upgrade your mining software, mining pool software, or both to a segwit-compatible version.

- Begin producing blocks containing segwit’s BIP9 versionbit, which is bit 1.

When segwit is activated, you will want to be able to mine and relay segwit-style blocks.  The following mining software has been upgraded to support segwit.

- Full nodes 
    - [Bitcoin Core](https://bitcoin.org/en/download) 0.13.1
    - [Bitcoin Knots](http://bitcoinknots.org/) 0.13.1.\*
    - [Btcd](https://github.com/btcsuite/btcd) ([PR open](https://github.com/btcsuite/btcd/pull/656))
- [libblkmaker](https://github.com/bitcoin/libblkmaker) 0.6.0
- [Eloipool](https://github.com/luke-jr/eloipool) ([Branch available](https://github.com/luke-jr/eloipool/commits/segwit))
- [BFGMiner](https://github.com/luke-jr/bfgminer) 2.10.4+ (requires libblkmaker 0.6.0 or greater)
- [CGMiner](https://github.com/ckolivas/cgminer)
- [Bitcoin FIBRE](http://bitcoinfibre.org/)
- [The Bitcoin Relay Network](http://www.bitcoinrelaynetwork.org/) (see for details on upgrading to the new network)
<commit_msg>Update mining links<commit_after>---
title: Segregated Witness Upgrade Guide
name: segwit-upgrade-guide
id: en-segwit-upgrade-guide
type: posts
layout: post
lang: en
permalink: /en/2016/10/27/segwit-upgrade-guide/
version: 1
excerpt: Almost two years of iterative design, development, and testing has gone into the version of segwit being released in Bitcoin Core 0.13.1, with much of the effort over the last year focused on making it as easy as possible for existing Bitcoin users, businesses, developers, and miners to upgrade to segwit.
---
{% include _toc.html %}
{% include _references.md %}

Almost two years of iterative design, development, and testing has gone into the version of segwit being released in Bitcoin Core 0.13.1, with much of the effort over the last year focused on making it as easy as possible for existing Bitcoin users, businesses, developers, and miners to upgrade to segwit.

Initial segwit adoption requires the participation of two groups:

- **[Miners][miners guide]** representing 95% or more of the total Bitcoin network hash rate must signal support for segwit in order to  lock-in segwit’s activation.

- **[Full nodes][node guide]** run by a reasonable number of users and business to validate the payments they receive need to be upgraded to Bitcoin Core 0.13.1 or another segwit-compatible implementation in order to incentivize miners to follow segwit’s rules after segwit activates.  (This is Bitcoin’s normal incentivization mechanism where miners only receive income for generating a block if they follow all of the consensus rules, which will include the new segwit consensus rules once segwit activates.)

The segwit soft fork has been designed to allow individuals in both groups to voluntarily decide whether or not they want to adopt segwit, and guides are provided below for both those who want to adopt segwit and those who don’t.

If enough miners do decide to adopt segwit, it will eventually activate and wallet users will be able to begin creating transactions with segregated witnesses.  The segwit soft fork has also been designed to be both backwards and forwards compatible with all commonly-used wallets, so wallet developers and users can also independently decide whether they want to adopt segwit or continue making transactions without segregated witnesses.  Guides are provided below for both adopting and non-adopting [developers][dev guide] and [users][user guide].

In addition to instructions, the end of each guide section below also provides a short list of recommended places to ask any segwit-related questions you may have.

## Miners

*This section is written for solo miners and mining pool operators.  Pool miners should contact their pool operators for information about what they need to do (if anything) to upgrade or not upgrade to segwit.* 

The BIP9 soft fork deployment mechanism is being used for segwit---the same mechanism used for the BIP 68/112/113 soft fork that activated on 4 July 2016.  Whether you wish to upgrade or not, you should understand the important stages of the upgrade process:

- **Started:** Segwit will be in the *started* stage from the beginning of the first retarget period on or after 15 November 2016 until it either activates or is considered failed (under BIP9’s policy) after one year of not reaching locked-in.  During this time, miners who are willing and able to enforce segwit’s new consensus rules will be signaling their intent to do so by placing bit 1 in the block header versionbits field.

- **Locked-in:** if 95% of blocks during a 2,016-block retarget period signal support for segwit, the segwit soft-fork will be *locked-in* with *activation* scheduled for 2,016 blocks later (about two weeks).

- **Activated:** after the completion of the *locked-in* period, the miners who signaled readiness to enforce segwit will begin producing segwit-style blocks that contain transactions with segregated witnesses.


### Not upgrading

This section describes what you can do as a miner if you don’t want to enforce segwit.

During the *started* phase, if you don’t want to adopt segwit, you may simply refuse to upgrade to a segwit-compatible full node such as Bitcoin Core 0.13.1, as well as avoiding any mining software that assumes you want to set segwit’s versionbit of bit 1.

If segwit reaches *locked-in*, you still don’t need to upgrade, but upgrading is strongly recommended.  The segwit soft fork does not require you to produce segwit-style blocks, so you may continue producing non-segwit blocks indefinitely.  However, once segwit activates, it will be possible for other miners to produce blocks that you consider to be valid but which every segwit-enforcing node rejects; if you build any of your blocks upon those invalid blocks, your blocks will be considered invalid too.

For this reason, after segwit reaches *locked-in*, it is recommended that you either upgrade your full node to Bitcoin Core 0.13.1 or later (or a compatible full node), or that you follow the “not upgrading” instructions in the Full Node section below to use Bitcoin Core 0.13.1 or later as a filter for your pre-segwit software.

### Upgrading

The BIP9 parameters for the segwit soft fork allow miners to begin signaling their support for it at the beginning of the first retarget period on or after 15 November 2016.  To signal support, you will need to
do the following: 

- Upgrade the full node you use for transaction selection and block construction to Bitcoin Core 0.13.1 or another segwit-compatible full node.

- Upgrade your mining software, mining pool software, or both to a segwit-compatible version.

- Begin producing blocks containing segwit’s BIP9 versionbit, which is bit 1.

When segwit is activated, you will want to be able to mine and relay segwit-style blocks.  The following mining software has been upgraded to support segwit.

- Full nodes 
    - [Bitcoin Core](https://bitcoin.org/en/download) 0.13.1
    - [Bitcoin Knots](http://bitcoinknots.org/) 0.13.1.\*
    - [Btcd](https://github.com/btcsuite/btcd) ([PR open](https://github.com/btcsuite/btcd/pull/656))
- [libblkmaker](https://github.com/bitcoin/libblkmaker) 0.6.0
- [Eloipool](https://github.com/luke-jr/eloipool) ([Branch available](https://github.com/luke-jr/eloipool/commits/segwit))
- [BFGMiner](https://github.com/luke-jr/bfgminer) 2.10.4+ (requires libblkmaker 0.6.0 or greater)
- [ckpool](https://bitbucket.org/ckolivas/ckpool)
- [CGMiner](https://github.com/ckolivas/cgminer) (pull-request [pending](https://github.com/ckolivas/cgminer/pull/699))
- [Bitcoin FIBRE](http://bitcoinfibre.org/)
- [The Bitcoin Relay Network](http://www.bitcoinrelaynetwork.org/) (see for details on upgrading to the new network)

{'fraction_non_alphanumeric': 0.06176271695844917, 'fraction_numerical': 0.015553384927492675, 'mean_word_length': 4.484136794396374, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 18, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '669827', 'n_tokens_mistral': 3716, 'n_tokens_neox': 3441, 'n_words': 1893}