iT邦幫忙

0

application Load Balancing後端截取public ip?

原本的server會去記錄所有連線來源的ip record到DB
可是後來在AWS做了Elastic Load Balancing之後
發現ELB會自動建立兩筆私有ip
變成到DB端記錄的全都是ELB所搭配的這兩個ip
比方說172.xx.xx.1 ;172.xx.xx.2
這樣紀錄了ip也無法分辨是哪一個來源了 沒什麼意義
有沒有辦法解決這樣的問題?
讓db去記錄ELB端所接收到的source ip

椅恩啾 iT邦新手 5 級 ‧ 2018-05-25 15:03:55 檢舉
試著抓看看 ELB 過來的 http header裡面的 X-Real-IP
fillano iT邦超人 1 級 ‧ 2018-05-25 15:49:02 檢舉
https://docs.aws.amazon.com/elasticloadbalancing/latest/classic/x-forwarded-headers.html
圖片
  直播研討會
圖片
{{ item.channelVendor }} {{ item.webinarstarted }} |
{{ formatDate(item.duration) }}
直播中

尚未有邦友回答

立即登入回答