Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I install nginx as a reverse proxy. If I use:

proxy_pass http://127.0.0.1:81

it does not work. But if I use:

proxy_pass http://domain.com:81

it works. And I can use browser to access to http://domain.com:81 and http://ip:81

Could anyone explain for me?

share|improve this question
    
What happens if you "telnet 127.0.0.1 81"? It should give you a connected message. –  user103508 Dec 8 '11 at 9:58
    
In fact, my port I want is 8080 and this is result telnet: 127.0.0.1:8080: Name or service not known 127.0.0.1:8080: Unknown host –  KingOfDCP Dec 8 '11 at 10:19
add comment

1 Answer

No serverfault account so this is my reply. The telnet command i gave shouldn't have a colon. It should be "telnet 127.0.0.1 8080". It it doesn't work then i would guess whatever webserver you're using isn't being bound to 127.0.0.1 and/or port 8080.

share|improve this answer
    
"telnet 127.0.0.1 8080" command worked. Connected to 127.0.0.1. Escape character is '^]'. So what's the problem here. I already stuck –  KingOfDCP Dec 8 '11 at 12:08
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.