Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Gentoo: Hardened

bootstrap.sh fails with a Segmentation Fault

 

 

Gentoo hardened RSS feed   Index | Next | Previous | View Threaded


frank at schreiner-consulting

Mar 11, 2005, 8:50 AM

Post #1 of 9 (402 views)
Permalink
bootstrap.sh fails with a Segmentation Fault

hi all,

i try to install a gentoo-selinux and get an Segmentation Fault when
bootstrap.sh try`s to qmerge the sys-libs/glibc-2.3.4.20040808-r1

i use livecd-x86-selinux-20040616-1.iso and a
stage1-x86-selinux-20041123.tar.bz2.

I also tried stage1-x86-selinux-pie-ssp-20041123.tar.bz2 which also
fails with an Segmentation Fault (after installing libnsl.so.1).

The error is always occurs at the same point (which you can see in the
following outputs)

could anybody point me to the right direction? I googled for this error,
searched in bugs.gentoo.org and the forum, but i didnt find any hint.

greets frank

##########################################################################
output:
##########################################################################
>>> /usr/lib/librt.so -> ../../lib/librt.so.1
>>> /usr/lib/libanl.so -> ../../lib/libanl.so.1
>>> /usr/lib/libnss_nis.so -> ../../lib/libnss_nis.so.2
>>> /usr/lib/libc_nonshared.a
--- /usr/sbin/
>>> /usr/sbin/zic
>>> /usr/sbin/nscd
>>> /usr/sbin/nscd_nischeck
>>> /usr/sbin/zdump
>>> /usr/sbin/rpcinfo
>>> /usr/sbin/iconvconfig
--- /usr/share/
scripts/bootstrap.sh: line 279: 20229 Segmentation fault ${V_ECHO}
USE="-* build bootstrap ${STAGE1_USE}" emerge ${STRAP_EMERGE_OPTS}
${myPORTAGE}
livecd portage # emerge --info
Portage 2.0.51-r3 (selinux/2004.1/x86, gcc-3.3.4, unavailable,
2.6.5-gentoo-r1 i686)
=================================================================
System uname: 2.6.5-gentoo-r1 i686 Intel(R) Pentium(R) 4 CPU 2.53GHz
Gentoo Base System version 1.4.16
Autoconf:
Automake:
Binutils: sys-devel/binutils-2.15.90.0.1.1-r3
Headers: sys-kernel/linux-headers-2.4.22-r1
Libtools:
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O2 -march=pentium4 -pipe -fomit-frame-pointer"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O2 -march=pentium4 -pipe -fomit-frame-pointer"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms strict"
GENTOO_MIRRORS="http://gentoo.osuosl.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="berkdb crypt hardened ncurses pam pic python readline selinux ssl
x86 zlib"

livecd portage #
###########################################################################


--
gentoo-hardened [at] gentoo mailing list


ps.m at gmx

Mar 11, 2005, 3:43 PM

Post #2 of 9 (397 views)
Permalink
Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

On Fri, 11 Mar 2005, Frank Schreiner wrote:

I cant answer your question, but how does it come that you miss the pie
use flag?

Peter

> hi all,
>
> i try to install a gentoo-selinux and get an Segmentation Fault when
> bootstrap.sh try`s to qmerge the sys-libs/glibc-2.3.4.20040808-r1
>
> i use livecd-x86-selinux-20040616-1.iso and a
> stage1-x86-selinux-20041123.tar.bz2.
>
> I also tried stage1-x86-selinux-pie-ssp-20041123.tar.bz2 which also
> fails with an Segmentation Fault (after installing libnsl.so.1).
>
> The error is always occurs at the same point (which you can see in the
> following outputs)
>
> could anybody point me to the right direction? I googled for this error,
> searched in bugs.gentoo.org and the forum, but i didnt find any hint.
>
> greets frank
>
> ##########################################################################
> output:
> ##########################################################################
> >>> /usr/lib/librt.so -> ../../lib/librt.so.1
> >>> /usr/lib/libanl.so -> ../../lib/libanl.so.1
> >>> /usr/lib/libnss_nis.so -> ../../lib/libnss_nis.so.2
> >>> /usr/lib/libc_nonshared.a
> --- /usr/sbin/
> >>> /usr/sbin/zic
> >>> /usr/sbin/nscd
> >>> /usr/sbin/nscd_nischeck
> >>> /usr/sbin/zdump
> >>> /usr/sbin/rpcinfo
> >>> /usr/sbin/iconvconfig
> --- /usr/share/
> scripts/bootstrap.sh: line 279: 20229 Segmentation fault ${V_ECHO}
> USE="-* build bootstrap ${STAGE1_USE}" emerge ${STRAP_EMERGE_OPTS}
> ${myPORTAGE}
> livecd portage # emerge --info
> Portage 2.0.51-r3 (selinux/2004.1/x86, gcc-3.3.4, unavailable,
> 2.6.5-gentoo-r1 i686)
> =================================================================
> System uname: 2.6.5-gentoo-r1 i686 Intel(R) Pentium(R) 4 CPU 2.53GHz
> Gentoo Base System version 1.4.16
> Autoconf:
> Automake:
> Binutils: sys-devel/binutils-2.15.90.0.1.1-r3
> Headers: sys-kernel/linux-headers-2.4.22-r1
> Libtools:
> ACCEPT_KEYWORDS="x86"
> AUTOCLEAN="yes"
> CFLAGS="-O2 -march=pentium4 -pipe -fomit-frame-pointer"
> CHOST="i686-pc-linux-gnu"
> COMPILER=""
> CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config /usr/share/config /var/qmail/control"
> CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
> CXXFLAGS="-O2 -march=pentium4 -pipe -fomit-frame-pointer"
> DISTDIR="/usr/portage/distfiles"
> FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms strict"
> GENTOO_MIRRORS="http://gentoo.osuosl.org
> http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
> MAKEOPTS="-j2"
> PKGDIR="/usr/portage/packages"
> PORTAGE_TMPDIR="/var/tmp"
> PORTDIR="/usr/portage"
> PORTDIR_OVERLAY=""
> SYNC="rsync://rsync.gentoo.org/gentoo-portage"
> USE="berkdb crypt hardened ncurses pam pic python readline selinux ssl
> x86 zlib"
>
> livecd portage #
> ###########################################################################
>
>

--
Peter S. Mazinger <ps dot m at gmx dot net> ID: 0xA5F059F2
Key fingerprint = 92A4 31E1 56BC 3D5A 2D08 BB6E C389 975E A5F0 59F2


--
gentoo-hardened [at] gentoo mailing list


frank at schreiner-consulting

Mar 11, 2005, 11:49 PM

Post #3 of 9 (389 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

Am Freitag, den 11.03.2005, 23:43 +0100 schrieb Peter S. Mazinger:
> On Fri, 11 Mar 2005, Frank Schreiner wrote:
>
> I cant answer your question, but how does it come that you miss the pie
> use flag?

HMM, now i tried to install a stage3 but it`s the same effect, when i
try to install a kernel-source it segfaults at the qmerge process and
this also happens when i try to emerge portage itself (at bc).

I didn`t changed any settings in the make.conf. just installed stage 3
and tried to emerge hardened-dev-source.

helpless

greets frank


--
Frank Schreiner Telefon : +49 911 5975546
IT-Consulting E-Mail : frank [at] schreiner-consulting
Rosental 23 Web : www.schreiner-consulting.com
90403 Nuremberg
Germany


--
gentoo-hardened [at] gentoo mailing list


rumen_yotov at dir

Mar 12, 2005, 12:08 AM

Post #4 of 9 (391 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

On СЃР±, 2005-03-12 at 07:49 +0100, Frank Schreiner wrote:
> Am Freitag, den 11.03.2005, 23:43 +0100 schrieb Peter S. Mazinger:
> > On Fri, 11 Mar 2005, Frank Schreiner wrote:
> >
> > I cant answer your question, but how does it come that you miss the pie
> > use flag?
>
> HMM, now i tried to install a stage3 but it`s the same effect, when i
> try to install a kernel-source it segfaults at the qmerge process and
> this also happens when i try to emerge portage itself (at bc).
>
> I didn`t changed any settings in the make.conf. just installed stage 3
> and tried to emerge hardened-dev-source.
>
> helpless
>
> greets frank
>
>
Hi,
Haven't done this, but there are/were a hardened-stage-3 (stages) to
begin installing a hardened system. As i began using mine quite 2 years
ago, remember that the procedure was different then.
Just a suggestion/tip here. In qmerge phase it might be a sandbox issue,
but then there will be such message or file-system problem. Could check
if the stage ungzips/untars OK elsewhere (also check md5sums).
HTH
--
Rumen Yotov <rumen_yotov [at] dir>
Attachments: smime.p7s (3.24 KB)


solar at gentoo

Mar 12, 2005, 6:39 AM

Post #5 of 9 (392 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

No idea if this is related or not..
Those stages are not the newest and if they contain a program named
isetdyn that might segfault with newer PIEs.
If that is what is causing the segfault you can work around it by doing.
rm `which isetdyn`

On Sat, 2005-03-12 at 07:49 +0100, Frank Schreiner wrote:
> Am Freitag, den 11.03.2005, 23:43 +0100 schrieb Peter S. Mazinger:
> > On Fri, 11 Mar 2005, Frank Schreiner wrote:
> >
> > I cant answer your question, but how does it come that you miss the pie
> > use flag?
>
> HMM, now i tried to install a stage3 but it`s the same effect, when i
> try to install a kernel-source it segfaults at the qmerge process and
> this also happens when i try to emerge portage itself (at bc).
>
> I didn`t changed any settings in the make.conf. just installed stage 3
> and tried to emerge hardened-dev-source.
>
> helpless
>
> greets frank
>
>
--
Ned Ludd <solar [at] gentoo>


--
gentoo-hardened [at] gentoo mailing list


frank at schreiner-consulting

Mar 14, 2005, 4:31 AM

Post #6 of 9 (394 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

On Sat, 2005-03-12 at 08:39 -0500, Ned Ludd wrote:
> No idea if this is related or not..
> Those stages are not the newest and if they contain a program named
> isetdyn that might segfault with newer PIEs.
> If that is what is causing the segfault you can work around it by doing.
> rm `which isetdyn`

i didn`t found isetdyn in the whole system


--
gentoo-hardened [at] gentoo mailing list


ps.m at gmx

Mar 14, 2005, 5:07 AM

Post #7 of 9 (387 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

On Sat, 12 Mar 2005, Frank Schreiner wrote:

> Am Freitag, den 11.03.2005, 23:43 +0100 schrieb Peter S. Mazinger:
> > On Fri, 11 Mar 2005, Frank Schreiner wrote:
> >
> > I cant answer your question, but how does it come that you miss the pie
> > use flag?

maybe the selinux profile does not set USE="pie" ?

>
> HMM, now i tried to install a stage3 but it`s the same effect, when i
> try to install a kernel-source it segfaults at the qmerge process and
> this also happens when i try to emerge portage itself (at bc).
>
> I didn`t changed any settings in the make.conf. just installed stage 3
> and tried to emerge hardened-dev-source.

I do following to be sure that I have correct toolchain, from a stage1
(this procedure works also to switch from a normal stage to hardened)
set the proper relative (relative is important) link to make.conf and
check w/ emerge info what FEATURES/USE are enabled (for hardened you need
hardened pic pie), I do not use selinux, so cant tell what you should see
there
emerge -O gnuconfig
emerge -O gcc-config
if I want to use multiple versions of the toolchain I also emerge -O
binutils-config (you need USE="multislot") for this
USE="build" emerge -O binutils
run binutils-config if installed and select the newly installed binutils
USE="build nocxx" emerge -O gcc
run gcc-config and select newly installed gcc
emerge your preferred headers you want to use in conjunction w/ *libc
USE="build" emerge -O {g,uc}libc

this should be enough to allow you to bootstrap correctly
(I sometimes repeat the above steps once again , so that they are really
synced up)

if you start from a stage3 you should omit from USE "build" and/or
"nocxx" but you are not allowed probably to switch headers (well, I
wouldn't do that, it calls for trouble)

Peter

--
Peter S. Mazinger <ps dot m at gmx dot net> ID: 0xA5F059F2
Key fingerprint = 92A4 31E1 56BC 3D5A 2D08 BB6E C389 975E A5F0 59F2


--
gentoo-hardened [at] gentoo mailing list


frank at schreiner-consulting

Mar 14, 2005, 11:35 AM

Post #8 of 9 (388 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

> I do following to be sure that I have correct toolchain, from a stage1
> (this procedure works also to switch from a normal stage to hardened)
> set the proper relative (relative is important) link to make.conf an

did you mean /etc/make.profile ? because i have no idea where i should
make.conf link to.

> d
> check w/ emerge info what FEATURES/USE are enabled (for hardened you need
> hardened pic pie), I do not use selinux, so cant tell what you should see
> there
> emerge -O gnuconfig
> emerge -O gcc-config
> if I want to use multiple versions of the toolchain I also emerge -O
> binutils-config (you need USE="multislot") for this
> USE="build" emerge -O binutils
> run binutils-config if installed and select the newly installed binutils
> USE="build nocxx" emerge -O gcc
> run gcc-config and select newly installed gcc
> emerge your preferred headers you want to use in conjunction w/ *libc
> USE="build" emerge -O {g,uc}libc
>
> this should be enough to allow you to bootstrap correctly
> (I sometimes repeat the above steps once again , so that they are really
> synced up)
>
> if you start from a stage3 you should omit from USE "build" and/or
> "nocxx" but you are not allowed probably to switch headers (well, I
> wouldn't do that, it calls for trouble)
>
> Peter
>


--
gentoo-hardened [at] gentoo mailing list


ps.m at gmx

Mar 14, 2005, 11:43 AM

Post #9 of 9 (393 views)
Permalink
Re: Re: bootstrap.sh fails with a Segmentation Fault [In reply to]

On Mon, 14 Mar 2005, Frank Schreiner wrote:

>
> > I do following to be sure that I have correct toolchain, from a stage1
> > (this procedure works also to switch from a normal stage to hardened)
> > set the proper relative (relative is important) link to make.conf an
>
> did you mean /etc/make.profile ? because i have no idea where i should
> make.conf link to.

sorry, yes

--
Peter S. Mazinger <ps dot m at gmx dot net> ID: 0xA5F059F2
Key fingerprint = 92A4 31E1 56BC 3D5A 2D08 BB6E C389 975E A5F0 59F2


--
gentoo-hardened [at] gentoo mailing list

Gentoo hardened RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.