iotaledger / hornet

HORNET is a powerful IOTA fullnode software
Apache License 2.0
310 stars 151 forks source link

Error when running for the first time: no download URL specified for snapshot files in config #1143

Closed qlereboursBS closed 3 years ago

qlereboursBS commented 3 years ago

Describe the bug We ran hornet and had this error: no download URL specified for snapshot files in config

To Reproduce

The output of the command is above

Expected behavior According to the documentation they should be downloaded automatically from trusted source thanks to hornet, and we shouldn't have this error.

Environment information:

Additional context

No profiles config file found via 'profiles.json'. Loading default settings.Parameters loaded: 
 {
  "coordinator": {
    "checkpoints": {
      "maxtrackedmessages": 10000
    },
    "interval": "10s",
    "powworkercount": 1,
    "quorum": {
      "enabled": false,
      "timeout": "2s"
    },
    "signing": {
      "provider": "local",
      "remoteaddress": "localhost:12345"
    },
    "statefilepath": "coordinator.state",
    "tipsel": {
      "heaviestbranchselectiontimeout": "100ms",
      "maxheaviestbranchtipspercheckpoint": 10,
      "minheaviestbranchunreferencedmessagesthreshold": 20,
      "randomtipspercheckpoint": 3
    }
  },
  "dashboard": {
    "auth": {
      "sessiontimeout": "72h",
      "username": "admin"
    },
    "bindaddress": "0.0.0.0:8081",
    "dev": false
  },
  "db": {
    "autorevalidation": false,
    "debug": false,
    "engine": "rocksdb",
    "path": "mainnetdb"
  },
  "debug": {
    "whiteflagparentssolidtimeout": "2s"
  },
  "gossip": {
    "streamreadtimeout": "1m0s",
    "streamwritetimeout": "10s"
  },
  "migrator": {
    "querycooldownperiod": "5s",
    "receiptmaxentries": 110,
    "statefilepath": "migrator.state"
  },
  "mqtt": {
    "bindaddress": "localhost:1883",
    "workercount": 100,
    "wsport": 1888
  },
  "node": {
    "alias": "",
    "disableplugins": [],
    "enableplugins": [],
    "profile": "auto"
  },
  "p2p": {
    "bindmultiaddresses": [
      "/ip4/127.0.0.1/tcp/15600"
    ],
    "connectionmanager": {
      "highwatermark": 10,
      "lowwatermark": 5
    },
    "gossipunknownpeerslimit": 4,
    "peerstore": {
      "path": "./p2pstore"
    },
    "reconnectinterval": "30s"
  },
  "p2pdisc": {
    "advertiseinterval": "30s",
    "maxdiscoveredpeerconns": 4,
    "rendezvouspoint": "between-two-vertices",
    "routingtablerefreshperiod": "1m0s"
  },
  "pow": {
    "refreshtipsinterval": "5s"
  },
  "profiling": {
    "bindaddress": "localhost:6060"
  },
  "prometheus": {
    "bindaddress": "localhost:9311",
    "cachesmetrics": true,
    "coordinatormetrics": true,
    "databasemetrics": true,
    "debugmetrics": false,
    "fileservicediscovery": {
      "enabled": false,
      "path": "target.json",
      "target": "localhost:9311"
    },
    "gometrics": false,
    "gossipmetrics": true,
    "migrationmetrics": true,
    "nodemetrics": true,
    "processmetrics": false,
    "promhttpmetrics": false,
    "restapimetrics": true
  },
  "protocol": {
    "bech32hrp": "iota",
    "milestonepublickeycount": 2,
    "minpowscore": "4000",
    "networkid": "iota"
  },
  "pruning": {
    "milestones": {
      "enabled": false,
      "maxmilestonestokeep": 60480
    },
    "prunereceipts": false,
    "size": {
      "cooldowntime": "5m0s",
      "enabled": true,
      "targetsize": "30GB",
      "thresholdpercentage": "10"
    }
  },
  "receipts": {
    "backup": {
      "enabled": false,
      "folder": "receipts"
    },
    "validator": {
      "api": {
        "address": "http://localhost:14266",
        "timeout": "5s"
      },
      "coordinator": {
        "address": "JFQ999DVN9CBBQX9DSAIQRAFRALIHJMYOXAQSTCJLGA9DLOKIWHJIFQKMCQ9QHWW9RXQMDBVUIQNIY9GZ",
        "merkletreedepth": 18
      },
      "ignoresofterrors": false,
      "validate": false
    }
  },
  "requests": {
    "discardolderthan": "15s",
    "pendingreenqueueinterval": "5s"
  },
  "restapi": {
    "bindaddress": "0.0.0.0:14265",
    "excludehealthcheckfromauth": false,
    "jwtauth": {
      "enabled": false
    },
    "limits": {
      "bodylength": "1M",
      "maxresults": 1000
    },
    "permittedroutes": [
      "/health",
      "/mqtt",
      "/api/v1/info",
      "/api/v1/tips",
      "/api/v1/messages/:messageID",
      "/api/v1/messages/:messageID/metadata",
      "/api/v1/messages/:messageID/raw",
      "/api/v1/messages/:messageID/children",
      "/api/v1/messages",
      "/api/v1/transactions/:transactionID/included-message",
      "/api/v1/milestones/:milestoneIndex",
      "/api/v1/milestones/:milestoneIndex/utxo-changes",
      "/api/v1/outputs/:outputID",
      "/api/v1/addresses/:address",
      "/api/v1/addresses/:address/outputs",
      "/api/v1/addresses/ed25519/:address",
      "/api/v1/addresses/ed25519/:address/outputs"
    ],
    "powenabled": false,
    "powworkercount": 1,
    "whitelistedaddresses": [
      "127.0.0.1",
      "::1"
    ]
  },
  "snapshots": {
    "deltapath": "snapshots/mainnet/delta_snapshot.bin",
    "deltasizethresholdpercentage": "50",
    "depth": 50,
    "fullpath": "snapshots/mainnet/full_snapshot.bin",
    "interval": 50
  },
  "spammer": {
    "autostart": false,
    "cpumaxusage": "0.5",
    "index": "HORNET Spammer",
    "indexsemilazy": "HORNET Spammer Semi-Lazy",
    "message": "Binary is the future.",
    "mpsratelimit": "0",
    "workers": 1
  },
  "tangle": {
    "milestonetimeout": "30s"
  },
  "tipsel": {
    "belowmaxdepth": 15,
    "maxdeltamsgoldestconerootindextocmi": 13,
    "maxdeltamsgyoungestconerootindextocmi": 8,
    "nonlazy": {
      "maxchildren": 30,
      "maxreferencedtipage": "3s",
      "retentionrulestipslimit": 100,
      "spammertipsthreshold": 0
    },
    "semilazy": {
      "maxchildren": 2,
      "maxreferencedtipage": "3s",
      "retentionrulestipslimit": 20,
      "spammertipsthreshold": 30
    }
  },
  "warpsync": {
    "advancementrange": 150
  }
}

              ██╗  ██╗ ██████╗ ██████╗ ███╗   ██╗███████╗████████╗
              ██║  ██║██╔═══██╗██╔══██╗████╗  ██║██╔════╝╚══██╔══╝
              ███████║██║   ██║██████╔╝██╔██╗ ██║█████╗     ██║
              ██╔══██║██║   ██║██╔══██╗██║╚██╗██║██╔══╝     ██║
              ██║  ██║╚██████╔╝██║  ██║██║ ╚████║███████╗   ██║
              ╚═╝  ╚═╝ ╚═════╝ ╚═╝  ╚═╝╚═╝  ╚═══╝╚══════╝   ╚═╝
                                   v1.0.3

2021-07-24T13:27:05Z    INFO    App app/app.go:174  Loading plugins ...
2021-07-24T13:27:05Z    INFO    Profile profile/core.go:62  Profile mode 'auto', Using profile '4gb'
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: Profile ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: ProtoCfg ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: Graceful Shutdown ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: Database ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: PoW ... done
2021-07-24T13:27:05Z    INFO    P2P p2p/core.go:215 never share your ./p2pstore folder as it contains your node's private key!
2021-07-24T13:27:05Z    INFO    P2P p2p/core.go:222 retrieved existing peer identity from p2pstore/key.pub
2021-07-24T13:27:05Z    INFO    P2P p2p/core.go:225 peer configured, ID: *******
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: P2P ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: Gossip ... done
2021-07-24T13:27:05Z    INFO    Node    node/node.go:214    Loading core plugin: Tangle ... done
2021-07-24T13:27:05Z    PANIC   Snapshot    snapshot/core.go:186    no download URL specified for snapshot files in config
github.com/gohornet/hornet/core/snapshot.configure
    /__w/hornet/hornet/core/snapshot/core.go:186
github.com/gohornet/hornet/pkg/node.(*Node).configure.func1
    /__w/hornet/hornet/pkg/node/node.go:212
github.com/gohornet/hornet/pkg/node.forEachCorePlugin
    /__w/hornet/hornet/pkg/node/node.go:320
github.com/gohornet/hornet/pkg/node.(*Node).ForEachCorePlugin
    /__w/hornet/hornet/pkg/node/node.go:328
github.com/gohornet/hornet/pkg/node.(*Node).configure
    /__w/hornet/hornet/pkg/node/node.go:210
github.com/gohornet/hornet/pkg/node.New
    /__w/hornet/hornet/pkg/node/node.go:49
github.com/gohornet/hornet/pkg/node.Run
    /__w/hornet/hornet/pkg/node/node.go:62
main.main
    /__w/hornet/hornet/main.go:33
runtime.main
    /usr/local/go/src/runtime/proc.go:225
panic: no download URL specified for snapshot files in config

goroutine 1 [running]:
go.uber.org/zap/zapcore.(*CheckedEntry).Write(0xc0008d0300, 0x0, 0x0, 0x0)
    /github/home/go/pkg/mod/go.uber.org/zap@v1.16.0/zapcore/entry.go:234 +0x58d
go.uber.org/zap.(*SugaredLogger).log(0xc00011f4c0, 0x4, 0x0, 0x0, 0xc000c59d30, 0x1, 0x1, 0x0, 0x0, 0x0)
    /github/home/go/pkg/mod/go.uber.org/zap@v1.16.0/sugar.go:234 +0xf6
go.uber.org/zap.(*SugaredLogger).Panic(...)
    /github/home/go/pkg/mod/go.uber.org/zap@v1.16.0/sugar.go:123
github.com/gohornet/hornet/core/snapshot.configure()
    /__w/hornet/hornet/core/snapshot/core.go:186 +0x119
github.com/gohornet/hornet/pkg/node.(*Node).configure.func1(0xc0001305f0, 0x1b70f01)
    /__w/hornet/hornet/pkg/node/node.go:212 +0xdd
github.com/gohornet/hornet/pkg/node.forEachCorePlugin(0xc0000c3e00, 0x9, 0x10, 0xc000c59e40)
    /__w/hornet/hornet/pkg/node/node.go:320 +0x51
github.com/gohornet/hornet/pkg/node.(*Node).ForEachCorePlugin(...)
    /__w/hornet/hornet/pkg/node/node.go:328
github.com/gohornet/hornet/pkg/node.(*Node).configure(0xc0004128c0)
    /__w/hornet/hornet/pkg/node/node.go:210 +0x7c
github.com/gohornet/hornet/pkg/node.New(0xc00089ff60, 0x3, 0x3, 0x1c58060)
    /__w/hornet/hornet/pkg/node/node.go:49 +0x248
github.com/gohornet/hornet/pkg/node.Run(0xc00089ff60, 0x3, 0x3, 0xc000281da0)
    /__w/hornet/hornet/pkg/node/node.go:62 +0x3f
main.main()
    /__w/hornet/hornet/main.go:33 +0x334
muXxer commented 3 years ago

Thank you for the bug report. Fixed for mainnet config with #1162