Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 493544 - /sbin/runscript fails silently when /run/openrc is unexpectedly empty
Summary: /sbin/runscript fails silently when /run/openrc is unexpectedly empty
Status: UNCONFIRMED
Alias: None
Product: Gentoo Hosted Projects
Classification: Unclassified
Component: OpenRC (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: OpenRC Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-07 17:34 UTC by Honza
Modified: 2013-12-09 12:35 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Honza 2013-12-07 17:34:57 UTC
/sbin/runscript from openrc (called as /etc/init.d/anything, like /etc/init.d/ssh start for example) will fail miserably if /run/openrc is cleaned, missing or something. It somehow concludes that the service is already starting and do nothing.

Note that I'm aware that /run/openrc is not supposed to be cleaned. I'm filling next bug about that.

Reproducible: Always

Steps to Reproduce:
1. somehow manage to have empty /run
2. /etc/init.d/anything start

Actual Results:  
 * WARNING: anything is already starting


Expected Results:  
Ideally, fill /run/openrc/ correctly and start the service. If not possible, at least provide warning message which make sense.

Note that surprisingly, calling rc-status DOES fill /run/openrc with enough directories to make runscript behave correctly, so perhaps call some function which rc-status calls before wrongly concluding anything is starting?

Portage 2.2.7 (hardened/linux/amd64, gcc-4.6.3-hardenednopie, glibc-2.11.2-r3, 3.0.6-gentoo-64 x86_64)
=================================================================
System uname: Linux-3.0.6-gentoo-64-x86_64-AMD_Athlon-tm-_64_Processor_3000+-with-gentoo-2.2
KiB Mem:     3296612 total,    375368 free
KiB Swap:          0 total,         0 free
Timestamp of tree: Sat, 30 Nov 2013 12:45:02 +0000
ld GNU ld (GNU Binutils) 2.20.1.20100303
app-shells/bash:          4.2_p45
dev-java/java-config:     1.3.7-r1, 2.1.12-r1
dev-lang/python:          2.6.8-r3, 2.7.5-r3
dev-util/cmake:           2.8.10.2-r2
dev-util/pkgconfig:       0.28
sys-apps/baselayout:      2.2
sys-apps/openrc:          0.12.4
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13::<unknown repository>, 2.68
sys-devel/automake:       1.4_p6-r1, 1.5-r1, 1.6.3-r1, 1.7.9-r2, 1.8.5-r4, 1.9.6-r3, 1.10.3, 1.11.6, 1.12.6, 1.13.4
sys-devel/binutils:       2.16.1-r3::<unknown repository>, 2.18-r3, 2.20.1-r1
sys-devel/gcc:            3.4.6-r2, 4.3.4, 4.4.6-r1, 4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4-r1
sys-devel/make:           3.82-r1
sys-kernel/linux-headers: 3.1 (virtual/os-headers)
sys-libs/glibc:           2.11.2-r3
Repositories: gentoo x-portage
ACCEPT_KEYWORDS="amd64"
ACCEPT_LICENSE="* -@EULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe -mtune=athlon64"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/gnupg/qualified.txt"
CONFIG_PROTECT_MASK="/etc/env.d /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/php/apache2-php5.3/ext-active/ /etc/php/cgi-php5.3/ext-active/ /etc/php/cli-php5.3/ext-active/ /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-O2 -pipe -mtune=athlon64"
DISTDIR="/usr/portage/distfiles"
FCFLAGS="-O2 -pipe"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles merge-sync metadata-transfer news parallel-fetch preserve-libs protect-owned sandbox sfperms unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox usersync xattr"
FFLAGS="-O2 -pipe"
GENTOO_MIRRORS="ftp://ftp.tu-clausthal.de/pub/linux/gentoo http://ftp.sh.cvut.cz/MIRRORS/gentoo/gentoo/ http://www.mirror.ac.uk/sites/www.ibiblio.org/gentoo/ http://gentoo.oregonstate.edu http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --omit-dir-times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="3dnow 3dnowex X Xaw3d aalib acl acpi alsa amd64 apache2 apm audiofile avi berkdb browserplugin bzip2 bzlib caps cdr cli cracklib crypt curl cxx dbase dbm dbx dga directfb divx4linux doc dri dvd dvdr encode esd ethereal exif fbcon flac flash gd gdbm ggi gif gpm gtk hardened iconv imagemagick imlib innodb ipv6 java jpeg justify lcms lesstif libcaca libwww lirc lzma lzo mad mailwrapper mbox mcal memlimit mhash mikmod mime ming mmap mmx mmx2 mng modules motif mozilla mp3 mpeg mudflap multilib multislot mysql ncurses nls nptl offensive oggvorbis openal opengl openmp oss pam pax_kernel pcntl pcre pdflib perl php plotutils png posix python qt quicktime readline real rtc samba sdl session shared sharedmem slang sndfile snmp sockets spell sqlite sse sse2 ssl sysvipc tcpd tetex theora tiff truetype unicode urandom usb v4l v4l2 vhosts videos wmf xinerama xml xosd xpm xsl xv xvid zip zlib" ABI_X86="64" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" APACHE2_MODULES="access auth auth_dbm auth_anon auth_digest alias file-cache echo charset-lite cache disk-cache mem-cache ext-filter case_filter case-filter-in deflate mime-magic cern-meta expires headers usertrack unique-id proxy proxy-connect proxy-ftp proxy-http info include cgi cgid dav dav-fs vhost-alias speling rewrite log_config logio env setenvif mime status autoindex asis negotiation dir imap actions userdir so filter unique_id authz_host auth_basic authn_dbd authn_file authz_owner authz_user charset_lite dbd mem_cache" APACHE2_MPMS="prefork" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump author" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ublox ubx" INPUT_DEVICES="evdev keyboard mouse" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="en cs en_GB" OFFICE_IMPLEMENTATION="libreoffice" PHP_TARGETS="php5-5" PYTHON_SINGLE_TARGET="python2_7" PYTHON_TARGETS="python2_6 python2_7" RUBY_TARGETS="ruby19 ruby18" USERLAND="GNU" VIDEO_CARDS="nv vesa r128 fbdev radeon nouveau" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
USE_PYTHON="2.6 2.7"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LANG, LC_ALL, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS