Reload IR config on SIGHUP #125

Closed
opened 2023-03-09 11:34:45 +00:00 by ironbee · 1 comment
Contributor
  • Set logging level
  • Configure pprof and prometheus
  • Set extra wallets for regular transfers
- [x] Set logging level - [x] Configure pprof and prometheus - [x] Set extra wallets for regular transfers
ironbee added the
triage
label 2023-03-09 11:34:45 +00:00
fyrchik added this to the v0.37.0 milestone 2023-04-11 08:23:55 +00:00
acid-ant self-assigned this 2023-04-12 08:45:04 +00:00
fyrchik added the
frostfs-ir
P1
labels 2023-04-14 09:10:13 +00:00
Member

How to change log level (used dev-env as reference installation):

  • make up && sleep 40 && make prepare.ir && sudo make prepare.storage
  • vi services/ir/cfg/config.yml: edit line level: debug # Minimum enabled logging level
  • send SIGHUP: docker exec -it ir01 kill -1 1
  • check ir log for new presence of corresponding log entries: docker logs ir01 2>&1 | less

To validate pprof/metrics need to change corresponding sections in services/ir/cfg/config.yml

# Profiler section
pprof:
  enabled: true
...
# Application metrics section
prometheus:
  enabled: true
...

Use neo-go to create new wallet:

annikifa@annikiforov:~/workspace/frostfs-api-go$ docker exec -it morph_chain neo-go wallet init -a -w wallets/wallet_new.json
...
{
 	"version": "1.0",
 	"accounts": [
 		{
 			"address": "NUp82P6Wi64xmKwsXZG86mvvD1hvw5dA94",
...

Edit services/ir/cfg/config.yml in section # Storage node GAS emission settings

emit:
  extra_wallets: 
    - NfmG238LD9U3SZYKtWS4EhiGdPFWbykq6K
    - NbUgTSFvPmsRxmGeWpuuGeJUoRoi6PErcM
    - NUp82P6Wi64xmKwsXZG86mvvD1hvw5dA94

Wait for a while for presence in log following line:

$ docker logs ir01 2>&1 | less
...
2023-05-16T07:05:13.589Z        debug   alphabet/process_emit.go:61     gas emission    {"network_map": 4, "extra_wallets": 1}
...

Check gas amount in wallet:

$ docker exec -it morph_chain neo-go wallet nep17 balance -w wallets/wallet.json -r http://morph-chain.frostfs.devenv:30333
Account NbUgTSFvPmsRxmGeWpuuGeJUoRoi6PErcM
GAS: GasToken (d2a4cff31913016155e38e474a2c06d08be276cf)
	Amount : 814.99999674
	Updated: 24522

How to change log level (used dev-env as reference installation): - `make up && sleep 40 && make prepare.ir && sudo make prepare.storage` - `vi services/ir/cfg/config.yml`: edit line `level: debug # Minimum enabled logging level` - send SIGHUP: `docker exec -it ir01 kill -1 1` - check ir log for new presence of corresponding log entries: `docker logs ir01 2>&1 | less` To validate pprof/metrics need to change corresponding sections in `services/ir/cfg/config.yml` ``` # Profiler section pprof: enabled: true ... # Application metrics section prometheus: enabled: true ... ``` Use neo-go to create new wallet: ``` annikifa@annikiforov:~/workspace/frostfs-api-go$ docker exec -it morph_chain neo-go wallet init -a -w wallets/wallet_new.json ... { "version": "1.0", "accounts": [ { "address": "NUp82P6Wi64xmKwsXZG86mvvD1hvw5dA94", ... ``` Edit `services/ir/cfg/config.yml` in section `# Storage node GAS emission settings` ``` emit: extra_wallets: - NfmG238LD9U3SZYKtWS4EhiGdPFWbykq6K - NbUgTSFvPmsRxmGeWpuuGeJUoRoi6PErcM - NUp82P6Wi64xmKwsXZG86mvvD1hvw5dA94 ``` Wait for a while for presence in log following line: ``` $ docker logs ir01 2>&1 | less ... 2023-05-16T07:05:13.589Z debug alphabet/process_emit.go:61 gas emission {"network_map": 4, "extra_wallets": 1} ... ``` Check gas amount in wallet: ``` $ docker exec -it morph_chain neo-go wallet nep17 balance -w wallets/wallet.json -r http://morph-chain.frostfs.devenv:30333 Account NbUgTSFvPmsRxmGeWpuuGeJUoRoi6PErcM GAS: GasToken (d2a4cff31913016155e38e474a2c06d08be276cf) Amount : 814.99999674 Updated: 24522 ```
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#125
No description provided.