LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 08-21-2012, 12:00 PM   #1
yenn
Member
 
Registered: Jan 2011
Location: Czech Republic
Distribution: Slackware, Gentoo
Posts: 155

Rep: Reputation: 21
Slackware network scripts inside OpenVZ container


I'm trying to run Slackware inside OpenVZ container with bridged network. The network itself works, but only if I set it manually, which means I have to start VM and then enable networking inside VM every (re)start. Apparently Slackware rc.inet1 script(s) arent't executed, which is strange because Debian init scripts works without a glitch.

Anyone encountered this issue?
 
Old 08-21-2012, 12:58 PM   #2
Didier Spaier
Senior Member
 
Registered: Nov 2008
Location: Paris, France
Distribution: Slackware{,64}-{14.1,current} on a Lenovo Thinkpad T61 6457-4XG
Posts: 4,381

Rep: Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088Reputation: 1088
Simplest things first. Did you check that /etc/rc.d/rc.inet1 be executable?
 
Old 08-21-2012, 04:19 PM   #3
yenn
Member
 
Registered: Jan 2011
Location: Czech Republic
Distribution: Slackware, Gentoo
Posts: 155

Original Poster
Rep: Reputation: 21
Yes, rc.inet1 is executable and it is actually executed during boot.

After hour or so fiddling with init scripts I figured out that problem is somewhere else. There are two network interfaces (besides loopback) - venet0 (NAT) and eth0 (bind to bridge) - and rc.inet1 recognize first network interface (venet0) as eth0, therefore assign IP address to this interface. I'm curious why because of the comment in /etc/rc.d/rc.inet1.conf
Code:
# If IFNAME[interface] is unset or empty, it is assumed you're configuring eth<interface>.
And /etc/rc.d/rc.inet1
Code:
. /etc/rc.d/rc.inet1.conf

MAXNICS=${MAXNICS:-6}

i=0
while [ $i -lt $MAXNICS ];
do
  IFNAME[$i]=${IFNAME[$i]:=eth${i}}
  i=$(($i+1))
done
However, workaround is simple:
Code:
# /etc/rc.d/rc.inet1.conf
# prepend this to NIC definition
IFNAME[0]="eth0"

IPADDR[0]="a.a.a.a"
NETMASK[0]="n.n.n.n"
And by the way, if anyone is interested, Slackware 13.37 minimal template for OpenVZ isn't very good. Missing wget, slackpkg and messed routes in /etc/rc.d/rc.inet1 take some time to get working minimal system. If you want to run Slackware inside OpenVZ, create your own template.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
Can not connect to OpenVZ container sometimes CentOS hostnode sokha Linux - Virtualization and Cloud 0 11-30-2010 08:08 PM
QEMU / DosEMU inside OpenVZ container kirtimaan_bkn Linux - Virtualization and Cloud 2 11-09-2010 09:59 PM
OpenVZ Container Backup vzxen Linux - Virtualization and Cloud 5 09-22-2010 12:53 AM
Reinstall OpenVZ Container OS vzxen Linux - Virtualization and Cloud 0 07-21-2010 01:23 PM
PPTPclient in openVZ container laurens Linux - Newbie 0 03-24-2009 09:32 AM


All times are GMT -5. The time now is 11:34 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration