Author

Topic: Possible to specify a different location for bootstrap.dat (Read 1009 times)

legendary
Activity: 1512
Merit: 1036
To answer the subject, yes, it is possible to specify a different location for bootstrap.dat by using a full path with this command line option:

bitcoin -loadblock=(filename)
Imports blocks from external blk000??.dat formatted files on startup

Any file that has blocks stored in the original bitcoin format will work. 2GB or 128MB blocks from the bitcoin data directory or the torrent dat. Blocks that have already been imported will be skipped.

Multiple files can be imported in one command as long as they contain continuous chronological blocks:

bitcoin -loadblock=blk00000.dat -loadblock=blk00001.dat -loadblock=blk00002.dat
administrator
Activity: 5222
Merit: 13032
I think starting with Windows Vista, you can use MKLink to create junctions to different directories, while giving the appearance that the directory is in the same local directory. So you could use this to move your Bitcoin blockchain pretty much wherever you want.

mklink /j [Directory1] [Directory2]

Right. The location pointed-to by -datadir should always really contain your wallet-related files (wallet.dat, db.log, database directory, .lock) but in my experience it's totally fine to replace any of the other files/directories with symlinks.

I don't know whether mklink /j will create the right type of link, though. Isn't that for directories?
legendary
Activity: 4256
Merit: 1313
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....

What he means is that bootstrap.dat has not been useful since bitcoin 0.10.x and up due to headers first sync.  Consequently, it is often in fact slower to use the .dat file compared to just connecting to the bitcoin network.
From what I read it's faster to just download with the client than to download the bootstrap.dat separately, but surely it's faster to use bootstrap.dat if you already have it, right? Maybe I'll give it a try later and see how it goes.

Maybe, it could be just about the same if the bottleneck is your CPU or memory.  :-)




If you are on a metered connection the savings in the cost of bandwidth might make using a bootstrap.dat downloaded elsewhere preferable. Downloading a bootstrap.dat on a free connection at work or elsewhere could be the only viable option for those with limited bandwidth at home.

Good point.  For this use case, that is one option. 
member
Activity: 62
Merit: 10
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....

What he means is that bootstrap.dat has not been useful since bitcoin 0.10.x and up due to headers first sync.  Consequently, it is often in fact slower to use the .dat file compared to just connecting to the bitcoin network.
From what I read it's faster to just download with the client than to download the bootstrap.dat separately, but surely it's faster to use bootstrap.dat if you already have it, right? Maybe I'll give it a try later and see how it goes.

Maybe, it could be just about the same if the bottleneck is your CPU or memory.  :-)




If you are on a metered connection the savings in the cost of bandwidth might make using a bootstrap.dat downloaded elsewhere preferable. Downloading a bootstrap.dat on a free connection at work or elsewhere could be the only viable option for those with limited bandwidth at home.
legendary
Activity: 4256
Merit: 1313
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....

What he means is that bootstrap.dat has not been useful since bitcoin 0.10.x and up due to headers first sync.  Consequently, it is often in fact slower to use the .dat file compared to just connecting to the bitcoin network.
From what I read it's faster to just download with the client than to download the bootstrap.dat separately, but surely it's faster to use bootstrap.dat if you already have it, right? Maybe I'll give it a try later and see how it goes.

Maybe, it could be just about the same if the bottleneck is your CPU or memory.  :-)


copper member
Activity: 1498
Merit: 1528
No I dont escrow anymore.
even when I do specify -datadir it doesn't load the bootstrap file...

Check the debug.log IIRC there is no "Im using the file you gave me" message in the GUI. To your other question: what cr1776 said.

-snip-
From what I read it's faster to just download with the client than to download the bootstrap.dat separately, but surely it's faster to use bootstrap.dat if you already have it, right? Maybe I'll give it a try later and see how it goes.

Depends on the systems bottleneck, but it shouldnt be slower if you already have it.
sr. member
Activity: 433
Merit: 267
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....

What he means is that bootstrap.dat has not been useful since bitcoin 0.10.x and up due to headers first sync.  Consequently, it is often in fact slower to use the .dat file compared to just connecting to the bitcoin network.
From what I read it's faster to just download with the client than to download the bootstrap.dat separately, but surely it's faster to use bootstrap.dat if you already have it, right? Maybe I'll give it a try later and see how it goes.
legendary
Activity: 4256
Merit: 1313
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....

What he means is that bootstrap.dat has not been useful since bitcoin 0.10.x and up due to headers first sync.  Consequently, it is often in fact slower to use the .dat file compared to just connecting to the bitcoin network.

sr. member
Activity: 433
Merit: 267
Ok, I ran BitcoinQT to make sure I wasn't telling you a bunch of crap and it's working fine for me. I installed BitcoinQT in the default directory and then I did the following two commands after making a folder called "My Path" in the root directory;

C:\Users\UserName>cd C:\Program Files\Bitcoin

C:\Program Files\Bitcoin>bitcoin-qt.exe -datadir="C:/My Path"

Be sure to put the bootstrap.dat file under the "blocks" folder in your data directory. So from my example it would be "C:/My Path/blocks/bootstrap.dat"
sr. member
Activity: 348
Merit: 251
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.

Can you clarify what you mean? I'm using the most current client bitcoin-qt 32bit and on opening it's showing 6 years behind.....

Christ I can't believe bitcoin has been around that long now....
sr. member
Activity: 348
Merit: 251
even when I do specify -datadir it doesn't load the bootstrap file...
sr. member
Activity: 433
Merit: 267
I think starting with Windows Vista, you can use MKLink to create junctions to different directories, while giving the appearance that the directory is in the same local directory. So you could use this to move your Bitcoin blockchain pretty much wherever you want.

mklink /j [Directory1] [Directory2]

http://www.sevenforums.com/tutorials/278262-mklink-create-use-links-windows.html

You can also change the data directory via a command line switch when starting your Bitcoin client. The same thing can also be specified in your bitcoin.conf file.

-datadir=

https://en.bitcoin.it/wiki/Running_Bitcoin#Sample_Bitcoin.conf
copper member
Activity: 1498
Merit: 1528
No I dont escrow anymore.
I want to use an external drive because my ssd has limited space.

Thanks.

the bootstrap.dat goes in the -datadir= folder. With newer version using the bootstrap.dat is only useful under certain conditions, if you have not yet downloaded it, you can just skip it.
sr. member
Activity: 348
Merit: 251
I want to use an external drive because my ssd has limited space.

Thanks.
Jump to: