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

503 Error code, curl JSONRPC #182

Open
lorepieri8 opened this issue May 20, 2019 · 0 comments
Open

503 Error code, curl JSONRPC #182

lorepieri8 opened this issue May 20, 2019 · 0 comments
Labels
bug Something isn't working High Priority It creates bottlenecks or it's needed asap.

Comments

@lorepieri8
Copy link
Member

lorepieri8 commented May 20, 2019

Describe the bug
Error 503 when doing curl -X POST. The bug is present both in docker and in a droplet.

To Reproduce
https://github.com/AnyLedger/anyledger-wallet/blob/master/BUILD-qemu.md
-part one- networking, only points 2 and 3 are relevant here.

Expected behavior

$ curl -X POST --header "Content-Type: application/json"  --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":987}' [::1]:8545
 
{"jsonrpc":"2.0","result":"Parity-Ethereum//v2.4.5-stable-76d4064-20190408/x86_64-linux-gnu/rustc1.33.0","id":987}

Desktop (please complete the following information):

  • OS: Docker Ubuntu 18.04 and Digital Ocean Droplet.
  • Zephyr Kernel: 1.13.0
  • Zephyr SDK: 0.9.5
  • anyledger-wallet commit 43630f0

Error Log

root@lorenzoPractice:~/zephyr/samples/anyledger/anyledger-wallet# lighttpd -f misc/lighttpd.conf
2019-05-20 14:25:27: (network.c.273) warning: please use server.use-ipv6 only for hostnames, not without server.bind / empty address; your config will break if the kernel default for IPV6_V6ONLY changes 
2019-05-20 14:25:27: (log.c.217) server started 
root@lorenzoPractice:~/zephyr/samples/anyledger/anyledger-wallet# curl -X POST --header "Content-Type: application/json"  --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":987}' [::1]:8545
<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
         "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 <head>
  <title>503 - Service Not Available</title>
 </head>
 <body>
  <h1>503 - Service Not Available</h1>
 </body>
</html>

Additional context
Trying to bypass the lighttpd.conf works:

root@lorenzoPractice:~# curl -X POST --header "Content-Type: application/json"  --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":987}' 127.0.0.1:18545
{"jsonrpc":"2.0","result":"Parity-Ethereum//v2.5.0-beta-b52ac20-20190408/x86_64-linux-gnu/rustc1.33.0","id":987}

Active ports:

root@lorenzoPractice:~# netstat -tulnp
Active Internet connections (only servers)
Proto Recv-Q Send-Q Local Address           Foreign Address         State       PID/Program name    
tcp        0      0 0.0.0.0:80              0.0.0.0:*               LISTEN      26528/lighttpd      
tcp        0      0 127.0.0.1:18545         0.0.0.0:*               LISTEN      21978/parity        
tcp        0      0 127.0.0.53:53           0.0.0.0:*               LISTEN      13228/systemd-resol 
tcp        0      0 0.0.0.0:22              0.0.0.0:*               LISTEN      1131/sshd           
tcp        0      0 0.0.0.0:30303           0.0.0.0:*               LISTEN      21978/parity        
tcp        0      0 127.0.0.1:8546          0.0.0.0:*               LISTEN      21978/parity        
tcp6       0      0 :::22                   :::*                    LISTEN      1131/sshd           
tcp6       0      0 :::8545                 :::*                    LISTEN      22048/lighttpd      
udp        0      0 127.0.0.53:53           0.0.0.0:*                           13228/systemd-resol 
udp        0      0 0.0.0.0:30303           0.0.0.0:*                           21978/parity        

-It actually works on a regular mac pc:
https://stackoverflow.com/questions/55895088/curl-post-returning-error-503-in-cloud-linux-instance-while-working-on-local-ma

@lorepieri8 lorepieri8 added bug Something isn't working High Priority It creates bottlenecks or it's needed asap. labels May 20, 2019
@lorepieri8 lorepieri8 mentioned this issue Jul 18, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working High Priority It creates bottlenecks or it's needed asap.
Projects
None yet
Development

No branches or pull requests

1 participant