Home | Gallery | Forum | Services | Webmail | Archive | Links | Contact Us | About Us
OS2 World.Com Forum
OS2 World.Com Online Discussion Forum.
Index / OS/2 - General / Networking
author message
2 IP Addresses on the Same Network Card
Post a new topic Reply to this Topic Printable Version of this Topic Forward this Topic to your Friend Topic Commands (for administrator or moderators only)
klcant
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this member
posts: 4
since: 28 Apr, 2005
1. 2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message
Hopefully this is not TOO noobish of a question ... but ... can I add 2 IP addresses to the same network card?

Thanks,

KC

Date: 28 Apr, 2005 on 15:17
hausmaus
Premium member
in user

View this member's profileSearch all posts from this memberSend an email to this memberhttp://outpostbbs.net
posts: 87
since: 11 Aug, 2004
2. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message

klcant (28 Apr, 2005 15:17):
Hopefully this is not TOO noobish of a question ... but ... can I add 2 IP addresses to the same network card?

Thanks,

KC


Not that I know of.

--Sean

Date: 28 Apr, 2005 on 18:41
klcant
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this member
posts: 4
since: 28 Apr, 2005
3. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message
I found this ... can anyone tell me if this is correct?

Edit \mptn\bin\setup.cmd and add a second ifconfig line for the
interface...

Unlike the first one, this has to have the keyword 'alias' after the
interface name. See the TCP/IP command reference for more details.

Thanks!

Date: 28 Apr, 2005 on 19:56
Fudeba
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this memberhttp://www.caetano.eng.br/
posts: 35
since: 31 Oct, 2003
4. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message
Yes, it is correct. I used the ALIAS keyword many times when I was using only one NIC at my server, doing some black magic to it could see the Internet and the computers (all connected to the same hub) but the computers could not see the internet nor the internet see them.
It works like a charm.
Date: 28 Apr, 2005 on 20:31
klcant
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this member
posts: 4
since: 28 Apr, 2005
5. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message
Please excuse my ignorance ... I have not played with O/S2 much. Does this syntex look correct?

"C:\mptn\bin\setup.cmd"
route -fh
arp -f
ifconfig lan0 192.xxx.xx.xxx netmask 255.255.255.000
ifconfig lan0 alias 10.xxx.xx.xxx netmask 255.255.000.000
rem ifconfig lan1
rem ifconfig lan2
rem ifconfig lan3
etc ...

Thanks again!

Date: 28 Apr, 2005 on 21:04
FrMike
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this memberhttp://frmike.com
posts: 12
since: 17 Aug, 2003
6. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message

klcant (28 Apr, 2005 21:04):
Please excuse my ignorance ... I have not played with O/S2 much. Does this syntex look correct?
...

ifconfig lan0 alias 10.xxx.xx.xxx netmask 255.255.000.000
...


Yup. You can also take advantage of a nifty feature of OS/2's implementation of TCP/IP: you can issue this command at any command prompt. For example, you can add an alias IP and later drop it. As far as that goes, you can change IP addresses on the fly, and/or switch into or out of dynamic-IP mode with DHCP. Linux also has this capability, but its syntax of the commands is somewhat different.

In Windoze, if you want to change your IP settings, you have to reboot before they take effect. (Funny, you do a lot of rebooting in Windoze!)


Also, when you are specifying the octets of an IP address or a netmask, you don't have to pad things to three digits. Therefore, 255.255.0.0 would do fine in your example.

Date: 29 Apr, 2005 on 03:51
klcant
Normal member
in user

View this member's profileSearch all posts from this memberSend an email to this member
posts: 4
since: 28 Apr, 2005
7. Re:2 IP Addresses on the Same Network Card
Reply to this topic with quote Modify your message
Very cool ... thanks all! And thanks FrMike ... I am going to give the command prompt a try!!
Date: 29 Apr, 2005 on 16:18
2 IP Addresses on the Same Network Card
Post a new topic Reply to this Topic Printable Version of this Topic Forward this Topic to your Friend Topic Commands (for administrator or moderators only)
All times are CET+1. < Prev. | P. 1 | Next >
Go to:
 

Powered by UltraBoard 2000 Standard Edition,
Copyright © UltraScripts.com, Inc. 1999-2000.
Home | Gallery | Forums | Services | Webmail | Archive | Links | Contact Us | About Us
OS2 World.Com 2000-2004