Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR OCCURED #9

Open
bassjobsen opened this issue Jul 5, 2018 · 5 comments
Open

ERROR OCCURED #9

bassjobsen opened this issue Jul 5, 2018 · 5 comments
Assignees

Comments

@bassjobsen
Copy link
Contributor

[2018-07-05 15:37:789][INFO] check balance...
[2018-07-05 15:37:498][ERROR] ERROR OCCURED
[2018-07-05 15:37:501][ERROR] Request failed with status code 500
[2018-07-05 15:37:509][ERROR] Error: Request failed with status code 500
at createError (/home/bass/testomgeving/asch-redeploy/node_modules/axios/lib/core/createError.js:16:15)
at settle (/home/bass/testomgeving/asch-redeploy/node_modules/axios/lib/core/settle.js:18:12)
at IncomingMessage.handleStreamEnd (/home/bass/testomgeving/asch-redeploy/node_modules/axios/lib/adapters/http.js:201:11)
at emitNone (events.js:111:20)
at IncomingMessage.emit (events.js:208:7)
at endReadableNT (_stream_readable.js:1064:12)
at _combinedTickCallback (internal/process/next_tick.js:138:11)
at process._tickCallback (internal/process/next_tick.js:180:9)
[2018-07-05 15:37:512][INFO] SIGINT send

@a1300
Copy link
Contributor

a1300 commented Jul 6, 2018

Hi @bassjobsen
Could you please paste the last 50 lines of the two log files:

  • your Dapp/logs/asch-node-2018-07-05.log and
  • your Dapp/logs/asch-redeploy-2018-07-06.log

@a1300 a1300 self-assigned this Jul 8, 2018
@bassjobsen
Copy link
Contributor Author

possible related errors:

[2018-07-26 13:23:489][INFO] starting asch-node in "/home/bass/testomgeving/asch" on port 4096
[2018-07-26 13:23:616][ERROR] ERROR OCCURED
[2018-07-26 13:23:618][ERROR] connect ECONNREFUSED 127.0.0.1:4096
[2018-07-26 13:23:618][ERROR] Error: connect ECONNREFUSED 127.0.0.1:4096
    at Object._errnoException (util.js:1022:11)
    at _exceptionWithHostPort (util.js:1044:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1198:14)

Now i wonder if these errors are related to some processes which don't stop after stopping ASCH:

ps -aux | grep node
bass     14606  0.0  0.2 1093800 20944 pts/0   Sl   01:10   0:01 node /home/bass/testomgeving/asch/node_modules/asch-sandbox/shovel2.js dapps/8a1e9ee1736163dd1659fdc01811a0dfea8a0ac7dec901025ea8389baa4aab41 sentence weasel match weather apple onion release keen lens deal fruit matrix
bass     14636  0.0  0.2 1093816 20996 pts/0   Sl   01:10   0:01 node /home/bass/testomgeving/asch/node_modules/asch-sandbox/shovel2.js dapps/b0f7a64d5b30d36e1781faab0869bf77bb3b4396bbb307c8155a1f3bbb43dc9b sentence weasel match weather apple onion release keen lens deal fruit matrix
bass     14991  0.0  0.3 1093816 22532 pts/0   Sl   01:11   0:01 node /home/bass/testomgeving/asch/node_modules/asch-sandbox/shovel2.js dapps/8a1e9ee1736163dd1659fdc01811a0dfea8a0ac7dec901025ea8389baa4aab41 sentence weasel match weather apple onion release keen lens deal fruit matrix
bass     15026  0.0  0.3 1093816 21752 pts/0   Sl   01:11   0:01 node /home/bass/testomgeving/asch/node_modules/asch-sandbox/shovel2.js dapps/b0f7a64d5b30d36e1781faab0869bf77bb3b4396bbb307c8155a1f3bbb43dc9b sentence weasel match weather apple onion release keen lens deal fruit matrix
bass     30175  0.0  0.0    540     4 pts/2    D+   15:56   0:00 grep --color=auto node

Notice that the above also shows my master secret?!

@a1300
Copy link
Contributor

a1300 commented Jul 26, 2018

@bassjobsen normally asch-redeploy can't be started if something is already running on port 4096

Do you have something running on port 4096? Maybe asch-redeploy didn't shut down correctly...

@bassjobsen
Copy link
Contributor Author

i'll check the ports next time the situation occurs

@a1300
Copy link
Contributor

a1300 commented Jul 31, 2018

In the next version there will be axios logging for better BUG reporting. In the logs/asch-redeploy-*.log file you can find all axios requests and responses from the server.

I think I know what caused the bug:

  • `asch-redeploy``waits a fixed time interval after the asch node gets restartetd. If the node is taking longer to start the request will result into a 500 error.

TODO

  • ASCH node restart needs to wait for the blockchain to be ready. Do not wait a fixed time interval
  • Also check if transaction has been written to the blockchain (wget http://localhost:4096/api/transactions/unconfirmed) or (wget http://localhost:4096/api/transactions/unconfirmed/get?id=e19a3ae0090208c3e2e1289d12b80511eca5ceb814d20f0cf37bd2e37942f820)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants