douzhan1238 2016-07-18 11:30
浏览 554

使用nginx重定向时,服务器在文件上载时返回501错误

I have a multi-server architecture i.e Server a and server b, Now I want all the URL's hit containg a perticuler keyword should always go to server a, So I added a nginx rule (if url have keyword redirect to server a)

Now every thing is working fine but file upload is returning error code 501, But the issue resolves if I make an entry for server a IP in my /etc/hosts.

Using Angular and php

  • 写回答

1条回答 默认 最新

  • duanqinbi9029 2016-07-19 07:43
    关注

    Ok So finally I found the issue. It was happening because of the options request.

    Options is a special kind of request which is used when the client wants to determine other available methods to retrieve or process a document on the Web server.

    So in my case my web server a and b have options method implemented while the server c (which is acting as a load balancer) does not resulting in 501 not implemented error

    评论

报告相同问题?