Topic: Error: You dont have permission to access / on this server

I finally got capistrano to successfully deploy my rails app after a few days of messing with it.  Unfortunately, after successfully deploying an app, I tried to fix something on the server and changed the permission of the directories on my web server.  I think I ran this:

chmod -R 0666 /var/www/

All of my websites are under /var/www/, for example, this would be how it looks directory wise: /var/www/mywebsite.com/current

after running that command to change permissions, I now get a webpage that says the following:

Forbidden
You don't have permission to access / on this server.

What can I run to fix this??  I am a total linux noob so please be very clear with the commands to run!!

Thanks again,

br

Re: Error: You dont have permission to access / on this server

Well, its official... This section of the forums is dead.

Re: Error: You dont have permission to access / on this server

well you're in / which is root. I'm not linux/unix pro myself, but obviously everyone else is not supposed to be able to read or execute from root. I'm not sure of the specific command but first I would change the directory to something that would be stemmed off your user account.

This doesn't have to do with a server, but for instance on my computer, I have a user account that isn't a root user, and that displays something like :
bens-macbook-pro:~ user1$      which is the user's directory and home folder if you will. If I type cd / I will then be in the root directory: bens-macbook-pro:/ user1$      I would have my rails apps in a folder branched from ~ , like:
bens-macbook-pro:rails_app user1$      Then view permissions to make sure users can see the apps, I believe this command is ls -ld

but if you have to change permissions at some point, you'll have to change the 'others' group's permissions with a chmod command that you can google for specifications.

here is a resource that should help

Last edited by RailsRhino (2010-06-16 19:57:14)

- Ben