Le Samedi 24 Septembre 2011 15:02:59 DerekLiao a écrit : > configuration files: > > > reqrep ^([^\ ]*)\ /kaijiang([/\?\ ].*) \1\ /result_aaa\2 > reqirep ^Host: Host:\ www.bbb.com > > Logs: > srv_aaa_caipiaos_01 0/0/0/2/2 404 735 - - ---- 0/0/0/0/0 0/0 "GET > /result_aaa/ HTTP/1.1" >
I'm lost, I don't understand what you are testing. Why is your log showing /result_aaa/ if you want to test /kaijiang ? Also, you don't provide enough information at the same time: Why your server is not the same as the one you provided at the beginning : srv_aaa_caipiaos_1_01 ? I think you forgot to give other pieces of configuration. It looks like you are testing another backend configuration. Confirmed by your frontend acls if they didn't change : acl acl_dom_caipiao.aaa.com hdr_dom(host) caipiao.aaa.com acl acl_url_kaijiang path_beg -i /kaijiang use_backend cs_aaa_caipiaos_1 if acl_dom_caipiao.aaa.com acl_url_kaijiang If you ask for /result_aaa/ the condition on the last line won't match. Can you provide everything (hide the IP/host names/passwords for security reasons) ? This will save time to everybody ;-) > but i can access www.bbb.com/result_aaa/ I suppose that you missed something about the Host headers. OK, you can access to www.bbb.com/result_aaa/ But it looks like your hostname in front of haproxy is caipiao.aaa.com (or aaa.com) Are you sure the server www.bbb.com accepts your virtualhost ? You can verify it : curl -i -H "Host: caipiao.aaa.com" www.bbb.com/result_aaa/ Isn't it a 404 ? -- Cyril Bonté

