Ok Guys ''n Gals, Here''s a lightweight matter for discussion: I have recently rebuilt my server, specifically to accommodate the deployment of production rails apps. Not a task undertaken lightly to be sure. I still have a sendmail issue or two and a problem with pam/IMAP but nothing that should affect rails, at least at the level at which I am employing it thus far. Here''s what I''ve done: 1. Rebuild server from RH6.2 to FreeBSD 5.3 2. Install apache, rails, mysql, and ruby (of course not in that order LoL) 3. Migrate data from dev db on dev box (OSX) to prod db on prod server (FreeBSD) 4. create project in serverroot on prod box 5. tar up dev project and scp to prod box 6. untar project in the prepared project space on prod server''s serverroot 7. Set up apropos vhost in httpd.conf Here''s the problem: I can get the ruby welcome page, but none of the sub-functions work. I simply get a 404. Nothing appears to be getting written to the logs; I''m off to check ownership vs. perms right now. Anybody wanna jump on this? Thanks! Twitch
You need to make sure mod_rewrite is working. When I installed rails on linux it worked right out of the box, I never messed with mod_rewrite but apache2 was already set up with it (I used gentoo portage to install it). I am not sure if all the linux installs are set up with mod_rewrite. When I installed apache2 on windows it wasn''t set up though. When I saw the 404 error I immediately knew that mod_rewrite was the probable culprit. I had to uncomment the LoadModule directive first. Is there anything in the rails documentation? This aught to be a separate itemized step, to make sure mod_rewrite is installed and functioning. Is there anything that could be put in the .htaccess file to warn the user that mod_rewrite directives are not being understood? By the way James, you should have an error in your error log when you make a request that the mod_rewrite directives (RewriteRule I believe) are not being processed from your .htaccess file in the public directory. -Jeff ----- Original Message ----- From: "James G. Stallings II" <twitch-kuaf+BvAnvdypLqBFPtG/w@public.gmane.org> To: <rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org> Sent: Monday, February 07, 2005 11:25 AM Subject: [Rails] More Stoopid Questions> Ok Guys ''n Gals, > > Here''s a lightweight matter for discussion: > > I have recently rebuilt my server, specifically to accommodate the > deployment of production rails apps. Not a task undertaken lightly to be > sure. I still have a sendmail issue or two and a problem with pam/IMAP but > nothing that should affect rails, at least at the level at which I am > employing it thus far. > > Here''s what I''ve done: > 1. Rebuild server from RH6.2 to FreeBSD 5.3 > 2. Install apache, rails, mysql, and ruby (of course not in that order > LoL) > 3. Migrate data from dev db on dev box (OSX) to prod db on prod server > (FreeBSD) > 4. create project in serverroot on prod box > 5. tar up dev project and scp to prod box > 6. untar project in the prepared project space on prod server''s serverroot > 7. Set up apropos vhost in httpd.conf > > Here''s the problem: > I can get the ruby welcome page, but none of the sub-functions work. > I simply get a 404. Nothing appears to be getting written to the logs; I''m > off to check ownership vs. perms right now. > > Anybody wanna jump on this? > > Thanks! > > Twitch > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails
Thanks for the reply Jeff. I had just recently checked mod rewrite and it is enabled; although the behavior certainly suggests that it is the point of failure. the only error I''m getting in the httpd-error log is: [Mon Feb 7 12:37:17 2005] [error] [client 192.168.1.37] File does not exist: /usr/local/www/cuneiform/public/post/ It does act precisely as if mod_rewrite is nonfunctional. I am digging further now for something more subtle, like a perms prob on the .htaccess file. Thanks! Best Regards, Twitch On Mon, 7 Feb 2005, Jeffrey Moss wrote:> Date: Mon, 7 Feb 2005 11:36:46 -0700 > From: Jeffrey Moss <jeff-61uStg5MtoFWk0Htik3J/w@public.gmane.org> > Reply-To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > Subject: Re: [Rails] More Stoopid Questions > > You need to make sure mod_rewrite is working. When I installed rails on linux > it worked right out of the box, I never messed with mod_rewrite but apache2 > was already set up with it (I used gentoo portage to install it). I am not > sure if all the linux installs are set up with mod_rewrite. When I installed > apache2 on windows it wasn''t set up though. When I saw the 404 error I > immediately knew that mod_rewrite was the probable culprit. I had to uncomment > the LoadModule directive first. > > Is there anything in the rails documentation? This aught to be a separate > itemized step, to make sure mod_rewrite is installed and functioning. Is there > anything that could be put in the .htaccess file to warn the user that > mod_rewrite directives are not being understood? > > By the way James, you should have an error in your error log when you make a > request that the mod_rewrite directives (RewriteRule I believe) are not being > processed from your .htaccess file in the public directory. > > -Jeff > > ----- Original Message ----- From: "James G. Stallings II" > <twitch-kuaf+BvAnvdypLqBFPtG/w@public.gmane.org> > To: <rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org> > Sent: Monday, February 07, 2005 11:25 AM > Subject: [Rails] More Stoopid Questions > > > > Ok Guys ''n Gals, > > > > Here''s a lightweight matter for discussion: > > > > I have recently rebuilt my server, specifically to accommodate the > > deployment of production rails apps. Not a task undertaken lightly to be > > sure. I still have a sendmail issue or two and a problem with pam/IMAP but > > nothing that should affect rails, at least at the level at which I am > > employing it thus far. > > > > Here''s what I''ve done: > > 1. Rebuild server from RH6.2 to FreeBSD 5.3 > > 2. Install apache, rails, mysql, and ruby (of course not in that order > > LoL) > > 3. Migrate data from dev db on dev box (OSX) to prod db on prod server > > (FreeBSD) > > 4. create project in serverroot on prod box > > 5. tar up dev project and scp to prod box > > 6. untar project in the prepared project space on prod server''s serverroot > > 7. Set up apropos vhost in httpd.conf > > > > Here''s the problem: > > I can get the ruby welcome page, but none of the sub-functions work. > > I simply get a 404. Nothing appears to be getting written to the logs; I''m > > off to check ownership vs. perms right now. > > > > Anybody wanna jump on this? > > > > Thanks! > > > > Twitch > > > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
On Mon, 7 Feb 2005 11:36:46 -0700, Jeffrey Moss <jeff-61uStg5MtoFWk0Htik3J/w@public.gmane.org> wrote:> You need to make sure mod_rewrite is working. When I installed rails on > linux it worked right out of the box, I never messed with mod_rewrite but > apache2 was already set up with it (I used gentoo portage to install it). I > am not sure if all the linux installs are set up with mod_rewrite. When I > installed apache2 on windows it wasn''t set up though. When I saw the 404 > error I immediately knew that mod_rewrite was the probable culprit. I had to > uncomment the LoadModule directive first. > > Is there anything in the rails documentation? This aught to be a separate > itemized step, to make sure mod_rewrite is installed and functioning. Is > there anything that could be put in the .htaccess file to warn the user that > mod_rewrite directives are not being understood? > > By the way James, you should have an error in your error log when you make a > request that the mod_rewrite directives (RewriteRule I believe) are not > being processed from your .htaccess file in the public directory. > > -Jeff >You might also just verify that the .htaccess file was copied as well given that it''s a "hidden" file on *nix systems, it''s fairly easy to lose track of.
On Mon, 7 Feb 2005, Tanner Burson wrote:> Date: Mon, 7 Feb 2005 12:43:03 -0600 > From: Tanner Burson <tanner.burson-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> > To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > Subject: Re: [Rails] More Stoopid Questions > > On Mon, 7 Feb 2005 11:36:46 -0700, Jeffrey Moss <jeff-61uStg5MtoFWk0Htik3J/w@public.gmane.org> wrote: > > You need to make sure mod_rewrite is working. When I installed rails on > > linux it worked right out of the box, I never messed with mod_rewrite but > > apache2 was already set up with it (I used gentoo portage to install it). I > > am not sure if all the linux installs are set up with mod_rewrite. When I > > installed apache2 on windows it wasn''t set up though. When I saw the 404 > > error I immediately knew that mod_rewrite was the probable culprit. I had to > > uncomment the LoadModule directive first. > > > > Is there anything in the rails documentation? This aught to be a separate > > itemized step, to make sure mod_rewrite is installed and functioning. Is > > there anything that could be put in the .htaccess file to warn the user that > > mod_rewrite directives are not being understood? > > > > By the way James, you should have an error in your error log when you make a > > request that the mod_rewrite directives (RewriteRule I believe) are not > > being processed from your .htaccess file in the public directory. > > > > -Jeff > > > > You might also just verify that the .htaccess file was copied as well > given that it''s a "hidden" file on *nix systems, it''s fairly easy to > lose track of. > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Sorry about that last one - me and pine dont get along so well. ANYway, I just checked perms and contents of .htaccess; nothing amiss there. I''m kinda stumped for the moment. Do I have to use rails to generate the models/views/controllers or can they just be supplied from the tarfile? Thnx James
Make sure allowoverride all is in your <Directory> or <VirtualHost> section in httpd.conf, otherwise it wont even look for a .htaccess. -Jeff ----- Original Message ----- From: "James G. Stallings II" <twitch-kuaf+BvAnvdypLqBFPtG/w@public.gmane.org> To: <rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org> Sent: Monday, February 07, 2005 11:41 AM Subject: Re: [Rails] More Stoopid Questions> > Thanks for the reply Jeff. > > I had just recently checked mod rewrite and it is enabled; although the > behavior certainly suggests that it is the point of failure. > > the only error I''m getting in the httpd-error log is: > [Mon Feb 7 12:37:17 2005] [error] [client 192.168.1.37] File does not > exist: /usr/local/www/cuneiform/public/post/ > > It does act precisely as if mod_rewrite is nonfunctional. > > I am digging further now for something more subtle, like a perms prob on > the .htaccess file. > > Thanks! > > Best Regards, > Twitch > > On Mon, 7 Feb 2005, Jeffrey Moss wrote: > >> Date: Mon, 7 Feb 2005 11:36:46 -0700 >> From: Jeffrey Moss <jeff-61uStg5MtoFWk0Htik3J/w@public.gmane.org> >> Reply-To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> Subject: Re: [Rails] More Stoopid Questions >> >> You need to make sure mod_rewrite is working. When I installed rails on >> linux >> it worked right out of the box, I never messed with mod_rewrite but >> apache2 >> was already set up with it (I used gentoo portage to install it). I am >> not >> sure if all the linux installs are set up with mod_rewrite. When I >> installed >> apache2 on windows it wasn''t set up though. When I saw the 404 error I >> immediately knew that mod_rewrite was the probable culprit. I had to >> uncomment >> the LoadModule directive first. >> >> Is there anything in the rails documentation? This aught to be a separate >> itemized step, to make sure mod_rewrite is installed and functioning. Is >> there >> anything that could be put in the .htaccess file to warn the user that >> mod_rewrite directives are not being understood? >> >> By the way James, you should have an error in your error log when you >> make a >> request that the mod_rewrite directives (RewriteRule I believe) are not >> being >> processed from your .htaccess file in the public directory. >> >> -Jeff >> >> ----- Original Message ----- From: "James G. Stallings II" >> <twitch-kuaf+BvAnvdypLqBFPtG/w@public.gmane.org> >> To: <rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org> >> Sent: Monday, February 07, 2005 11:25 AM >> Subject: [Rails] More Stoopid Questions >> >> >> > Ok Guys ''n Gals, >> > >> > Here''s a lightweight matter for discussion: >> > >> > I have recently rebuilt my server, specifically to accommodate the >> > deployment of production rails apps. Not a task undertaken lightly to >> > be >> > sure. I still have a sendmail issue or two and a problem with pam/IMAP >> > but >> > nothing that should affect rails, at least at the level at which I am >> > employing it thus far. >> > >> > Here''s what I''ve done: >> > 1. Rebuild server from RH6.2 to FreeBSD 5.3 >> > 2. Install apache, rails, mysql, and ruby (of course not in that order >> > LoL) >> > 3. Migrate data from dev db on dev box (OSX) to prod db on prod server >> > (FreeBSD) >> > 4. create project in serverroot on prod box >> > 5. tar up dev project and scp to prod box >> > 6. untar project in the prepared project space on prod server''s >> > serverroot >> > 7. Set up apropos vhost in httpd.conf >> > >> > Here''s the problem: >> > I can get the ruby welcome page, but none of the sub-functions work. >> > I simply get a 404. Nothing appears to be getting written to the logs; >> > I''m >> > off to check ownership vs. perms right now. >> > >> > Anybody wanna jump on this? >> > >> > Thanks! >> > >> > Twitch >> > >> > _______________________________________________ >> > Rails mailing list >> > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> > http://lists.rubyonrails.org/mailman/listinfo/rails >> >> _______________________________________________ >> Rails mailing list >> Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org >> http://lists.rubyonrails.org/mailman/listinfo/rails >> > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails