Solved

Two IP addresses on the same VLAN but different virtual interface

Posted on 2006-07-07
6
808 Views
Last Modified: 2013-12-06
Dear Sir,

I have a Red Hat Linux Enterprise 3 ES OS, I have a virtual interface that is vlan tagged, but I need to add another vlan tagged interface on the same vlan,
but I get a conflict when I add for example another ifcfg-eth0.43 with different ip addresses.

For now I have one eth1 :

DEVICE=eth1
BOOTPROTO=static
BROADCAST=10.0.0.3
IPADDR=10.0.0.1
NETMASK=255.255.255.252
NETWORK=10.0.0.0
ONBOOT=yes
TYPE=Ethernet

eth0 and eth0.43

DEVICE=eth0
BOOTPROTO=static
BROADCAST=0.0.0.0
IPADDR=0.0.0.0
NETMASK=0.0.0.0
NETWORK=0.0.0.0
ONBOOT=yes
TYPE=Ethernet

DEVICE=eth0.43
BOOTPROTO=static
BROADCAST=213.xxx.xxx.63
IPADDR=213.xxx.xxx.60
NETMASK=255.255.255.192
NETWORK=213.xxx.xxx.0
VLAN=yes
ONBOOT=yes
TYPE=Ethernet

And I need an extra eth0.43 with a different ip address.

Sincerely

Uday MOOORAJNI



0
Comment
Question by:umoorjani
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 2
6 Comments
 
LVL 22

Expert Comment

by:pjedmond
ID: 17061018
>I need to add another vlan tagged interface on the same vlan,

Why??????

>but I get a conflict when I add for example another ifcfg-eth0.43 with different ip addresses.

That's exactly what should happen! You cannot have 2 eth0.43s (on the same system)! Each interface has to be unique. What's wrong with eth0.44 or indeed any other number combination!

(   (()
(`-' _\
 ''  ''
0
 

Author Comment

by:umoorjani
ID: 17062324
Well won't it tag ifcfg-eth44 into a vlan ID=44 ?? AHHHHHHHHHHHHHH!

vconfig add eth1.44 43 ??

I need to to have two IP addresse on the same VLAN, mainly for the clusering reasons. I'm just small technician
I follow orders. I just want to know a workaround for this knowing that our network is vlan tagged and i have only
two interfaces, wherer one interface on each server is crossed with each other. so I have to deal with one interface.
0
 
LVL 22

Expert Comment

by:pjedmond
ID: 17062520
>Well won't it tag ifcfg-eth44 into a vlan ID=44 ?? AHHHHHHHHHHHHHH!

I suppose it would - but why is that a problem? What decides whether the 2 ips can 'communicate' is the ip address, the net mask and the routing/bridging. Their vlan 'ID' is not important other than as identification for relating the various properties and routing rules to.

eth1.43   - 10.0.0.1 netmask 255.255.255.0
eth1.44   - 10.0.0.2 netmask 255.255.255.0

can quite happily communicate with each other. Worthwhile making sure that you change the hw MAC address for each of your virtual ethernet connections ifconfig eth1.43 hw ether 00:11:22:33:44:55 etc to ensure that if they are on the same network, they do not get confused.

vconfig add eth1.44 43 ??

I guess this 'might work', but why have a virtual ethernet interface on a virtual interface. This gives 2 levels of interface to pass traffic through (even if it does work!) rather than one. Gonsidering that a 1 GHz interface requires approx 1GHz of processing power to work flat out, then this concept has severe performance penalty issues (even if you do get it to work!) Don't do it - you don't need to.

I think that you are misunderstanding what a virtual interface/vlan is, and think that it may be worth reading the following:

http://www.linuxhorizon.ro/vlans.html
http://www.cyberciti.biz/tips/howto-configure-linux-virtual-local-area-network-vlan.html

Effectively, you are just making a single ethernet behave like multiple ethernet connections.

(   (()
(`-' _\
 ''  ''
0
Containers & Docker to Create a Powerful Team

Containers are an incredibly powerful technology that can provide you and/or your engineering team with huge productivity gains. Using containers, you can deploy, back up, replicate, and move apps and their dependencies quickly and easily.

 
LVL 22

Expert Comment

by:pjedmond
ID: 17062541
Incidentally, eth1 (which is 'hosting' the virtual ethernet adaptors) is effectively in promiscuous mode - i.e. it receives all traffic that is transmitted to it, and then translates anything as necessary for it's virtual adaptors. Hence all the 0.0.0.0s

(   (()
(`-' _\
 ''  ''
0
 

Author Comment

by:umoorjani
ID: 17062560
I have a catalyst switch that is switch port access vlan 43 and other vlans trunked as well on the switch.
It's not like I have a /24, I have a /26, the vlan in particular is on a "Looking Glass" Carrier-Grade Voice Backbone.

anyway, I'll look through the papers you've given me.
0
 
LVL 22

Accepted Solution

by:
pjedmond earned 500 total points
ID: 17062677
OK - I understand - You are getting confused between a Cisco VLAN, and a Linux virtual ethernet interface.

http://www.cisco.com/univercd/cc/td/doc/product/lan/28201900/1928v8x/eescg8x/02vlans.htm

should help you understand the difference (in conjuction with the previous docs)

(   (()
(`-' _\
 ''  ''

0

Featured Post

NFR key for Veeam Agent for Linux

Veeam is happy to provide a free NFR license for one year.  It allows for the non‑production use and valid for five workstations and two servers. Veeam Agent for Linux is a simple backup tool for your Linux installations, both on‑premises and in the public cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

How to update Firmware and Bios in Dell Equalogic PS6000 Arrays and Hard Disks firmware update.
In this article we will learn how to backup a VMware farm using Nakivo Backup & Replication. In this tutorial we will install the software on a Windows 2012 R2 Server.
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

630 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question