user89384: I am using bitcoin.rpc.RawProxy to connect to bitcoind and scrape the data. But I am getting an error when I gettransaction and I have to reindex the blockchain. Thus I am wondering how I set the txindex to 1 so I can reindex and continue.

user60443: You can enable the txindex by either adding it to your bitcoin.conf file:
txindex=1

or
You can run bitcoind with the -txindex flag:
$ bitcoind -txindex

See:
$ bitcoind --help

    -txindex
       Maintain a full transaction index, used by the getrawtransaction rpc
       call (default: 0)


89384: <p>I am using bitcoin.rpc.RawProxy to connect to bitcoind and scrape the data. But I am getting an error when I <code>gettransaction</code> and I have to reindex the blockchain. Thus I am wondering how I set the txindex to 1 so I can reindex and continue.</p>
 60443: <p>You can enable the <code>txindex</code> by either adding it to your <code>bitcoin.conf</code> file:</p>

<pre><code>txindex=1
</code></pre>

<p>or</p>

<p>You can run <code>bitcoind</code> with the <code>-txindex</code> flag:</p>

<pre><code>$ bitcoind -txindex
</code></pre>

<p>See:</p>

<pre><code>$ bitcoind --help

    -txindex
       Maintain a full transaction index, used by the getrawtransaction rpc
       call (default: 0)
</code></pre>
