Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 220136 - sys-fs/cryptsetup for crypt-swap takes ages with openrc waiting for udev to finish
Summary: sys-fs/cryptsetup for crypt-swap takes ages with openrc waiting for udev to f...
Status: RESOLVED OBSOLETE
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] baselayout (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo's Team for Core System packages
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-03 17:39 UTC by Bernd Wurst
Modified: 2012-10-22 04:47 UTC (History)
2 users (show)

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


Attachments
cryptsetup.strace (cryptsetup.strace,410.51 KB, text/plain)
2008-05-03 17:40 UTC, Bernd Wurst
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Bernd Wurst 2008-05-03 17:39:43 UTC
Upgraded to baselayout-2 today and noticed that my encrypted swap needs literally minutes to be set up.

After some debugging, I found out that cryptsetup is calling udevsettle and the latter one waits ages for /dev/.udev/queue to disappear.

Will attach strace log here.

This behaviour started when I upgraded my system last night to current ~amd64 state. This was not only baselayout-2 but some other things too. But no udev or cryptsetup, AFAICS.




Portage 2.1.5_rc6 (default-linux/amd64/2007.0, gcc-4.2.3, glibc-2.7-r2, 2.6.24-marvin-1 x86_64)
=================================================================
System uname: 2.6.24-marvin-1 x86_64 Intel(R) Pentium(R) 4 CPU 2.66GHz
Timestamp of tree: Fri, 02 May 2008 14:30:01 +0000
ccache version 2.4 [enabled]
app-shells/bash:     3.2_p33
dev-java/java-config: 1.3.7, 2.1.6
dev-lang/python:     2.4.3-r4, 2.5.2-r2
dev-python/pycrypto: 2.0.1-r6
dev-util/ccache:     2.4-r7
sys-apps/baselayout: 2.0.0
sys-apps/openrc:     0.2.3
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.62
sys-devel/automake:  1.5, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2, 1.10.1-r1
sys-devel/binutils:  2.18-r1
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.25-r1
ABI="amd64"
ACCEPT_KEYWORDS="amd64 ~amd64"
ALSA_CARDS="intel8x0"
ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol"
ANT_HOME="/usr/share/ant"
APACHE2_MODULES="log_config authz_host dir mime"
ARCH="amd64"
ASFLAGS_x86="--32"
AUTOCLEAN="yes"
CAMERAS="ptp2"
CBUILD="x86_64-pc-linux-gnu"
CCACHE_DIR="/var/tmp/ccache"
CCACHE_SIZE="2G"
CDEFINE_amd64="__x86_64__"
CDEFINE_x86="__i386__"
CFLAGS="-O2 -pipe -march=nocona"
CFLAGS_x86="-m32 -L/emul/linux/x86/lib -L/emul/linux/x86/usr/lib"
CHOST="x86_64-pc-linux-gnu"
CHOST_amd64="x86_64-pc-linux-gnu"
CHOST_x86="i686-pc-linux-gnu"
CLASSPATH="."
CLEAN_DELAY="5"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c /etc/udev/rules.d"
CVS_RSH="ssh"
CXXFLAGS="-O2 -pipe -march=nocona"
DEFAULT_ABI="amd64"
DISPLAY=":0"
DISTDIR="/usr/portage/distfiles"
EDITOR="/usr/bin/vim"
ELIBC="glibc"
EMERGE_DEFAULT_OPTS="--verbose"
EMERGE_WARNING_DELAY="10"
FEATURES="ccache distlocks parallel-fetch sandbox sfperms strict unmerge-orphans userfetch"
FETCHCOMMAND="/usr/bin/wget -t 5 -T 60 --passive-ftp -O "${DISTDIR}/${FILE}" "${URI}""
GCC_SPECS=""
GDK_USE_XFT="1"
GENERATION="2"
GENTOO_MIRRORS="http://gentoo.intergenia.de ftp://ftp.join.uni-muenster.de/pub/linux/distributions/gentoo"
GUILE_LOAD_PATH="/usr/share/guile/1.8"
HOME="/root"
INFOPATH="/usr/share/info:/usr/share/binutils-data/x86_64-pc-linux-gnu/2.18/info:/usr/share/gcc-data/x86_64-pc-linux-gnu/4.2.3/info"
INPUT_DEVICES="keyboard mouse evdev"
JAVAC="/etc/java-config-2/current-system-vm/bin/javac"
JAVA_HOME="/etc/java-config-2/current-system-vm"
JDK_HOME="/etc/java-config-2/current-system-vm"
KDEDIRS="/usr:/usr/local:/usr/kde/3.5"
KERNEL="linux"
LANG="de_DE.utf8"
LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text"
LC_ALL="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--sort-common -Wl,--as-needed"
LDFLAGS_x86="-m elf_i386 -L/emul/linux/x86/lib -L/emul/linux/x86/usr/lib"
LESS="-R -M --shift 5"
LESSOPEN="|lesspipe.sh %s"
LIBDIR_amd64="lib64"
LIBDIR_x86="lib32"
LINGUAS="de"
LOGNAME="root"
LS_COLORS="rs=0:di=01;34:ln=01;36:pi=40;33:so=01;35:do=01;35:bd=40;33;01:cd=40;33;01:or=01;05;37;41:mi=01;05;37;41:su=37;41:sg=30;43:tw=30;42:ow=34;42:st=37;44:ex=01;32:*.tar=01;31:*.tgz=01;31:*.arj=01;31:*.taz=01;31:*.lzh=01;31:*.lzma=01;31:*.zip=01;31:*.z=01;31:*.Z=01;31:*.dz=01;31:*.gz=01;31:*.bz2=01;31:*.bz=01;31:*.tbz2=01;31:*.tz=01;31:*.deb=01;31:*.rpm=01;31:*.jar=01;31:*.rar=01;31:*.ace=01;31:*.zoo=01;31:*.cpio=01;31:*.7z=01;31:*.rz=01;31:*.jpg=01;35:*.jpeg=01;35:*.gif=01;35:*.bmp=01;35:*.pbm=01;35:*.pgm=01;35:*.ppm=01;35:*.tga=01;35:*.xbm=01;35:*.xpm=01;35:*.tif=01;35:*.tiff=01;35:*.png=01;35:*.svg=01;35:*.svgz=01;35:*.mng=01;35:*.pcx=01;35:*.mov=01;35:*.mpg=01;35:*.mpeg=01;35:*.m2v=01;35:*.mkv=01;35:*.ogm=01;35:*.mp4=01;35:*.m4v=01;35:*.mp4v=01;35:*.vob=01;35:*.qt=01;35:*.nuv=01;35:*.wmv=01;35:*.asf=01;35:*.rm=01;35:*.rmvb=01;35:*.flc=01;35:*.avi=01;35:*.fli=01;35:*.flv=01;35:*.gl=01;35:*.dl=01;35:*.xcf=01;35:*.xwd=01;35:*.yuv=01;35:*.pdf=00;32:*.ps=00;32:*.txt=00;32:*.patch=00;32:*.diff=00;32:*.log=00;32:*.tex=00;32:*.doc=00;32:*.aac=00;36:*.au=00;36:*.flac=00;36:*.mid=00;36:*.midi=00;36:*.mka=00;36:*.mp3=00;36:*.mpc=00;36:*.ogg=00;36:*.ra=00;36:*.wav=00;36:"
MAKEOPTS="-j2"
MANPATH="/etc/java-config-2/current-system-vm/man:/usr/local/share/man:/usr/share/man:/usr/share/binutils-data/x86_64-pc-linux-gnu/2.18/man:/usr/share/gcc-data/x86_64-pc-linux-gnu/4.2.3/man:/opt/blackdown-jdk-1.4.2.03/man:/etc/java-config/system-vm/man/:/usr/kde/3.5/share/man:/usr/qt/3/doc/man:/opt/opera/share/man"
MULTILIB_ABIS="amd64 x86"
MULTILIB_STRICT_DENY="64-bit.*shared object"
MULTILIB_STRICT_DIRS="/lib /usr/lib /usr/kde/*/lib /usr/qt/*/lib /usr/X11R6/lib"
MULTILIB_STRICT_EXEMPT="(perl5|gcc|gcc-lib|binutils|eclipse-3|debug|portage)"
OPENGL_PROFILE="xorg-x11"
PAGER="/usr/bin/less"
PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.2.3:/opt/blackdown-jdk-1.4.2.03/bin:/opt/blackdown-jdk-1.4.2.03/jre/bin:/usr/kde/3.5/sbin:/usr/kde/3.5/bin:/usr/qt/3/bin"
PKGDIR="/usr/portage/packages"
PKG_CONFIG_PATH="/usr/qt/3/lib64/pkgconfig"
PORTAGE_ARCHLIST="ppc s390 amd64 x86 ppc64 x86-fbsd m68k arm sparc sh mips ia64 alpha hppa sparc-fbsd"
PORTAGE_BINHOST_CHUNKSIZE="3000"
PORTAGE_BIN_PATH="/usr/lib64/portage/bin"
PORTAGE_CONFIGROOT="/"
PORTAGE_DEBUG="0"
PORTAGE_DEPCACHEDIR="/var/cache/edb/dep"
PORTAGE_ELOG_CLASSES="log warn error"
PORTAGE_ELOG_MAILFROM="portage@localhost"
PORTAGE_ELOG_MAILSUBJECT="[portage] ebuild log for ${PACKAGE} on ${HOST}"
PORTAGE_ELOG_MAILURI="root"
PORTAGE_ELOG_SYSTEM="save_summary echo"
PORTAGE_FETCH_CHECKSUM_TRY_MIRRORS="5"
PORTAGE_FETCH_RESUME_MIN_SIZE="350K"
PORTAGE_GID="250"
PORTAGE_INST_GID="0"
PORTAGE_INST_UID="0"
PORTAGE_PYM_PATH="/usr/lib64/portage/pym"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_RSYNC_RETRIES="3"
PORTAGE_TMPDIR="/var/tmp"
PORTAGE_WORKDIR_MODE="0700"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage/local /usr/local/portage/keks"
PORT_LOGDIR="/var/log/portage"
PWD="/root"
PYTHONPATH="/usr/lib64/portage/pym"
QMAKESPEC="linux-g++"
QTDIR="/usr/qt/3"
RESUMECOMMAND="/usr/bin/wget -c -t 5 -T 60 --passive-ftp -O "${DISTDIR}/${FILE}" "${URI}""
ROOT="/"
ROOTPATH="/opt/bin:/usr/x86_64-pc-linux-gnu/gcc-bin/4.2.3:/opt/blackdown-jdk-1.4.2.03/bin:/opt/blackdown-jdk-1.4.2.03/jre/bin:/usr/kde/3.5/sbin:/usr/kde/3.5/bin:/usr/qt/3/bin"
RPMDIR="/usr/portage/rpm"
SANE_BACKENDS="net plustek"
SANE_CONFIG_DIR="/etc/sane.d"
SCHEME_LIBRARY_PATH="/usr/share/slib/"
SHELL="/bin/bash"
SHLVL="1"
STAGE1_USE="nptl nptlonly unicode"
SYMLINK_LIB="yes"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
TERM="xterm"
USB_DEVFS_PATH="/dev/bus/usb"
USE="X a52 aac acl acpi aiglx alsa amd64 avi berkdb bluetooth bzip2 cairo cddb chipcard cli cpudetection cracklib crypt cups curl dbus divx4linux dmi dri dts dv dvb dvd dvdr dvdread encode exif fam ffmpeg fortran gammu gdbm geldkarte gif gimp gimpprint gnutls gstreamer hal hbci iconv idn ieee1394 imap iproute2 ipv6 isdnlog jpeg kde kdeenablefinal kipi kmid mad midi mmx mmxext mp3 mpeg mudflap mysql ncurses nls nodrm nolvm1 nptl nptlonly obex ogg opengl openmp pam pcre pdf perl png pppd python qt qt3 qt3support qt4 quicktime readline reflection samba scanner sdl session spell spl sqlite3 sse sse2 ssl svg tcpd theora tiff truetype tse3 unicode usb userlocales utf8 vorbis wifi xml xorg xv xvid zlib" ALSA_CARDS="intel8x0" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="log_config authz_host dir mime" CAMERAS="ptp2" ELIBC="glibc" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LINGUAS="de" USERLAND="GNU" VIDEO_CARDS="radeon"
USER="root"
USERLAND="GNU"
USE_EXPAND="ALSA_CARDS ALSA_PCM_PLUGINS APACHE2_MODULES APACHE2_MPMS CAMERAS CROSSCOMPILE_OPTS DVB_CARDS ELIBC FCDSL_CARDS FOO2ZJS_DEVICES FRITZCAPI_CARDS INPUT_DEVICES KERNEL LCD_DEVICES LINGUAS LIRC_DEVICES MISDN_CARDS USERLAND VIDEO_CARDS"
USE_EXPAND_HIDDEN="CROSSCOMPILE_OPTS ELIBC KERNEL USERLAND"
USE_ORDER="env:pkg:conf:defaults:pkginternal:env.d"
VIDEO_CARDS="radeon"
VISUAL="/usr/bin/vim"
VMHANDLE="blackdown-jdk-1.4.2"
XAUTHORITY="/root/.xauthrezkYq"
XDG_DATA_DIRS="/usr/share:/usr/kde/3.5/share:/usr/local/share"
_="/usr/bin/emerge"
Comment 1 Bernd Wurst 2008-05-03 17:40:56 UTC
Created attachment 151717 [details]
cryptsetup.strace
Comment 2 Doug Goldstein (RETIRED) gentoo-dev 2008-05-05 13:44:19 UTC
Without reading any of your debugging info, all I can say is I used an encrypted swap on my box at the office using cryptsetup with a baselayout-2/openrc machine and it's fast as ever. I would include your configuration for it as well.
Comment 3 SpanKY gentoo-dev 2008-10-05 20:53:30 UTC
it needs to wait for udev to process its queue otherwise it may try to operate on devices that do not yet exist
Comment 4 Matthias Schwarzott gentoo-dev 2008-12-03 16:02:10 UTC
I guess the patch from Bug #242778 will solve this issue.
Comment 5 SpanKY gentoo-dev 2012-10-22 04:47:10 UTC
i don't think this is relevant anymore.  cryptsetup doesn't call udevsettle but instead interacts with the dm subsystem.