# Gem install fcgi

**URL:** <https://rubytalk.org/t/gem-install-fcgi/22363>\
**Category:** ruby-talk\
**Created:** [10 November 2005 21:30 UTC](https://rubytalk.org/t/gem-install-fcgi/22363 "2005-11-10T21:30:35Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mohammad\_Khan1](https://avatars.discourse-cdn.com/v4/letter/m/eb9ed0/32.png) [@Mohammad\_Khan1](https://rubytalk.org/u/Mohammad_Khan1)\
**Post date:** [10 November 2005 21:30 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/1 "2005-11-10T21:30:35Z")

</div>

[root@www dhaka]# gem install fcgi  
Attempting local installation of 'fcgi'  
Local gem file not found: fcgi\*.gem  
Attempting remote installation of 'fcgi'  
Updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
Building native extensions. This could take a while...  
can't find header files for ruby.  
ERROR: While executing gem ... (RuntimeError)  
ERROR: Failed to build gem native extension.  
Gem files will remain installed in  
/usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1\<[http://0.8.6.1](http://0.8.6.1)\>for  
inspection.  
ruby extconf.rb install fcgi\n

Results logged to  
/usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1/ext/gem\_make.out\<[http://0.8.6.1/ext/gem\_make.out](http://0.8.6.1/ext/gem_make.out)\>  
[root@www dhaka]# rpm -qa | grep ruby  
ruby-1.8.3-2.fc3  
ruby-docs-1.8.3-2.fc3  
ruby-libs-1.8.3-2.fc3  
[root@www dhaka]#

At what location gem is looking for ruby header files?  
Would anybody please show me right direction.

Thanks,

---

<div class="post-metadata">

**Author:** ![Mohammad\_Khan1](https://avatars.discourse-cdn.com/v4/letter/m/eb9ed0/32.png) [@Mohammad\_Khan1](https://rubytalk.org/u/Mohammad_Khan1)\
**Post date:** [10 November 2005 21:34 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/2 "2005-11-10T21:34:33Z")

</div>

I have figured that Ineed ruby-devel package installed too..  
thanks anyway

> **···**
>
> On 11/10/05, Mohammad Khan \<beeplove@gmail.com\> wrote:
> 
> > [root@www dhaka]# gem install fcgi  
> > Attempting local installation of 'fcgi'  
> > Local gem file not found: fcgi\*.gem  
> > Attempting remote installation of 'fcgi'  
> > Updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
> > Building native extensions. This could take a while...  
> > can't find header files for ruby.  
> > ERROR: While executing gem ... (RuntimeError)  
> > ERROR: Failed to build gem native extension.  
> > Gem files will remain installed in  
> > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1 \<[http://0.8.6.1](http://0.8.6.1)\>\<[http://0.8.6.1](http://0.8.6.1)  
> > \>for  
> > inspection.  
> > ruby extconf.rb install fcgi\n
> > 
> > Results logged to  
> > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1/ext/gem\_make.out\<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);  
> > \<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);  
> > [root@www dhaka]# rpm -qa | grep ruby  
> > ruby-1.8.3-2.fc3  
> > ruby-docs-1.8.3-2.fc3  
> > ruby-libs-1.8.3-2.fc3  
> > [root@www dhaka]#
> > 
> > At what location gem is looking for ruby header files?  
> > Would anybody please show me right direction.
> > 
> > Thanks,

---

<div class="post-metadata">

**Author:** ![Ara.T.Howard6](https://avatars.discourse-cdn.com/v4/letter/a/958977/32.png) [@Ara.T.Howard6](https://rubytalk.org/u/Ara.T.Howard6)\
**Post date:** [10 November 2005 21:42 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/3 "2005-11-10T21:42:04Z")

</div>

have you installed the fastcgi library itself - not the ruby extenstion - the  
fastcgi lib?

-a

> **···**
>
> On Fri, 11 Nov 2005, Mohammad Khan wrote:
> 
> > [root@www dhaka]# gem install fcgi  
> > Attempting local installation of 'fcgi'  
> > Local gem file not found: fcgi\*.gem  
> > Attempting remote installation of 'fcgi'  
> > Updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
> > Building native extensions. This could take a while...  
> > can't find header files for ruby.  
> > ERROR: While executing gem ... (RuntimeError)  
> > ERROR: Failed to build gem native extension.  
> > Gem files will remain installed in  
> > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1\<[http://0.8.6.1](http://0.8.6.1)\>for  
> > inspection.  
> > ruby extconf.rb install fcgi\n
> > 
> > Results logged to  
> > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1/ext/gem\_make.out\<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);  
> > [root@www dhaka]# rpm -qa | grep ruby  
> > ruby-1.8.3-2.fc3  
> > ruby-docs-1.8.3-2.fc3  
> > ruby-libs-1.8.3-2.fc3  
> > [root@www dhaka]#
> > 
> > At what location gem is looking for ruby header files?  
> > Would anybody please show me right direction.
> > 
> > Thanks,
> 
> # --
> 
> > ara [dot] t [dot] howard [at] gmail [dot] com  
> > all happiness comes from the desire for others to be happy. all misery  
> > comes from the desire for oneself to be happy.  
> > -- bodhicaryavatara
> 
> ===============================================================================

---

<div class="post-metadata">

**Author:** ![Mohammad\_Khan1](https://avatars.discourse-cdn.com/v4/letter/m/eb9ed0/32.png) [@Mohammad\_Khan1](https://rubytalk.org/u/Mohammad_Khan1)\
**Post date:** [10 November 2005 21:50 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/4 "2005-11-10T21:50:53Z")

</div>

I have installed ,  
fcgi-2.4.0  
mod\_fastcgi-2.4.2  
gem install fcgi

and followed the instrucion of  
[http://wiki.rubyonrails.com/rails/pages/FastCGI+on+unix+linux+bsd](http://wiki.rubyonrails.com/rails/pages/FastCGI+on+unix+linux+bsd)

and I am getting in my error.log

[Thu Nov 10 16:44:40 2005] [error] [client 66.237.x.y] FastCGI: comm with  
(dynamic) server "/var/www/rails/project\_1/public/dispatch.fcgi" aborted:  
(first read) idle timeout (30 sec)  
[Thu Nov 10 16:44:40 2005] [error] [client 66.237.x.y] FastCGI: incomplete  
headers (0 bytes) received from server  
"/var/www/rails/project\_1/public/dispatch.fcgi"

> **···**
>
> On 11/10/05, Ara.T.Howard \<ara.t.howard@noaa.gov\> wrote:
> 
> > On Fri, 11 Nov 2005, Mohammad Khan wrote:
> > 
> > \> [root@www dhaka]# gem install fcgi  
> > \> Attempting local installation of 'fcgi'  
> > \> Local gem file not found: fcgi\*.gem  
> > \> Attempting remote installation of 'fcgi'  
> > \> Updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
> > \> Building native extensions. This could take a while...  
> > \> can't find header files for ruby.  
> > \> ERROR: While executing gem ... (RuntimeError)  
> > \> ERROR: Failed to build gem native extension.  
> > \> Gem files will remain installed in  
> > \> /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1 \<[http://0.8.6.1](http://0.8.6.1)\>\<[http://0.8.6.1](http://0.8.6.1)  
> > \>for  
> > \> inspection.  
> > \> ruby extconf.rb install fcgi\n  
> > \>  
> > \> Results logged to  
> > \> /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1/ext/gem\_make.out\<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);  
> > \<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);  
> > \> [root@www dhaka]# rpm -qa | grep ruby  
> > \> ruby-1.8.3-2.fc3  
> > \> ruby-docs-1.8.3-2.fc3  
> > \> ruby-libs-1.8.3-2.fc3  
> > \> [root@www dhaka]#  
> > \>  
> > \> At what location gem is looking for ruby header files?  
> > \> Would anybody please show me right direction.  
> > \>  
> > \> Thanks,
> > 
> > have you installed the fastcgi library itself - not the ruby extenstion -  
> > the  
> > fastcgi lib?
> > 
> > -a  
> > --
> > 
> > ===============================================================================  
> > \> ara [dot] t [dot] howard [at] gmail [dot] com  
> > \> all happiness comes from the desire for others to be happy. all misery  
> > \> comes from the desire for oneself to be happy.  
> > \> -- bodhicaryavatara
> > 
> > ===============================================================================

---

<div class="post-metadata">

**Author:** ![Ara.T.Howard6](https://avatars.discourse-cdn.com/v4/letter/a/958977/32.png) [@Ara.T.Howard6](https://rubytalk.org/u/Ara.T.Howard6)\
**Post date:** [11 November 2005 03:33 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/5 "2005-11-11T03:33:17Z")

</div>

> I have installed ,  
> fcgi-2.4.0  
> mod\_fastcgi-2.4.2  
> gem install fcgi
> 
> and followed the instrucion of  
> [http://wiki.rubyonrails.com/rails/pages/FastCGI+on+unix+linux+bsd](http://wiki.rubyonrails.com/rails/pages/FastCGI+on+unix+linux+bsd)
> 
> and I am getting in my error.log
> 
> [Thu Nov 10 16:44:40 2005] [error] [client 66.237.x.y] FastCGI: comm with  
> (dynamic) server "/var/www/rails/project\_1/public/dispatch.fcgi" aborted:  
> (first read) idle timeout (30 sec)  
> [Thu Nov 10 16:44:40 2005] [error] [client 66.237.x.y] FastCGI: incomplete  
> headers (0 bytes) received from server  
> "/var/www/rails/project\_1/public/dispatch.fcgi"

and what does dispatch.fcgi say when you run it from the command line as the  
web user

&nbsp;&nbsp;&nbsp;sudo www ./dispatch.fcgi \< /dev/null

??

> > > [root@www dhaka]# gem install fcgi  
> > > Attempting local installation of 'fcgi'  
> > > Local gem file not found: fcgi\*.gem  
> > > Attempting remote installation of 'fcgi'  
> > > Updating Gem source index for: [http://gems.rubyforge.org](http://gems.rubyforge.org)  
> > > Building native extensions. This could take a while...  
> > > can't find header files for ruby.  
> > > ERROR: While executing gem ... (RuntimeError)  
> > > ERROR: Failed to build gem native extension.  
> > > Gem files will remain installed in  
> > > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1 \<[http://0.8.6.1](http://0.8.6.1)\>\<[http://0.8.6.1](http://0.8.6.1)  
> > > for  
> > > inspection.  
> > > ruby extconf.rb install fcgi\n
> > > 
> > > Results logged to  
> > > /usr/lib/ruby/gems/1.8/gems/fcgi-0.8.6.1/ext/gem\_make.out\<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);
> > 
> > \<[http://0.8.6.1/ext/gem\_make.out&gt](http://0.8.6.1/ext/gem_make.out&gt);
> > 
> > > [root@www dhaka]# rpm -qa | grep ruby  
> > > ruby-1.8.3-2.fc3  
> > > ruby-docs-1.8.3-2.fc3  
> > > ruby-libs-1.8.3-2.fc3  
> > > [root@www dhaka]#
> > > 
> > > At what location gem is looking for ruby header files?  
> > > Would anybody please show me right direction.
> > > 
> > > Thanks,
> > 
> > have you installed the fastcgi library itself - not the ruby extenstion -  
> > the  
> > fastcgi lib?
> > 
> > -a  
> > --
> > 
> > ===============================================================================  
> > \> ara [dot] t [dot] howard [at] gmail [dot] com  
> > \> all happiness comes from the desire for others to be happy. all misery  
> > \> comes from the desire for oneself to be happy.  
> > \> -- bodhicaryavatara
> > 
> > ===============================================================================

-a

> **···**
>
> On Fri, 11 Nov 2005, Mohammad Khan wrote:
> 
> > On 11/10/05, Ara.T.Howard \<ara.t.howard@noaa.gov\> wrote:
> > 
> > > On Fri, 11 Nov 2005, Mohammad Khan wrote:
> 
> # --
> 
> > ara [dot] t [dot] howard [at] gmail [dot] com  
> > all happiness comes from the desire for others to be happy. all misery  
> > comes from the desire for oneself to be happy.  
> > -- bodhicaryavatara
> 
> ===============================================================================

---

<div class="post-metadata">

**Author:** ![Andrew\_Stone](https://avatars.discourse-cdn.com/v4/letter/a/b9bd4f/32.png) [@Andrew\_Stone](https://rubytalk.org/u/Andrew_Stone)\
**Post date:** [11 November 2005 14:41 UTC](https://rubytalk.org/t/gem-install-fcgi/22363/6 "2005-11-11T14:41:18Z")

</div>

> \> [Thu Nov 10 16:44:40 2005] [error] [client 66.237.x.y] FastCGI:  
> incomplete  
> \> headers (0 bytes) received from server  
> \> "/var/www/rails/project\_1/public/dispatch.fcgi"

I think this means the location reference (she-bang) to ruby in the  
dispatch.fcgi is incorrect. I would at least verify that it is pointing to  
the right location.

-andy

> **···**
>
> --  
> Andrew Stone
