Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Networking & Security
  • Search

The new OpenRC networking script

Having problems getting connected to the internet or running a server? Wondering about securing your box? Ask here.
Post Reply
Advanced search
145 posts
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • Next
Author
Message
Etal
Veteran
Veteran
User avatar
Posts: 1932
Joined: Fri Jul 15, 2005 3:01 pm

The new OpenRC networking script

  • Quote

Post by Etal » Sat Oct 10, 2009 9:15 pm

The new OpenRC (0.5.1) got this new flag:

Code: Select all

oldnet: Install the old type of network init-scripts with a symlink net.IFACE for each interface
So apparently now, instead of the usual net.eth0, net.wlan0, etc., there is a new way to do things; however, I can not find anything about it except the 0.5 announcement and announcement of the networking change...

Is there any any actual documentation on how to migrate to and use the new network script (aside for the comments in the file)?
Top
pdw_hu
Apprentice
Apprentice
Posts: 200
Joined: Mon Jun 02, 2008 6:56 pm
Location: Budapest, Hungary

Re: The new OpenRC networking script

  • Quote

Post by pdw_hu » Sat Oct 10, 2009 9:29 pm

AM088 wrote:The new OpenRC (0.5.1) got this new flag:

Code: Select all

oldnet: Install the old type of network init-scripts with a symlink net.IFACE for each interface
So apparently now, instead of the usual net.eth0, net.wlan0, etc., there is a new way to do things; however, I can not find anything about it except the 0.5 announcement and announcement of the networking change...

Is there any any actual documentation on how to migrate to and use the new network script (aside for the comments in the file)?
Wondering myself...
Anyway the good old, wpa_supplicant -Dwext -B -c /etc/wpa_supplicant/wpa_supplicant.conf -i wlan0 + dhcpcd wlan0 works as always but it really seems this openrc update was a bit rushed without any proper info to get it working.
Why would you want to stick with anything that has "old" in it's name after an update? :D
Top
ziggysquatch
Apprentice
Apprentice
User avatar
Posts: 172
Joined: Tue Nov 16, 2004 11:54 pm
Location: /USA/Minnesota

  • Quote

Post by ziggysquatch » Sun Oct 11, 2009 12:37 am

Over at Funtoo there is some documentation on it. Not sure if it applies to Gentoo but i would think it's the same.

http://www.funtoo.org/en/funtoo/networking/
Top
rahulthewall
Veteran
Veteran
User avatar
Posts: 1264
Joined: Thu Nov 01, 2007 11:28 pm
Location: Zürich
Contact:
Contact rahulthewall
Website

  • Quote

Post by rahulthewall » Sun Oct 11, 2009 12:51 am

Follow this thread: (openRC support thread - there is some information there)

http://forums.gentoo.org/viewtopic-t-79 ... rt-25.html
Who shall guard the guards?
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Sun Oct 11, 2009 2:51 am

In fact, it's time to have an official migration guide or something that we can read more about it officially.

The Funtoo doc is good, but we need a Gentoo guide too here :P
Top
Etal
Veteran
Veteran
User avatar
Posts: 1932
Joined: Fri Jul 15, 2005 3:01 pm

  • Quote

Post by Etal » Sun Oct 11, 2009 6:26 pm

d2_racing wrote:In fact, it's time to have an official migration guide or something that we can read more about it officially.

The Funtoo doc is good, but we need a Gentoo guide too here :P
Yeah, an official guide is really needed.

The Funtoo guide, though, is actually different from openrc - they're trying to get rid of the networking configuration "infrastructure" entirely, and just use the tools like ifconfig directly. Which actually sounds really nice, except there does not seem to be a comprehensive guide so that I could learn how to do what I want without ending up with no internet.

Here's what I currently have and what I want to keep: netplug manages which interface is used based on whether the ethernet is plugged in, wpa_supplicant manages the wireless, and the IP addresses are acquired via dhcpcd. How to start it all up manually, I have no clue.
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Sun Oct 11, 2009 9:14 pm

In fact, I have no clue too.
Roy wrote: But what about the other DHCP clients - I want to use dhclient with ifplugd/wpa_supplicant. You have two options here - keep on using the exiting network modules or script ifplugd/wpa_supplicant yourself. Or use something else like NetworkManager.
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Sun Oct 11, 2009 9:24 pm

Maybe if you use the use flag that disable the new stuff from OpenRc, then maybe you will be able to run like you are used to do.

If you find something, just post here :P
Top
Etal
Veteran
Veteran
User avatar
Posts: 1932
Joined: Fri Jul 15, 2005 3:01 pm

  • Quote

Post by Etal » Sun Oct 11, 2009 10:27 pm

d2_racing wrote:Maybe if you use the use flag that disable the new stuff from OpenRc, then maybe you will be able to run like you are used to do.

If you find something, just post here :P
I am running with oldnet, so it is working fine. The reason I'm posting here is because I want to learn a new way :D

I guess I'll have to wait until I have a few days of free time and read some docs on how all the components fit together. Can't do it now because losing the Internet connection would be a big no-no for me. :(
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Mon Oct 12, 2009 2:02 pm

In fact, testing some network stuff can be pretty hard if you actually crash your internet connection.
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Mon Oct 12, 2009 9:07 pm

Until the release of an official guide, I will mask the 0.5 version or at least I will use new the use flag that remove all the new stuff.
Last edited by d2_racing on Tue Oct 13, 2009 1:26 am, edited 1 time in total.
Top
rahulthewall
Veteran
Veteran
User avatar
Posts: 1264
Joined: Thu Nov 01, 2007 11:28 pm
Location: Zürich
Contact:
Contact rahulthewall
Website

  • Quote

Post by rahulthewall » Mon Oct 12, 2009 9:57 pm

d2_racing wrote:... at least I will use new the use flag that remove all the new stuff.
What does that mean?
Who shall guard the guards?
Top
Evileye
l33t
l33t
User avatar
Posts: 782
Joined: Wed Aug 06, 2003 9:09 pm
Location: Toronto

  • Quote

Post by Evileye » Mon Oct 12, 2009 10:39 pm

d2_racing wrote:Until the release of an official guide, I will mask the 0.5 version or...
What if we already installed 0.5.1?

I installed it yesterday, THEN read about all this stuff. I am afraid to reboot my system fearing my network/internet will no longer work.

Do you have a general idea about when an official guide will be released? I would like to learn the new way of doing things too.

Update: I see openrc has the "oldnet" useflag set, does this mean my net.ethx will work and I can reboot without any problems?
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Tue Oct 13, 2009 1:26 am

EvilEye wrote:Update: I see openrc has the "oldnet" useflag set, does this mean my net.ethx will work and I can reboot without any problems?
As far as I know, yes.
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Tue Oct 13, 2009 1:27 am

rahulthewall wrote:
d2_racing wrote:... at least I will use new the use flag that remove all the new stuff.
What does that mean?
I mean the new use flag oldnet

Code: Select all

# quse -D oldnet
local:oldnet:sys-apps/openrc: Install the old type of network init-scripts with a symlink net.IFACE for each interface
Top
huckabuck
Tux's lil' helper
Tux's lil' helper
User avatar
Posts: 110
Joined: Sat Apr 14, 2007 11:59 am
Location: Bronx, NY

  • Quote

Post by huckabuck » Tue Oct 13, 2009 1:35 am

I have openrc 0.5.1 installed now for a few days, and oldnet useflag was set by default profile. Reboot has not been a problem.
Top
sylware
Apprentice
Apprentice
User avatar
Posts: 159
Joined: Sat Oct 16, 2004 2:16 pm
Location: European Union (Paris / France)

bloody hell!

  • Quote

Post by sylware » Tue Oct 13, 2009 4:07 pm

Come on, drop ifconfig support for good in the new openrc!
What is this mess with bsd kernel tools and linux kernel tools?? Have specific scripts for each kernel, bloody hell!
Top
UberLord
Retired Dev
Retired Dev
User avatar
Posts: 6838
Joined: Thu Sep 18, 2003 10:26 am
Location: Blighty
Contact:
Contact UberLord
Website

Re: bloody hell!

  • Quote

Post by UberLord » Tue Oct 13, 2009 4:15 pm

sylware wrote:Come on, drop ifconfig support for good in the new openrc!
iproute2 only exists in Linux, so no.
What is this mess with bsd kernel tools and linux kernel tools?? Have specific scripts for each kernel, bloody hell!
Again no, scripts should be portable across kernels and tools where possible.
I see no benefit in ignoring ifconfig for this :)
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
sylware
Apprentice
Apprentice
User avatar
Posts: 159
Joined: Sat Oct 16, 2004 2:16 pm
Location: European Union (Paris / France)

Re: bloody hell!

  • Quote

Post by sylware » Tue Oct 13, 2009 4:59 pm

UberLord wrote:
sylware wrote:Come on, drop ifconfig support for good in the new openrc!
iproute2 only exists in Linux, so no.
I forgot to add for the Linux kernel.
UberLord wrote:
What is this mess with bsd kernel tools and linux kernel tools?? Have specific scripts for each kernel, bloody hell!
Again no, scripts should be portable across kernels and tools where possible.
I see no benefit in ignoring ifconfig for this :)
I do not agree, I think that anything which is too intimate with a kernel should have specific code and scripts (and I see BSD code as a threat so it does not help). Moreover bsd ifconfig is different from linux ifconfig (which has been meant to be replaced by iproute2 for years), that's why you have many switches in the script to handle the 2 ifconfig differently.

Well Roy Marple choices are different and I don't have time to allocate in order to maintain a lean and clean GPL linux version of openrc, then I shut up and sharpen my anger silentely.

What's up with initng and upstart for gentoo?
Top
sera
Retired Dev
Retired Dev
Posts: 1017
Joined: Fri Feb 29, 2008 3:03 pm
Location: CET

Re: bloody hell!

  • Quote

Post by sera » Tue Oct 13, 2009 5:32 pm

UberLord wrote: Again no, scripts should be portable across kernels and tools where possible.
I see no benefit in ignoring ifconfig for this :)
Across kernels I agree, if Gentoo want's pure linux init scripts it can provide them itself. But across tools is exactly the old net.lo approach. So I was wondering myself why the current script "network" doesn't come as three different scripts. As net.loopback, net.ifconfig, net.iproute2 for example. This would also allow neater configuration files I guess.
Top
pappy_mcfae
Watchman
Watchman
User avatar
Posts: 5999
Joined: Thu Dec 27, 2007 10:51 pm
Location: Pomona, California.
Contact:
Contact pappy_mcfae
Website

  • Quote

Post by pappy_mcfae » Thu Oct 15, 2009 5:48 am

I tried the new setup. It works quietly, and quite well. My only question/suggestion is perhaps the next version might be intuitive enough to not change things back once you get the new script setup. This change might inspire me to put baselayout-2/openrc on another of my machines.

Blessed be!
Pappy
This space left intentionally blank, except for these ASCII symbols.
Top
pappy_mcfae
Watchman
Watchman
User avatar
Posts: 5999
Joined: Thu Dec 27, 2007 10:51 pm
Location: Pomona, California.
Contact:
Contact pappy_mcfae
Website

  • Quote

Post by pappy_mcfae » Thu Oct 15, 2009 6:08 am

Sheepish head slap! I suppose using -oldnet is a good way to get that done. Who needs intuitive? hehehe

Good work on this one. I have it set up properly now. Love it!

Blessed be!
Pappy
This space left intentionally blank, except for these ASCII symbols.
Top
d2_racing
Bodhisattva
Bodhisattva
User avatar
Posts: 13047
Joined: Mon Apr 25, 2005 2:25 pm
Location: Ste-Foy,Canada
Contact:
Contact d2_racing
Website

  • Quote

Post by d2_racing » Thu Oct 15, 2009 11:44 am

So right now, do you have a working lan card and what about your Wifi card ?

Can you tell us more about your experiment ?
Top
sera
Retired Dev
Retired Dev
Posts: 1017
Joined: Fri Feb 29, 2008 3:03 pm
Location: CET

  • Quote

Post by sera » Thu Oct 15, 2009 12:14 pm

d2_racing wrote:So right now, do you have a working lan card and what about your Wifi card ?

Can you tell us more about your experiment ?
For the wlan card.

Build the wpa_supplicant init script as described in post: [post=6008568]6008568[/post].
Add it to the boot or default runlevel.
Put something like:

Code: Select all

wpa_supplicant_conf="/etc/wpa_supplicant/wpa_supplicant.conf"
wpa_supplicant_if="wlan0"
into /etc/conf.d/wpa_supplicant.
Done.

If it does not exactly what you want edit the init script.
Top
gerard27
Advocate
Advocate
Posts: 2377
Joined: Sun Jan 04, 2004 3:30 pm
Location: Netherlands

  • Quote

Post by gerard27 » Thu Oct 15, 2009 1:15 pm

I use a wired connection to the internet (net.eth0).
Reading this thread I got scared because I updated openrc to 5.1-r1.
I checked /etc/conf.s/net and it had oct 15th datestamp.
The emerge had copied the contents of my previous file into it!
The same happened to /etc/conf.d/network.
I've rebooted and no problems.
Gerard.
To install Gentoo I use sysrescuecd.Based on Gentoo,has firefox to browse Gentoo docs and mc to browse (and edit) files.
The same disk can be used for 32 and 64 bit installs.
You can follow the Handbook verbatim.
http://www.sysresccd.org/Download
Top
Post Reply

145 posts
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • Next

Return to “Networking & Security”

Jump to
  • Assistance
  • ↳   News & Announcements
  • ↳   Frequently Asked Questions
  • ↳   Installing Gentoo
  • ↳   Multimedia
  • ↳   Desktop Environments
  • ↳   Networking & Security
  • ↳   Kernel & Hardware
  • ↳   Portage & Programming
  • ↳   Gamers & Players
  • ↳   Other Things Gentoo
  • ↳   Unsupported Software
  • Discussion & Documentation
  • ↳   Documentation, Tips & Tricks
  • ↳   Gentoo Chat
  • ↳   Gentoo Forums Feedback
  • ↳   Duplicate Threads
  • International Gentoo Users
  • ↳   中文 (Chinese)
  • ↳   Dutch
  • ↳   Finnish
  • ↳   French
  • ↳   Deutsches Forum (German)
  • ↳   Diskussionsforum
  • ↳   Deutsche Dokumentation
  • ↳   Greek
  • ↳   Forum italiano (Italian)
  • ↳   Forum di discussione italiano
  • ↳   Risorse italiane (documentazione e tools)
  • ↳   Polskie forum (Polish)
  • ↳   Instalacja i sprzęt
  • ↳   Polish OTW
  • ↳   Portuguese
  • ↳   Documentação, Ferramentas e Dicas
  • ↳   Russian
  • ↳   Scandinavian
  • ↳   Spanish
  • ↳   Other Languages
  • Architectures & Platforms
  • ↳   Gentoo on ARM
  • ↳   Gentoo on PPC
  • ↳   Gentoo on Sparc
  • ↳   Gentoo on Alternative Architectures
  • ↳   Gentoo on AMD64
  • ↳   Gentoo for Mac OS X (Portage for Mac OS X)
  • Board index
  • All times are UTC
  • Delete cookies

© 2001–2026 Gentoo Foundation, Inc.

Powered by phpBB® Forum Software © phpBB Limited

Privacy Policy

 

 

magic