简体   繁体   中英

Could not complete Bundlr tx upload successfully, exiting due to: Error: connect ETIMEDOUT 172.3 at TCPConnectWrap.afterConnect [as oncomplete]

I have checked everything else before this step and it works fine.

  1. clone candy machine
  2. install dependencies
  3. check version
  4. add assets
  5. verify assets
  6. upload (error happens in this step).

Also this works fine when I upload 100 imgs+json pairs but if I tried to increase the number it shows this error.

I use metaplex to deploy nfts on Solana using this command

ts-node ./metaplex/js/packages/cli/src/candy-machine-v2-cli.ts upload \
-e mainnet-beta \
-k ./wallets/Admin.json \
-cp config.json \
./assets

This error shows when uploading nfts using metaplex

Using cluster mainnet-beta
Beginning the upload for 1000 (img+json) pairs
started at: 1656840826997
config for a candy machine with publickey: 7DboQ5o2h78D6YnPHt2vQGgHbv9GGLtNbagXsFvqd84u has been already initialized
[0] out of [1000] items have been uploaded
Starting upload for [1000] items, format {"mediaExt":".png","index":"0"}
0.00527584 SOL to upload 23.167MB with buffer
Current balance 2.055307683 is sufficient.
Computed Bundle range, including 1000 file pair(s) totaling 23.167MB.
Processing file groups...
Progress: [████████████████████████████████████████] 100% | 1000/1000
Uploading bundle via Bundlr... in multiple transactions
Progress: [███████████████░░░░░░░░░░░░░░░░░░░░░░░░░] 37% | 1112/3000
Could not complete Bundlr tx upload successfully, exiting due to:  Error: connect ETIMEDOUT 172.3
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1187:16) {
  errno: -4039,
  code: 'ETIMEDOUT',
  syscall: 'connect',
  address: '172.67.72.157',
  port: 443,
  config: {
    transitional: {
      silentJSONParsing: true,
      forcedJSONParsing: true,
      clarifyTimeoutError: false
    },
    adapter: [Function: httpAdapter],
    transformRequest: [ [Function: transformRequest] ],
    transformResponse: [ [Function: transformResponse] ],
    timeout: 60000,
    xsrfCookieName: 'XSRF-TOKEN',
    xsrfHeaderName: 'X-XSRF-TOKEN',
    maxContentLength: 536870912,
    maxBodyLength: Infinity,
    validateStatus: [Function: validateStatus],
    headers: {
      Accept: 'application/json, text/plain, */*',
      'Content-Type': 'application/octet-stream',
      'User-Agent': 'axios/0.25.0',
      'Content-Length': 7267
    },
    baseURL: 'https://node1.bundlr.network:443',
    method: 'post',
    url: 'https://node1.bundlr.network:443/tx/solana',
    data: <Buffer 02 00 e2 ae 36 52 fc 98 d3 d9 17 c7 7a c6 38 92 19 08 8f 62 f9 48 df bf 94 13 >
  },
  request: <ref *1> Writable {
    _writableState: WritableState {
      objectMode: false,
      highWaterMark: 16384,
      finalCalled: false,
      needDrain: false,
      ending: false,
      ended: false,
      finished: false,
      destroyed: false,
      decodeStrings: true,
      defaultEncoding: 'utf8',
      length: 0,
      writing: false,
      corked: 0,
      sync: true,
      bufferProcessing: false,
      onwrite: [Function: bound onwrite],
      writecb: null,
      writelen: 0,
      afterWriteTickInfo: null,
      buffered: [],
      bufferedIndex: 0,
      allBuffers: true,
      allNoop: true,
      pendingcb: 0,
      constructed: true,
      prefinished: false,
      errorEmitted: false,
      emitClose: true,
      autoDestroy: true,
      errored: null,
      closed: false,
      closeEmitted: false,
      [Symbol(kOnFinished)]: []
    },
    _events: [Object: null prototype] {
      response: [Function: handleResponse],
      error: [Function: handleRequestError],
      socket: [Array]
    },
    _eventsCount: 3,
    _maxListeners: undefined,
    _options: {
      maxRedirects: 21,
      maxBodyLength: Infinity,
      protocol: 'https:',
      path: '/tx/solana',
      method: 'POST',
      headers: [Object],
      agent: undefined,
      agents: [Object],
      auth: undefined,
      hostname: 'node1.bundlr.network',
      port: '443',
      nativeProtocols: [Object],
      pathname: '/tx/solana'
    },
    _ended: false,
    _ending: true,
    _redirectCount: 0,
    _redirects: [],
    _requestBodyLength: 7267,
    _requestBodyBuffers: [ [Object] ],
    _onNativeResponse: [Function (anonymous)],
    _currentRequest: ClientRequest {
      _events: [Object: null prototype],
      _eventsCount: 7,
      _maxListeners: undefined,
      outputData: [],
      outputSize: 0,
      writable: true,
      destroyed: false,
      _last: true,
      chunkedEncoding: false,
      shouldKeepAlive: false,
      maxRequestsOnConnectionReached: false,
      _defaultKeepAlive: true,
      useChunkedEncodingByDefault: true,
      sendDate: false,
      _removedConnection: false,
      _removedContLen: false,
      _removedTE: false,
      _contentLength: null,
      _hasBody: true,
      _trailer: '',
      finished: false,
      _headerSent: true,
      _closed: false,
      socket: [TLSSocket],
      _header: 'POST /tx/solana HTTP/1.1\r\n' +
        'Accept: application/json, text/plain, */*\r\n' +
        'Content-Type: application/octet-stream\r\n' +
        'User-Agent: axios/0.25.0\r\n' +
        'Content-Length: 7267\r\n' +
        'Host: node1.bundlr.network\r\n' +
        'Connection: close\r\n' +
        '\r\n',
      _keepAliveTimeout: 0,
      _onPendingData: [Function: nop],
      agent: [Agent],
      socketPath: undefined,
      method: 'POST',
      maxHeaderSize: undefined,
      insecureHTTPParser: undefined,
      path: '/tx/solana',
      _ended: false,
      res: null,
      aborted: false,
      timeoutCb: null,
      upgradeOrConnect: false,
      parser: null,
      maxHeadersCount: null,
      reusedSocket: false,
      host: 'node1.bundlr.network',
      protocol: 'https:',
      _redirectable: [Circular *1],
      [Symbol(kCapture)]: false,
      [Symbol(kNeedDrain)]: false,
      [Symbol(corked)]: 0,
      [Symbol(kOutHeaders)]: [Object: null prototype]
    },
    _currentUrl: 'https://node1.bundlr.network:443/tx/solana',
    _timeout: null,
    [Symbol(kCapture)]: false
  },
  response: undefined,
  isAxiosError: true,
  toJSON: [Function: toJSON]
}
upload was not successful, please re-run. Error: connect ETIMEDOUT 172.67.72.157:443
    at TCPConnectWrap.afterConnect [as oncomplete] (node:net:1187:16) {
  errno: -4039,
  code: 'ETIMEDOUT',
  syscall: 'connect',
  address: '172.67.72.157',
  port: 443,
  config: {
    transitional: {
      silentJSONParsing: true,
      forcedJSONParsing: true,
      clarifyTimeoutError: false
    },
    adapter: [Function: httpAdapter],
    transformRequest: [ [Function: transformRequest] ],
    transformResponse: [ [Function: transformResponse] ],
    timeout: 60000,
    xsrfCookieName: 'XSRF-TOKEN',
    xsrfHeaderName: 'X-XSRF-TOKEN',
    maxContentLength: 536870912,
    maxBodyLength: Infinity,
    validateStatus: [Function: validateStatus],
    headers: {
      Accept: 'application/json, text/plain, */*',
      'Content-Type': 'application/octet-stream',
      'User-Agent': 'axios/0.25.0',
      'Content-Length': 7267
    },
    baseURL: 'https://node1.bundlr.network:443',
    method: 'post',
    url: 'https://node1.bundlr.network:443/tx/solana',
    data: <Buffer 02 00 e2 ae 36 52 fc 98 d3 d9 17 c7 7a c6 38 92 19 08 8f 62 f9 48 df bf 94 13 >
  },
  request: <ref *1> Writable {
    _writableState: WritableState {
      objectMode: false,
      highWaterMark: 16384,
      finalCalled: false,
      needDrain: false,
      ending: false,
      ended: false,
      finished: false,
      destroyed: false,
      decodeStrings: true,
      defaultEncoding: 'utf8',
      length: 0,
      writing: false,
      corked: 0,
      sync: true,
      bufferProcessing: false,
      onwrite: [Function: bound onwrite],
      writecb: null,
      writelen: 0,
      afterWriteTickInfo: null,
      buffered: [],
      bufferedIndex: 0,
      allBuffers: true,
      allNoop: true,
      pendingcb: 0,
      constructed: true,
      prefinished: false,
      errorEmitted: false,
      emitClose: true,
      autoDestroy: true,
      errored: null,
      closed: false,
      closeEmitted: false,
      [Symbol(kOnFinished)]: []
    },
    _events: [Object: null prototype] {
      response: [Function: handleResponse],
      error: [Function: handleRequestError],
      socket: [Array]
    },
    _eventsCount: 3,
    _maxListeners: undefined,
    _options: {
      maxRedirects: 21,
      maxBodyLength: Infinity,
      protocol: 'https:',
      path: '/tx/solana',
      method: 'POST',
      headers: [Object],
      agent: undefined,
      agents: [Object],
      auth: undefined,
      hostname: 'node1.bundlr.network',
      port: '443',
      nativeProtocols: [Object],
      pathname: '/tx/solana'
    },
    _ended: false,
    _ending: true,
    _redirectCount: 0,
    _redirects: [],
    _requestBodyLength: 7267,
    _requestBodyBuffers: [ [Object] ],
    _onNativeResponse: [Function (anonymous)],
    _currentRequest: ClientRequest {
      _events: [Object: null prototype],
      _eventsCount: 7,
      _maxListeners: undefined,
      outputData: [],
      outputSize: 0,
      writable: true,
      destroyed: false,
      _last: true,
      chunkedEncoding: false,
      shouldKeepAlive: false,
      maxRequestsOnConnectionReached: false,
      _defaultKeepAlive: true,
      useChunkedEncodingByDefault: true,
      sendDate: false,
      _removedConnection: false,
      _removedContLen: false,
      _removedTE: false,
      _contentLength: null,
      _hasBody: true,
      _trailer: '',
      finished: false,
      _headerSent: true,
      _closed: false,
      socket: [TLSSocket],
      _header: 'POST /tx/solana HTTP/1.1\r\n' +
        'Accept: application/json, text/plain, */*\r\n' +
        'Content-Type: application/octet-stream\r\n' +
        'User-Agent: axios/0.25.0\r\n' +
        'Content-Length: 7267\r\n' +
        'Host: node1.bundlr.network\r\n' +
        'Connection: close\r\n' +
        '\r\n',
      _keepAliveTimeout: 0,
      _onPendingData: [Function: nop],
      agent: [Agent],
      socketPath: undefined,
      method: 'POST',
      maxHeaderSize: undefined,
      insecureHTTPParser: undefined,
      path: '/tx/solana',
      _ended: false,
      res: null,
      aborted: false,
      timeoutCb: null,
      upgradeOrConnect: false,
      parser: null,
      maxHeadersCount: null,
      reusedSocket: false,
      host: 'node1.bundlr.network',
      protocol: 'https:',
      _redirectable: [Circular *1],
      [Symbol(kCapture)]: false,
      [Symbol(kNeedDrain)]: false,
      [Symbol(corked)]: 0,
      [Symbol(kOutHeaders)]: [Object: null prototype]
    },
    _currentUrl: 'https://node1.bundlr.network:443/tx/solana',
    _timeout: null,
    [Symbol(kCapture)]: false
  },
  response: undefined,
  isAxiosError: true,
  toJSON: [Function: toJSON]
}

That's a normal error which is caused because of timeout of the transaction.

Here are a few solutions:-

  • Use a custom RPC from Quicknode (Paid)

  • For a free and fast RPC, use https://ssc-dao.genesysgo.net/

  • If none of them works, just let the command run once, once it stops (and does not return true), run it again, it'll pick up from where it left:)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM