ruby compile error on new slicehost.com vps

I just purchased a centOS5 vps from slicehost.com earlier today.

I have installed the following so far:

yum install httpd
yum install glibc
yum install gcc
yum install gcc-c++
yum install make

I downloaded ruby 1.8.6 and can ./configure just fine

when i try to make it gets about half way through then gets this error:

compiling nkf
make[1]: Entering directory `/usr/local/src/ruby-1.8.6/ext/nkf'
gcc -I. -I../.. -I../../. -I../.././ext/nkf -fPIC -g -O2 -c nkf.c
nkf.c:654: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make[1]: *** [nkf.o] Error 1
make[1]: Leaving directory `/usr/local/src/ruby-1.8.6/ext/nkf'
make: *** [all] Error 1

I haven't had any issues compiling on other Redhat Linux Server. Do you
know what the problem could be? I couldn't find anything on google yet.

thanks!

nevermind. i figured it out. i had to run the following:

yum install compat-gcc-34-g77.x86_64
yum install compat-gcc-34-c++.x86_64

Scott Kulik wrote:

nevermind. i figured it out. i had to run the following:

yum install compat-gcc-34-g77.x86_64
yum install compat-gcc-34-c++.x86_64

oops...i guess i have another problem.

im trying to install rails with gem and i'm getting the following:

gem install rails --include-dependencies

INFO: `gem install -y` is now default and will be removed
INFO: use --ignore-dependencies to install only the gems you list
Bulk updating Gem source index for: http://gems.rubyforge.org/
/usr/local/lib/ruby/site_ruby/1.8/rubygems/specification.rb:554: [BUG]
Segmentation fault
ruby 1.8.6 (2007-03-13) [x86_64-linux]

any ideas?

Scott Kulik wrote:

nevermind. i figured it out. i had to run the following:

yum install compat-gcc-34-g77.x86_64
yum install compat-gcc-34-c++.x86_64

oops...i guess i have another problem.

im trying to install rails with gem and i'm getting the following:

Is your ruby the very latest and greatest? 1.8.6p230 is known to
segfault.

Fred

Frederick Cheung wrote:

Is your ruby the very latest and greatest? 1.8.6p230 is known to
segfault.

Fred

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]

i tried it again and it's getting farther...at least it installed some
gems this time before it seg faulted.

gem install rails --include-dependencies
INFO: `gem install -y` is now default and will be removed
INFO: use --ignore-dependencies to install only the gems you list
Bulk updating Gem source index for: http://gems.rubyforge.org/
Successfully installed rake-0.8.1
Successfully installed activesupport-2.1.0
Successfully installed activerecord-2.1.0
Successfully installed actionpack-2.1.0
Successfully installed actionmailer-2.1.0
Successfully installed activeresource-2.1.0
Successfully installed rails-2.1.0
7 gems installed
Installing ri documentation for rake-0.8.1...
Installing ri documentation for activesupport-2.1.0...
/usr/local/lib/ruby/1.8/irb/slex.rb:204: [BUG] Segmentation fault
ruby 1.8.6 (2007-03-13) [x86_64-linux]

Aborted

i'll keep trying.

Frederick Cheung wrote:

Is your ruby the very latest and greatest? 1.8.6p230 is known to
segfault.

Fred

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]

i'd try the latest patch level before 230

Fred

Frederick Cheung wrote:

it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]

i'd try the latest patch level before 230

Fred

ok i downloaded patch level 114

now i'm getting errors trying to compile that:

[ruby-1.8.6-p114]# make
pack.c: In function 'pack_unpack':
pack.c:2120: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [pack.o] Error 1

then if i run make again (and anytime after) i get this error:

[ruby-1.8.6-p114]# make
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c pack.c
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c parse.c
parse.c: In function 'ruby_yyparse':
parse.c:4074: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [parse.o] Error 1

hmm...this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.

hmm...this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

no idea, but have you tried any of the slicehost installation guides?

Fred

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.

If gcc or ruby are segfaulting then something is quite screwed. No
ruby code should ever be able to crash the interpreter itself.

Frederick Cheung wrote:
>
>> it is ruby 1.8.6 (2007-03-13 patchlevel 0) [x86_64-linux]
> i'd try the latest patch level before 230
>
> Fred

ok i downloaded patch level 114

now i'm getting errors trying to compile that:

[ruby-1.8.6-p114]# make
pack.c: In function 'pack_unpack':
pack.c:2120: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [pack.o] Error 1

then if i run make again (and anytime after) i get this error:

[ruby-1.8.6-p114]# make
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c pack.c
gcc -g -O2 -DRUBY_EXPORT -D_GNU_SOURCE=1 -I. -I. -c parse.c
parse.c: In function 'ruby_yyparse':
parse.c:4074: internal compiler error: Segmentation fault
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://bugzilla.redhat.com/bugzilla> for instructions.
The bug is not reproducible, so it is likely a hardware or OS problem.
make: *** [parse.o] Error 1

hmm...this is frustrating since it installed so easy on my 32-bit intel
redhat es3.

is there some standard versions i should be using for 64-bit amd centOS
5?

do you think i should try the newest gem? i am running 1.1.1 and i just
noticed there is 1.2.0.

Craig White wrote:

well i have 1.8.6 installed on my other redhat development server so i
figured i should keep the versions the same.

i did see yum had some 1.8.5 packages that i'll try installing. thanks!

what distro do you guys usually run rails under? all the tutorials on
slicehost are either for ubuntu or debian.

oh one more thing...is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/

oh one more thing...is there any easy way to remove the 1.8.6 rails
install i did from the source code? its installed in /usr/local/bin/

I'm have multiple Centos 5 server running 1.8.6 and 1.8.7 and have
never seen issues like this... (Both 64bit and 32bit btw)

The first thing that I always do is remove any of the supplied ruby
installs that are provided with the os.

Currently I'm using gems 1.1.1

I know this does not help but just fyi...

I start with a centos5 box that is stripped to the bone then run this
command:

yum groupinstall "Development Libraries"

Here is a list of other groups that are installed:

Installed Groups:
   Development Libraries
   Editors
   System Tools
   Text-based Internet
   Network Servers
   Legacy Software Development
   Mail Server
   Server Configuration Tools
   Administration Tools

Craig White wrote:

Craig White wrote:
>> oh one more thing...is there any easy way to remove the 1.8.6 rails
>> install i did from the source code? its installed in /usr/local/bin/
> ----
> always tricky but if you did a 'make install' - try going to the same
> build directory and try running 'make uninstall'
>
> Craig

thanks for all the info craig. yea, no make uninstall for these
downloads. i think it might be best just to do a fresh reload of my
server and install all the ruby packages from yum.

which version of gem do you think i should go with? that latest 1.2.0
or something earlier?

thanks again for all the help so far!

heimdull wrote:

I'm have multiple Centos 5 server running 1.8.6 and 1.8.7 and have
never seen issues like this... (Both 64bit and 32bit btw)

The first thing that I always do is remove any of the supplied ruby
installs that are provided with the os.

Currently I'm using gems 1.1.1

I know this does not help but just fyi...

I start with a centos5 box that is stripped to the bone then run this
command:

yum groupinstall "Development Libraries"

Here is a list of other groups that are installed:

Installed Groups:
   Development Libraries
   Editors
   System Tools
   Text-based Internet
   Network Servers
   Legacy Software Development
   Mail Server
   Server Configuration Tools
   Administration Tools

ok i just reloaded my os from scratch. the first thing i tried to do
was:

yum groupinstall "Development Libraries"

--> Processing Dependency: libXinerama.so.1 for package: gtk2
--> Processing Dependency: libXi.so.6 for package: gtk2
--> Processing Dependency: libesd.so.0()(64bit) for package: libgnome
--> Processing Dependency: libavahi-glib.so.1 for package: gnome-vfs2
--> Processing Dependency: libXrandr.so.2()(64bit) for package: gtk2
--> Processing Dependency: libavahi-client.so.3()(64bit) for package:
gnome-vfs2
--> Processing Dependency: libXau.so.6 for package: libX11
--> Processing Dependency: libhal.so.1 for package: gnome-vfs2
--> Processing Dependency: glibc-common = 2.5-18.el5_1.1 for package:
glibc
Error: No Package Matching glibc.i686

and when i do run

[root@webapp1 ~]# yum list | grep glibc.i686
glibc.i686 2.5-18.el5_1.1
installed
glibc.i686 2.5-24 base

why do you think the groupinstall isn't finding this package?

this groupinstall would be very useful if i could get it working and
save me a ton of individual package installs.

heimdull wrote:
> I'm have multiple Centos 5 server running 1.8.6 and 1.8.7 and have
> never seen issues like this... (Both 64bit and 32bit btw)
>
> The first thing that I always do is remove any of the supplied ruby
> installs that are provided with the os.
>
> Currently I'm using gems 1.1.1
>
> I know this does not help but just fyi...
>
> I start with a centos5 box that is stripped to the bone then run this
> command:
>
> yum groupinstall "Development Libraries"
>
> Here is a list of other groups that are installed:
>
> Installed Groups:
> Development Libraries
> Editors
> System Tools
> Text-based Internet
> Network Servers
> Legacy Software Development
> Mail Server
> Server Configuration Tools
> Administration Tools

ok i just reloaded my os from scratch. the first thing i tried to do
was:

yum groupinstall "Development Libraries"

--> Processing Dependency: libXinerama.so.1 for package: gtk2
--> Processing Dependency: libXi.so.6 for package: gtk2
--> Processing Dependency: libesd.so.0()(64bit) for package: libgnome
--> Processing Dependency: libavahi-glib.so.1 for package: gnome-vfs2
--> Processing Dependency: libXrandr.so.2()(64bit) for package: gtk2
--> Processing Dependency: libavahi-client.so.3()(64bit) for package:
gnome-vfs2
--> Processing Dependency: libXau.so.6 for package: libX11
--> Processing Dependency: libhal.so.1 for package: gnome-vfs2
--> Processing Dependency: glibc-common = 2.5-18.el5_1.1 for package:
glibc
Error: No Package Matching glibc.i686

and when i do run

[root@webapp1 ~]# yum list | grep glibc.i686
glibc.i686 2.5-18.el5_1.1
installed
glibc.i686 2.5-24 base

why do you think the groupinstall isn't finding this package?

this groupinstall would be very useful if i could get it working and
save me a ton of individual package installs.

thanks craig after updating yum i got all the packages to install
properly. i still am occasionally getting random segmentation faults
which i think is due to memory usage since I only have 256MB. If i run
the updates again they usually work the second time.

i was reading on slicehost forums that gem 1.1.1 has a memory leak which
is causing issues on 256MB slices like mine. I'm going to try and roll
back a version to 1.1.0 and see if that helps any.

----
you shouldn't be getting random seg faults at all w/ 256MB RAM...it
should work.

you probably should be using runlevel 3 (text w/networking) and not
using GUI with that amount of RAM though.

Craig

Yea i can't explain it either. I'm in chat with slicehost support and
they say that the gui layer is not installed unless specified.

i finally got a working app with mysql installed on centos but not after
a few seg faults trying to start up webbrick.

they convinced me to go with ubuntu hardy. i just blew my system away.

time to see if this is any better.

if not, maybe i have some hardware issues.

ill let you know how my rails woes pan out with that distro.