# Application Error

**URL:** <https://www.ruby-forum.com/t/application-error/74289>\
**Category:** Rails\
**Created:** [November 3, 2006, 4:42pm UTC](https://www.ruby-forum.com/t/application-error/74289 "2006-11-03T16:42:49Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 3, 2006, 4:42pm UTC](https://www.ruby-forum.com/t/application-error/74289/1 "2006-11-03T16:42:49Z")

</div>

I think I’m relativly close to getting rails up on my domain but I get  
this application error if I try to run the page.

Application error  
Rails application failed to start properly"

At first it was a disptath.cgi error I fixed that by changing the  
attibutes, but now I get this, why may it be happening?

Ryan.

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 3, 2006, 7:55pm UTC](https://www.ruby-forum.com/t/application-error/74289/2 "2006-11-03T19:55:25Z")

</div>

This can be many things. Database connectivity, configuration errors,  
etc. Check your logs for any indication of what’s going on.

c.

Ryan Edwards-Crewe wrote:

> I think I’m relativly close to getting rails up on my domain but I get  
> this application error if I try to run the page.
> 
> Application error  
> Rails application failed to start properly"
> 
> At first it was a disptath.cgi error I fixed that by changing the  
> attibutes, but now I get this, why may it be happening?
> 
> Ryan.

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 3, 2006, 9:23pm UTC](https://www.ruby-forum.com/t/application-error/74289/3 "2006-11-03T21:23:08Z")

</div>

When this happened to me, it took me over an hour to realize it was that  
the public folder didn’t have the right permissions.

Quote from my web host’s help wiki:

“8. cd into your railsapp directory and do chmod -R u+rwX,go-w public  
log to set the correct permissions. The public directory and  
dispatch.fcgi must not be world-writable (or group-writable, just in  
case), and the log directory must be writable so that log and crash  
files can be generated.”

My web host is dreamhost, but even with other hosts you may find their  
installation guide helpful for installing ruby apps. It’s available at  
[http://wiki.dreamhost.com/index.php/Ruby\_on\_Rails#QuickStart\_Guide\_12-01-05](http://wiki.dreamhost.com/index.php/Ruby_on_Rails#QuickStart_Guide_12-01-05)

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 7, 2006, 10:58am UTC](https://www.ruby-forum.com/t/application-error/74289/4 "2006-11-07T10:58:41Z")

</div>

In my experience, it’s a problem with the dispatch file. Does it have  
the correct permissions to execute, and does it point to the proper  
location on the first line #!/bin/ruby or wherever your distro stores  
it? Also, I’ve had problems with log files not having permissions so the  
app can write them.

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 7, 2006, 10:58am UTC](https://www.ruby-forum.com/t/application-error/74289/5 "2006-11-07T10:58:42Z")

</div>

> it? Also, I’ve had problems with log files not having permissions so the  
> app can write them.

Good point there…forgot about that one. It has bitten me a few times.

–  
Andrew S.

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 7, 2006, 10:58am UTC](https://www.ruby-forum.com/t/application-error/74289/6 "2006-11-07T10:58:40Z")

</div>

Check the shebang line in the dispatch.cgi (.fcgi) and make sure it  
points  
to the correct location. A common location is

#!/usr/local/bin/ruby

This will give you the “failed to start…” error.

If you’re running linux can do “which ruby” on the command line to get  
the  
location.

## good luck, andy

Andrew S.

---

<div class="post-metadata">

**Author:** ![Ryan\_Edwards-Crewe](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/59ef9b/32.png) [@Ryan\_Edwards-Crewe](https://www.ruby-forum.com/u/Ryan_Edwards-Crewe)\
**Post date:** [November 7, 2006, 10:59am UTC](https://www.ruby-forum.com/t/application-error/74289/7 "2006-11-07T10:59:25Z")

</div>

also try running dispatch.(f)cgi from the command prompt …

As Cayce wrote, you need more symptoms to debug this problem.

J
