CentOS stream 9 :ganache installと 起動option

1.Ethereum のローカル開発環境をinstall

# npm install ganache

added 29 packages, and audited 360 packages in 2m

55 packages are looking for funding
  run `npm fund` for details

4 vulnerabilities (3 high, 1 critical)

To address all issues, run:
  npm audit fix

Run `npm audit` for details.
# npm audit fix

added 4 packages, changed 5 packages, and audited 364 packages in 6s

55 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
]# npm fund
privateinvoice@0.0.1
tqq https://opencollective.com/node-redis
x   mqq redis@3.1.2
tqw https://opencollective.com/eslint
x x mqq eslint@8.13.0
x tqq https://github.com/sponsors/epoberezkin
x x   mqq ajv@6.12.6
x tqw https://github.com/chalk/chalk?sponsor=1
x x x mqq chalk@4.1.2
x x mqq https://github.com/chalk/ansi-styles?sponsor=1
x x     mqq ansi-styles@4.3.0
x tqq https://github.com/sponsors/sindresorhus
x x   mqq escape-string-regexp@4.0.0, globals@13.13.0, type-fest@0.20.2, import-fresh@3.3.0, strip-json-comments@3.1.1, make-dir@3.1.0
x mqq https://github.com/sponsors/mysticatea
x     mqq eslint-utils@3.0.0, regexpp@3.2.0
tqq https://github.com/sponsors/RubenVerborgh
x   mqq follow-redirects@1.14.9
tqq https://github.com/sponsors/isaacs
x   mqq rimraf@3.0.2, glob@7.1.7
tqq https://github.com/sponsors/feross
x   mqq safe-buffer@5.2.1
mqq https://github.com/sponsors/ljharb
    mqq array-includes@3.1.4, call-bind@1.0.2, define-properties@1.1.4, has-property-descriptors@1.0.0, es-abstract@1.19.5, es-to-primitive@1.2.1, is-date-object@1.0.5, has-tostringtag@1.0.0, is-symbol@1.0.4, get-symbol-description@1.0.0, has-symbols@1.0.3, is-callable@1.2.4, is-negative-zero@2.0.2, is-regex@1.1.4, is-shared-array-buffer@1.0.2, is-weakref@1.0.2, object-inspect@1.12.0, object.assign@4.1.2, string.prototype.trimend@1.0.4, string.prototype.trimstart@1.0.4, unbox-primitive@1.0.1, has-bigints@1.0.2, which-boxed-primitive@1.0.2, is-bigint@1.0.4, is-boolean-object@1.1.2, is-number-object@1.0.7, side-channel@1.0.4, get-intrinsic@1.1.1, is-string@1.0.7, array.prototype.flatmap@1.3.0, object.fromentries@2.0.5, object.hasown@1.1.0, object.values@1.1.5, resolve@2.0.0-next.3, is-core-module@2.9.0, string.prototype.matchall@4.0.7, regexp.prototype.flags@1.4.3, functions-have-names@1.2.3
#

2.ganache 起動option

# ganache -d --db /opt/ganache/db

(1) ganache は起動毎に、 AccountsとPrivate Keysが変わる
AccountsとPrivate Keysを初期状態で固定するには、-d optionをつけて起動

# ganache -d

(2) データの永続化のディレクトリ作成

# mkdir /opt/ganache/
# mkdir /opt/ganache/db

(3) データの永続化
–dbでsaveディレクトリを指定

# ganache --db /opt/ganache/db

3. データの永続化の確認

# cd /opt/ganache/db
# pwd
/opt/ganache/db
# ls
000003.log  CURRENT  LOCK  LOG  MANIFEST-000002
#