LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Networking (https://www.linuxquestions.org/questions/linux-networking-3/)
-   -   setting two i.p. on same RHEL 5 machine. (https://www.linuxquestions.org/questions/linux-networking-3/setting-two-i-p-on-same-rhel-5-machine-617370/)

rushadrenaline 01-30-2008 04:45 AM

setting two i.p. on same RHEL 5 machine.
 
ok i have this rhel 5 server in our lan . Its ip is 192.168.4.20. We just bought a static ip. Now i want my rhel server to have both the i.p.. So that my branch at Malaysia can download the code via static i.p., while keeping previous i.p.also for my local network. Can any body tell me how to do it. Any nice links would be really helpful.
Thanx in advance

acid_kewpie 01-30-2008 05:18 AM

can you define your network topology? you would not want to have a public and private IP on the same NIC, so i would say there's going to be a better solution to what you actually want to do. normally the IP would be held on your firewall and statically natted through.

rushadrenaline 01-30-2008 07:02 AM

i created eth0:0 and gave it the static i.p. the one i bought (suppose 167.89.45.6)
while eth0 is 192.168.4.20.
I can ping eth0:0 from lan machines,,but cant ssh or do svn checkout,,it says connection refused on port 22. Slinux and firewall is already disabled. But still ???

So people in my lan will access the rhel5 server for svn checkout as svn co svn://192.168.4.20/file
while people from outside will do svn co svn://167.89.45.6/file.

There are only 20 comps in our network.

lsteacke 01-30-2008 08:25 AM

Maybe you've already thought of this and disregarded it for topology reasons, but would adding another NIC to the server makes things more simple for you? Then just assign each NIC their respective IPs?

acid_kewpie 01-30-2008 08:38 AM

no no, you don't want another nic... as above, please actually define your topology... how does the internet connect to this network etc..?

rushadrenaline 01-30-2008 08:58 AM

the main internet connection connects to a switch. The server and other machines also connect to internet trough this switch. So the server is no different from other machines, in term of internet connection. The only diference is that the serv er has 2 nics,,while other pcs have only one

acid_kewpie 01-30-2008 10:04 AM

you must have a firewall right? the internet itself won't just connect directly onto a switch...


All times are GMT -5. The time now is 02:24 AM.