Bitcoin Forum
May 07, 2024, 04:42:44 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Change location of database.  (Read 1024 times)
yochdog (OP)
Legendary
*
Offline Offline

Activity: 2044
Merit: 1000



View Profile
December 27, 2012, 04:58:40 PM
 #1

I thought I wanted to move my .dat file......I was mistaken.

I want to change the location where the blockchain is stored.  I am running out of room on my SSD, but have gobs of network storage. 

Can anyone give me a quick guide to changing where the database is stored? 

I am a trusted trader!  Ask Inaba, Luo Demin, Vanderbleek, Sannyasi, Episking, Miner99er, Isepick, Amazingrando, Cablez, ColdHardMetal, Dextryn, MB300sd, Robocoder, gnar1ta$ and many others!
1715100164
Hero Member
*
Offline Offline

Posts: 1715100164

View Profile Personal Message (Offline)

Ignore
1715100164
Reply with quote  #2

1715100164
Report to moderator
1715100164
Hero Member
*
Offline Offline

Posts: 1715100164

View Profile Personal Message (Offline)

Ignore
1715100164
Reply with quote  #2

1715100164
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
Meni Rosenfeld
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1054



View Profile WWW
December 27, 2012, 05:02:06 PM
 #2

The blockchain is stored in the data directory, which can be configured with the datadir parameter. For example:
Code:
"C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe" -datadir="E:\Data\Bitcoin"
Note that the wallet file is also stored in the data directory.

Symlinks may also be of use to you.

1EofoZNBhWQ3kxfKnvWkhtMns4AivZArhr   |   Who am I?   |   bitcoin-otc WoT
Bitcoil - Exchange bitcoins for ILS (thread)   |   Israel Bitcoin community homepage (thread)
Analysis of Bitcoin Pooled Mining Reward Systems (thread, summary)  |   PureMining - Infinite-term, deterministic mining bond
yochdog (OP)
Legendary
*
Offline Offline

Activity: 2044
Merit: 1000



View Profile
December 27, 2012, 05:07:47 PM
 #3

The blockchain is stored in the data directory, which can be configured with the datadir parameter. For example:
Code:
"C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe" -datadir="E:\Data\Bitcoin"
Note that the wallet file is also stored in the data directory.

Symlinks may also be of use to you.

so that command will change the database to sit on the E: drive? 

I am a trusted trader!  Ask Inaba, Luo Demin, Vanderbleek, Sannyasi, Episking, Miner99er, Isepick, Amazingrando, Cablez, ColdHardMetal, Dextryn, MB300sd, Robocoder, gnar1ta$ and many others!
Meni Rosenfeld
Donator
Legendary
*
Offline Offline

Activity: 2058
Merit: 1054



View Profile WWW
December 27, 2012, 05:24:08 PM
 #4

The blockchain is stored in the data directory, which can be configured with the datadir parameter. For example:
Code:
"C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe" -datadir="E:\Data\Bitcoin"
Note that the wallet file is also stored in the data directory.

Symlinks may also be of use to you.

so that command will change the database to sit on the E: drive? 
If you run Bitcoin with this command (as opposed to running it without this parameter), it will look for the database in the E:\Data\Bitcoin directory, and as necessary download it to that directory.

How you use it exactly depends on your exact setup, but assuming you have a Windows machine and a shortcut that points to "C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe", and you want the database to reside in E:\Data\Bitcoin (or any other directory), you should:

1. Move your already existing database to E:\Data\Bitcoin.
2. Change the shortcut to point to "C:\Program Files (x86)\Bitcoin\bitcoin-qt.exe" -datadir="E:\Data\Bitcoin".

1EofoZNBhWQ3kxfKnvWkhtMns4AivZArhr   |   Who am I?   |   bitcoin-otc WoT
Bitcoil - Exchange bitcoins for ILS (thread)   |   Israel Bitcoin community homepage (thread)
Analysis of Bitcoin Pooled Mining Reward Systems (thread, summary)  |   PureMining - Infinite-term, deterministic mining bond
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!