I don’t know if I’m doing something supported here, but this doesn’t seem to work for me:
0./src/bitcoind -datadir=/tmp/bitcoin_27302/ -rpcport=18555 -port=18556
02023-03-27T21:22:09Z Default data directory /home/will/.bitcoin
12023-03-27T21:22:09Z Using data directory /tmp/bitcoin_27302/regtest
22023-03-27T21:22:09Z Config file: /tmp/bitcoin_27302/bitcoin.conf
32023-03-27T21:22:09Z Config file arg: datadir="/tmp/bitcoin_27302/datadir2"
42023-03-27T21:22:09Z Config file arg: regtest="1"
52023-03-27T21:22:09Z Command-line arg: datadir="/tmp/bitcoin_27302/"
62023-03-27T21:22:09Z Command-line arg: port="18556"
72023-03-27T21:22:09Z Command-line arg: rpcport="18555"
82023-03-27T21:22:09Z Using at most 125 automatic connections (1024 file descriptors available)
I am specifying -datadir=
on the command line (to start with a non-default datadir). This first datadir contains a bitcoin.conf
file which contains a second datadir=
option, where the second datadir also contains a second bitcoin.conf
but I don’t see the warning?
The port=
option in datadir2/bitcoin.conf
is being ignored:
0will@ubuntu in /tmp/bitcoin_27302
1βΏ tree
2.
3βββ bitcoin.conf
4βββ datadir2
5βΒ Β βββ bitcoin.conf
6βββ regtest
7 βββ banlist.json
8 βββ bitcoind.pid
9 βββ blocks
10 βΒ Β βββ blk00000.dat
11 βΒ Β βββ index
12 βΒ Β βΒ Β βββ 000015.log
13 βΒ Β βΒ Β βββ 000016.ldb
14 βΒ Β βΒ Β βββ CURRENT
15 βΒ Β βΒ Β βββ LOCK
16 βΒ Β βΒ Β βββ MANIFEST-000013
17 βΒ Β βββ rev00000.dat
18 βββ chainstate
19 βΒ Β βββ 000005.ldb
20 βΒ Β βββ 000025.ldb
21 βΒ Β βββ 000027.log
22 βΒ Β βββ CURRENT
23 βΒ Β βββ LOCK
24 βΒ Β βββ MANIFEST-000026
25 βββ debug.log
26 βββ fee_estimates.dat
27 βββ mempool.dat
28 βββ onion_v3_private_key
29 βββ peers.dat
30 βββ settings.json
31 βββ wallets
32
336 directories, 23 files
34
35will@ubuntu in /tmp/bitcoin_27302
36βΏ cat bitcoin.conf
37regtest=1
38datadir=/tmp/bitcoin_27302/datadir2
39
40will@ubuntu in /tmp/bitcoin_27302
41βΏ cat datadir2/bitcoin.conf
42port=18557
I don’t see yet where the error is here, but suspect I might have short circuited it by providing a -datadir command line option intially?