Amazon ELB的Apache 2.4 remoteip配置

Amazon ELB的Apache 2.4 remoteip配置,apache,amazon-elb,Apache,Amazon Elb,我们在Amazon ELB后面的AWS EC2实例上运行Apache web服务器 我想配置在Apache2.4和更高版本上可用的remoteip。据我所知,为此,我需要启用remoteip并修改我的/etc/apache2/mods enabled/remoteip.conf文件,如下所示: RemoteIPHeader X-Forwarded-For RemoteIPInternalProxy <ip-address> RemoteIPHeader X-Forwarded-F

我们在Amazon ELB后面的AWS EC2实例上运行Apache web服务器

我想配置在Apache2.4和更高版本上可用的remoteip。据我所知,为此,我需要启用remoteip并修改我的/etc/apache2/mods enabled/remoteip.conf文件,如下所示:

RemoteIPHeader X-Forwarded-For 
RemoteIPInternalProxy <ip-address>
RemoteIPHeader X-Forwarded-For
RemoteIPInternalProxy

这里,当我使用亚马逊ELB时,我应该使用什么来代替ip地址(因为ELB给我的是域名而不是ip地址)?

当你使用提供的域名时发生了什么?它显示了ELB的相同动态ip地址。当你使用提供的域名时发生了什么?没有任何变化,它显示了我给域名时ELB的相同动态IP地址。您编辑了/etc/apache2/mods enabled/remoteip.conf并键入了提供的域,然后保存了文件并重新启动了服务。这并没有解决问题,所以您返回并查看该文件,它已恢复为IP地址,并且没有任何更改?很明显,有些事情确实发生了变化。