Forums

Skip to content

Advanced search
  • Quick links
    • Unanswered topics
    • Active topics
    • Search
  • FAQ
  • Login
  • Register
  • Board index Assistance Other Things Gentoo
  • Search

openrc support thread

Still need help with Gentoo, and your question doesn't fit in the above forums? Here is your last bastion of hope.
Locked
Advanced search
820 posts
  • Page 6 of 33
    • Jump to page:
  • Previous
  • 1
  • …
  • 4
  • 5
  • 6
  • 7
  • 8
  • …
  • 33
  • Next
Author
Message
slackline
Veteran
Veteran
User avatar
Posts: 1479
Joined: Fri Apr 01, 2005 7:22 pm
Location: /uk/sheffield
Contact:
Contact slackline
Website

Post by slackline » Mon Apr 21, 2008 11:43 am

drizzt wrote:@slack---line:
Have you tried to change the "strict" variable I mentioned some posts ago ? This one helped me with the similar problem of net.eth0 / net.eth1.
:oops: Cheers for that drizzt, I'd missed your posts and like yourself not read the comments in /etc/rc.conf in sufficient detail.
"Science is what we understand well enough to explain to a computer.  Art is everything else we do." - Donald Knuth
Top
zAfi
Apprentice
Apprentice
User avatar
Posts: 220
Joined: Tue Aug 08, 2006 7:49 pm
Location: Austria

Post by zAfi » Mon Apr 21, 2008 11:50 am

just upgrade to b2/openrc and it works like a charm!
There's just one thing, I get "err, no interface specified" messages all the time I start/stop/restart a net.* service, although everything works.

Code: Select all

~ $ sudo /etc/init.d/net.wlan0 restart
 * Caching service dependencies ...
err, no interface specified
err, no interface specified
err, no interface specified                                                                                                                           [ ok ]
err, no interface specified
err, no interface specified
 * Bringing down interface wlan0
 *   Stopping dhcpcd on wlan0 ...                                                                                                                     [ ok ]
 *   Stopping wpa_cli on wlan0 ...                                                                                                                    [ ok ]
 *   Stopping wpa_supplicant on wlan0 ...                                                                                                             [ ok ]
 *   Running postdown ...
err, no interface specified
 * Bringing up interface wlan0
 *   Running preup ...
 *   Starting wpa_supplicant on wlan0 ...
ioctl[SIOCSIWAUTH]: Operation not supported
WEXT auth param 4 value 0x0 - ioctl[SIOCSIWAUTH]: Operation not supported                                                                             [ ok ]
 *   Starting wpa_cli on wlan0 ...                                                                                                                    [ ok ]
 *   Backgrounding ... ...
It seems to me that dhcpcd tries to do something before it actually invokes the device, but this is only a weird idea. ;)

Here's /etc/conf.d/net, it should be alright according to the upgrade guide.

Code: Select all

config_eth0="dhcp"
dhcpcd_eth0="-t 5" #Timeout after 10 seconds
dhcp_eth0="release nontp nonis" #Only get an adress

config_wlan0="dhcp"
dhcpcd_wlan0="-t 5"
dhcp_wlan0="release nontp nonis"
# Prefer wpa_supplicant over wireless-tools
modules="wpa_supplicant" "dhcpcd"
wpa_supplicant_wlan0="-Dwext -B -qq -c/etc/wpa_supplicant/wpa_supplicant.conf"

#preup() and postdown() are needed to un-/load the wlan module!
#By simply restarting the service without reloading the module
#we won't receive an IP anymore.
preup() {
  if [ $IFACE == "wlan0" ]; then
    modprobe iwl4965 && sleep 0.5 #wait 1 second before continuing, else we fail!
  fi
}
postdown() {
  if [ $IFACE == "wlan0" ]; then
    modprobe -r iwl4965
  fi
}
I already reemerged dhcpcd and openresolv but to no avail. :?: Any ideas :?:
Gentoo 2008.0/desktop | Kernel: 2.6.27-tuxonice | Arch: amd64 | KDE 3.5.9 | WU Wien |
----------
Share your kernel information @ http://klive.cpushare.com/
Top
sdtester
n00b
n00b
User avatar
Posts: 29
Joined: Thu Mar 03, 2005 2:20 am
Location: 33°51’24” S, 151°12’55” E.

Post by sdtester » Tue Apr 22, 2008 1:17 am

The only problem I experienced with upgrading to b2/openrc is my dummy net interface is now not doing its job. I have the dummy interface there so that apache, named and other services will run when I don't have another internet connection. dummy0 is getting coming up with an ip address (10.0.0.2) but the other services remain inactive:
# rc-status
Runlevel: default
...
net.MainLAN [ inactive ]
net.dummy0 [ started ]
named [ scheduled ]
...
netmount [ scheduled ]
...
sshd [ scheduled ]
apache2 [ scheduled ]
slapd [ scheduled ]
samba [ scheduled ]
...

dummy is compiled into the kernel as a module.
When I execute "/etc/init.d/net.dummy0 restart" this is spewed out:
* Bringing down interface dummy0
* Stopping netplug on dummy0 ... [ ok ]
* Bringing up interface dummy0
* Starting netplug on dummy0 ... [ ok ]
* Backgrounding ...
* WARNING: net.dummy0 not under our control, aborting
Top
UberLord
Retired Dev
Retired Dev
User avatar
Posts: 6838
Joined: Thu Sep 18, 2003 10:26 am
Location: Blighty
Contact:
Contact UberLord
Website

Post by UberLord » Tue Apr 22, 2008 6:44 am

Do you have iproute2 installed?
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
sdtester
n00b
n00b
User avatar
Posts: 29
Joined: Thu Mar 03, 2005 2:20 am
Location: 33°51’24” S, 151°12’55” E.

Post by sdtester » Tue Apr 22, 2008 10:50 am

Yup, iproute is current at 2.6.24.20080108. I even made it explicit in /etc/conf.d/net (modules="iproute2")

dummy0 is not even getting a mention as being able to satisfy the 'net' dependency for services like apache. For example,

Code: Select all

# /etc/init.d/apache2 restart
 * WARNING: apache2 is scheduled to start when net.MainLAN has started
It use to be dependent on either MainLAN or dummy0 when using baselayout-1
Top
UberLord
Retired Dev
Retired Dev
User avatar
Posts: 6838
Joined: Thu Sep 18, 2003 10:26 am
Location: Blighty
Contact:
Contact UberLord
Website

Post by UberLord » Tue Apr 22, 2008 10:53 am

It's because they're both in the runlevel, so both are needed to satisfy the dep.
If only net.dummy0 is meant to satisfy the dep then remove net.MainLAN from the default runlevel or remove it's net provision like so in /etc/conf.d/net

Code: Select all

rc_net_MainLAN_provide="!net"
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
slackline
Veteran
Veteran
User avatar
Posts: 1479
Joined: Fri Apr 01, 2005 7:22 pm
Location: /uk/sheffield
Contact:
Contact slackline
Website

Post by slackline » Tue Apr 22, 2008 11:08 am

Or you could perhaps set...

Code: Select all

# Do we allow any started service in the runlevel to satisfy the depedency
# or do we want all of them regardless of state? For example, if net.eth0
# and net.eth1 are in the default runlevel then with rc_depend_strict="NO"
# both will be started, but services that depend on 'net' will work if either
# one comes up. With rc_depend_strict="YES" we would require them both to
# come up.
rc_depend_strict="NO"
...as I was advised further up the thread.
"Science is what we understand well enough to explain to a computer.  Art is everything else we do." - Donald Knuth
Top
sdtester
n00b
n00b
User avatar
Posts: 29
Joined: Thu Mar 03, 2005 2:20 am
Location: 33°51’24” S, 151°12’55” E.

Post by sdtester » Tue Apr 22, 2008 12:21 pm

Thanks Uberlord, That did the trick!
Top
elcugo
n00b
n00b
Posts: 9
Joined: Fri Mar 07, 2008 8:12 pm
Location: México
Contact:
Contact elcugo
Website

Post by elcugo » Tue Apr 22, 2008 8:34 pm

Hello, I just upgraded to b2/openrc. My system seems to boot faster, saves me 23 seconds, yay! :-)

I have problems with my net config. I had:

Code: Select all

modules=( "iproute2" )
modules=( "dhcpcd" )
config_eth0=( "dhcp" )
fallback_eth0=( "192.168.1.66/24" )
dhcpcd_eth0=( "-t 25" )
I tried just removing the "()"s but I get errors in the console. How do I migrate that config?

This is what I have right now:

Code: Select all

config_eth0= "dhcp"
fallback_eth0= "192.168.1.66/24"
But it complains about those commands not found.

Fortunatelly the script falls back to using dhcpcd anyway so I get my NIC configured.
Sign: File not found.
Top
golding
Apprentice
Apprentice
User avatar
Posts: 232
Joined: Tue Jun 07, 2005 12:20 am
Location: Adelaide / South Australia

Post by golding » Tue Apr 22, 2008 9:24 pm

Try this, has been working for me after I upgraded to bl-2 and openrc

Code: Select all

modules="iproute2"
config_eth0="dhcp 192.168.99.1/24" 
dhcp_eth0="nontp"
An example file can be found at /usr/share/doc/openrc/net.example
Regards, Robert

..... Some people can tell what time it is by looking at the sun, but I have never been able to make out the numbers.
Top
elcugo
n00b
n00b
Posts: 9
Joined: Fri Mar 07, 2008 8:12 pm
Location: México
Contact:
Contact elcugo
Website

Post by elcugo » Tue Apr 22, 2008 10:12 pm

Never mind, I just realized that I forgot to remove whitespace after the "=". Foolish me.
golding wrote:An example file can be found at /usr/share/doc/openrc/net.example
Ahh. I was looking at /etc/conf.d/net.example, which is useless. Thanks! Now my config works:

Code: Select all

config_eth0="dhcp"
fallback_eth0="192.168.10.100/24"
dhcpcd_eth0="-t 25"
No need to add modules="iproute2" and modules="dhcpcd" since they seem to be the defaults now.
Sign: File not found.
Top
crowbert
Tux's lil' helper
Tux's lil' helper
Posts: 147
Joined: Mon Apr 28, 2003 6:42 pm

Post by crowbert » Wed Apr 23, 2008 5:22 pm

I finally got ifplugd working.

I had to upgrade dhcpcd to the latest version.
I had to add -L to dhcpcd options to prevent it from configuring disconnected interfaces.
I had to set rc_depend_strict="NO" in rc.conf so that services would start without both interfaces coming up.

I also found that ifplugd works correctly with parallel initialization. My previous experience was that ifplugd and parallel startup was not a happy configuration. (I thought there was a bug report on this, but I couldn't find one.)

Anyway, much of my difficulty was due to errors in reconstructing /etc/conf.d/net. The rest was in not paying enough attention to /etc/rc.conf.
Top
semdornus
n00b
n00b
Posts: 58
Joined: Thu Sep 13, 2007 1:52 am
Location: Tokyo

Post by semdornus » Thu Apr 24, 2008 10:49 am

Just a small fyi; I'm using dash as my /bin/sh and I got the message "/lib/rc/sh/runscript.sh: 193: [[ not found"
when starting cpufreqd. Of course after removing all the double brackets it works as expected.
Top
fintan
Apprentice
Apprentice
User avatar
Posts: 150
Joined: Thu Nov 06, 2003 12:15 pm
Location: Dublin

fscking my home partition in the background

Post by fintan » Thu Apr 24, 2008 11:32 am

Hi all

I've just installed openrc. I had some issues but most of them are sorted now. My home partition is 200G+. So it takes some time to check. I was wondering is it possible to check it in the background since it's not needed until I login? Thanks

fintan
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: fscking my home partition in the background

Post by UberLord » Thu Apr 24, 2008 11:40 am

fintan wrote:I've just installed openrc. I had some issues but most of them are sorted now. My home partition is 200G+. So it takes some time to check. I was wondering is it possible to check it in the background since it's not needed until I login? Thanks
Check /etc/conf.d/fsck for an example of this.
You should enable rc_parallel in /etc/rc.conf for best benefit though.
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
fintan
Apprentice
Apprentice
User avatar
Posts: 150
Joined: Thu Nov 06, 2003 12:15 pm
Location: Dublin

Post by fintan » Thu Apr 24, 2008 12:28 pm

Thanks UberLord

So if I set fsck_passno="=1" to one it should just check one file system a a time?
Top
UberLord
Retired Dev
Retired Dev
User avatar
Posts: 6838
Joined: Thu Sep 18, 2003 10:26 am
Location: Blighty
Contact:
Contact UberLord
Website

Post by UberLord » Thu Apr 24, 2008 12:40 pm

No, it will just check fstab entries marked with a passno of 1.
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
fintan
Apprentice
Apprentice
User avatar
Posts: 150
Joined: Thu Nov 06, 2003 12:15 pm
Location: Dublin

Post by fintan » Thu Apr 24, 2008 12:43 pm

cool I'll figure the rest out. Thanks again
Top
furanku
l33t
l33t
User avatar
Posts: 905
Joined: Thu May 08, 2003 8:58 am
Location: Hamburg, Germany

Post by furanku » Thu Apr 24, 2008 12:47 pm

Here my experience from the migration:

- Besides that also i needed to recreate net.eth0,
- /etc/init.d/kexec stopped working (rebootet normally via bios, not kexec). I replaced it with the script from bugs.gentoo.org, which made it working again, but autodetection of kernel commandline and root device still didn't work. Entering these in /etc/conf.d/kexec was a workaround for that.
- In /etc/init.d/vboxdrv I had to replace /sbin/functions.sh with /etc/init.d/functions.sh. Is there already a bug report for that?
- I have a non-gentoo initscript for the commercial twonkyserver (UPnP) which stopped working if started in the boot process, but works if called manually via "/etc/init.d/twonkyserver start". Have to investigate that further, help would be appreciated
- Due to the almost same time upgrade to 2.6.25 and the problems with uvesafb, I lost my framebuffer console, but I'm not sure if BL2/OpenRC is involved into that and repaired it by setting it up from scratch.

Boot time is greatly improved, all in all it was worth it although the transisition was a little bit rough due to the buggy first 2.6.25 release, should have known better not to change two imporant parts of the system at the same time.
Top
NiceGuy
Guru
Guru
User avatar
Posts: 451
Joined: Mon Jun 12, 2006 1:35 pm
Location: Canada

openrc benefits?

Post by NiceGuy » Thu Apr 24, 2008 4:06 pm

Hello,

Other than a faster bootup time, can I get some clarity on what other benefits there are in adopting openrc on my system? I have just recently switched, and I'll admit, it appears nice, quick and clean, but I'm new to it, and am not entirely sure if I am utilizing it to its maximum.

Are there other current benefits or perhaps just long terms benefits that I am not aware of?
Thanks
success is the ability to go from one failure to the next without any loss of enthusiasm
Top
darkphader
Veteran
Veteran
User avatar
Posts: 1225
Joined: Thu May 09, 2002 11:24 pm
Location: Motown
Contact:
Contact darkphader
Website

Post by darkphader » Thu Apr 24, 2008 8:03 pm

Still have a number of issues with openrc.
  • alsa settings don't save and restore
  • nsd doesn't start, which means that:
    • named doesn't start
    • mit-krb5kdc doesn't start
    • mit-krb5kadmind doesn't start
  • txquelen doesn't get set (oddly enough mtu does)
In my case bind is just the dns cache, nsd is the authoritative server, and kerberos needs the TXT and SRV records in order to start. It all worked fine before the "upgrade". The alsa problems are with my desktop (it's not running on the server).

Chris
WYSIWYG - What You See Is What You Grep
Top
bunder
Bodhisattva
Bodhisattva
Posts: 5956
Joined: Sat Apr 10, 2004 5:13 am

Post by bunder » Thu Apr 24, 2008 9:25 pm

merged one post.
Neddyseagoon wrote:The problem with leaving is that you can only do it once and it reduces your influence.
banned from #gentoo since sept 2017
Top
UberLord
Retired Dev
Retired Dev
User avatar
Posts: 6838
Joined: Thu Sep 18, 2003 10:26 am
Location: Blighty
Contact:
Contact UberLord
Website

Post by UberLord » Thu Apr 24, 2008 9:56 pm

You should open bugs for those as I can't find any existing bugs.
Use dhcpcd for all your automated network configuration needs
Use dhcpcd-ui (GTK+/Qt) as your System Tray Network tool
Top
darkphader
Veteran
Veteran
User avatar
Posts: 1225
Joined: Thu May 09, 2002 11:24 pm
Location: Motown
Contact:
Contact darkphader
Website

Post by darkphader » Thu Apr 24, 2008 10:04 pm

UberLord wrote:You should open bugs for those as I can't find any existing bugs.
The txqueuelen bug was opened on 4/16:
http://bugs.gentoo.org/show_bug.cgi?id=217948

Will get to the others - waiting to be at the console when nsd fails so I can provide more info.
WYSIWYG - What You See Is What You Grep
Top
trad511
n00b
n00b
Posts: 27
Joined: Sat Nov 29, 2003 5:05 pm

Post by trad511 » Fri Apr 25, 2008 1:38 am


...You need to get dmcrypt to run after root. Try putting this in /etc/conf.d/dmcrypt

rc_need="root"

rc_need="root" and rc_dmcrypt_need="root" both result in dmcrypt failing to start since "fsck would fail". I also tried removing fsck, rc_dmcrypt_after="root", etc..., but to no avail. In addition the depends() functions in root, fsck and dmcrypt seem to force the requirements I need, but still doesn't work.

I have a gpg key on usb to decrypt /home, but the /lib/rcscripts/addons/dm-crypt-start.sh requires / to be rw as shown below:

Code: Select all

local mntrem=/mnt/remdev.$$
if [ ! -d "${mntrem}" ] ; then
    if ! mkdir -p "${mntrem}" ; then
        ewarn "${source} will not be decrypted ..."
        einfo "Reason: Unable to create temporary mount point '${mntrem}'"
        return
    fi
fi

Unfortunately it still seems like fsck, root and dmcrypt create a circular dependency for startup (despite trying to override) which dmcrypt always loses.

Any other ideas?

I've solved this.


I have /home, /tmp, and swap in dmcrypt, but this would probably work for everything except encrypted /.

The suggestion I was given by Roy was to put rc_need="root" in /etc/conf.d/dmcrypt. Unfortunately, as stated in my last post dmcrypt needs /mnt to be read-write in order to temporarily mount the usb drive to get the key (in my case gpg-encrypted). The real problem is that rc_need="root" puts root, fsck and dmcrypt in a circular dependency which dmcrypt always lost.

But, using Roy's suggestion I tried several options. I needed:

1. dmcrypt needs / to be read-write
2. dmcrypt needs to run after fsck (bear with me on this one) to break the dependency cycle.
3. dmcrypt needs to run before localmount or else filesystems (in fstab) won't get mounted.
4. localmount mounts things in order of appearance in /etc/fstab.

There are probably some simplifications that can be made (will try them soon), but this is what I got to work:

1. Add to /etc/rc.conf: rc_dmcrypt_need="root"
2. Add to /etc/rc.conf: rc_dmcrypt_after="fsck"
3. Add to /etc/rc.conf: rc_dmcrypt_before="localmount"
4. Put encrypted filesystems last in /etc/fstab (maybe not needed)
5. Put sixth field (fsck) in /etc/fstab to zero (0) for all encrypted filesystem (maybe not needed).

This works on both my systems and does not require script hackery - it uses the super flexible native facilities built in to openrc. The only thing I don't like about the solution is the mods to /etc/fstab. This shouldn't be needed (and may not, but I've not tested).

I believe that a bit better HOWTO of openrc rc_ options and boot ordering and baselayout2 would have sped up my discovery, but a week of (un)concentrated work isn't bad for a brand new application. I do think, after looking through cryptsetup scripts that _assuming_ /mnt will be read-write at the time the init script is run is not great design. A key exchange on a ramdisk or temporary ramdisk mount point might be better.

Hope this helps somebody. I'll let you know when I try the other (non-fstab hack) options.
Success is the ability to go from one failure to another with no loss of enthusiasm. - Winston Churchill
Top
Locked

820 posts
  • Page 6 of 33
    • Jump to page:
  • Previous
  • 1
  • …
  • 4
  • 5
  • 6
  • 7
  • 8
  • …
  • 33
  • Next

Return to “Other Things Gentoo”

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