remote connect openshift mysql

再虚拟机内 rhc port-forward <app-name>php

 

此时,能够在本机 访问 127.0.0.1:8080  登录 网页, 3306链接sqllinux

 

https://unix.stackexchange.com/questions/111433/iptables-redirect-outside-requests-to-127-0-0-1sql

https://serverfault.com/questions/551361/redirect-incoming-packets-to-loopback/702685app

 

按上述将tcp




而后
http://forums.justlinux.com/showthread.php?136144-SOLVED-hosts-file-redirecting-a-outgoing-ip-address-to-localhost


sysctl -w net.ipv4.conf.eth0.route_localnet=1

sudo iptables -t nat -A PREROUTING -d 192.168.252.30 -j DNAT --to-destination 127.0.0.1ide

sudo iptables -t nat -A OUTPUT -d 192.168.252.130 -j DNAT --to-destination 127.0.0.1oop

 

发现  能够在虚拟机内  用  虚拟机的eth0 的ip 地址:8080  访问了,,但主机上仍然不行    http://192.168.252.130:8080/unix

 

尝试 code

http://www.linuxidc.com/Linux/2012-06/63520.htmserver

iptables -t nat -A PREROUTING -p tcp --dport 8080 -j DNAT --to-destination 127.0.0.1:8080

相关文章
相关标签/搜索