LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Networking
User Name
Password
Linux - Networking This forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.

Notices


Reply
  Search this Thread
Old 08-22-2007, 05:08 PM   #1
jademan83
LQ Newbie
 
Registered: May 2005
Distribution: FreeBSD 4.9-5.3, Slackware 10
Posts: 25

Rep: Reputation: 15
Slackware and virtual network interfaces...


I am running Slackware 12.0 and trying to setup virtual ethernet interfaces. I have setup 6 interfaces thus far without any problems, in the /rc.d/rc.inet1.conf file. However, the 7th, 8th, and 9th interfaces continuously fail as soon as I restart the inet1 service. I can temporarily add them with the ifconfig command, but nothing solid with the inet1 file. The error is something along the lines of "SIOCSIFFLAGS: Cannot assign requested address". I have double checked for any mis-typing in the file, and the computer is not currently connected to any internet, for any type of IP conflict situation. Is there some type of limitation on the number of interfaces or a file I have to change to have more interfaces? Any help would be appreciated.


Thanks
 
Old 08-22-2007, 08:41 PM   #2
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
From /etc/rc.d/rc.inet1:

Code:
############################
# DETERMINE INTERFACE LIST #
############################

# Compose a list of interfaces from /etc/rc.d/rc.inet1.conf (with a maximum
# of 6 interfaces, but you can easily enlarge the interface limit
# - send me a picture of such a box :-).
# If a value for IFNAME[n] is not set, we assume it is an eth'n' interface.
# This way, the new script is compatible with older rc.inet1.conf files.
# The IFNAME array will be used to determine which interfaces to bring up/down.
MAXNICS=6
So yes, by default you are limited to 6 interfaces (virtual or physical), but you can increase the "MAXNICS" variable if you need more.
 
Old 08-22-2007, 10:34 PM   #3
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
Also, I was a little confused by the mention of 'virtual' in your post. As far as I'm aware, Slackware's scripts do not have a mechanism for handling virtual interfaces (e.g. eth0:0). I put mine in rc.local.
 
Old 08-23-2007, 09:15 AM   #4
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
You can specify "IFNAME" for any of the interface configurations, which would allow you to specify a virtual interface rather than a physical one.

If left to it's own devices, the rc.inet1 script would attempt to increment ethx for each configuration, which will fail when you don't have the physical devices to back it up. But if you used something like "IFNAME[1]="eth0:1", it would force the script to use eth0:1 rather than eth1. Since ifconfig generates the virtual interfaces as soon as you assign it an IP, the script creates the virtual interface without explicit support for doing so.

A bit of a hack, and probably not officially supported, but I am guessing that is what he has done here.

Last edited by MS3FGX; 08-23-2007 at 09:18 AM.
 
Old 08-23-2007, 06:27 PM   #5
Berhanie
Senior Member
 
Registered: Dec 2003
Location: phnom penh
Distribution: Fedora
Posts: 1,625

Rep: Reputation: 165Reputation: 165
Thanks for the pointer, MS3FGX. I wasn't aware of recent changes.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Virtual Interfaces geony Linux - Networking 6 02-13-2005 11:25 AM
Virtual Interfaces linuxboy69 Linux - Networking 1 12-31-2003 03:08 PM
Virtual Interfaces da_tibmeister Linux - Networking 2 10-15-2003 09:32 AM
Virtual network interfaces that use dhcp titakker Linux - Networking 1 09-23-2003 12:10 AM
Virtual Network Interfaces pickledbeans Linux - Networking 1 07-11-2002 09:08 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Networking

All times are GMT -5. The time now is 05:17 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration