Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

how to start with my site?

Ask for help with issues regarding the Installations of the Debian O/S.
Post Reply
Message
Author
jrahma
Posts: 81
Joined: 2011-10-17 07:59

how to start with my site?

#1 Post by jrahma »

Hi,

I have just installed debian server and it works great :)

I would like to know now how to start with my local website?

where to place the php files (website)?

I tried browsing to my IP and got the following:
It works!

This is the default web page for this server.

The web server software is running but no content has been added, yet.
and I want to replace that with my files.

kindly assist....


Thanks,
Jassim

User avatar
dilberts_left_nut
Administrator
Administrator
Posts: 5347
Joined: 2009-10-05 07:54
Location: enzed
Has thanked: 13 times
Been thanked: 66 times

Re: how to start with my site?

#2 Post by dilberts_left_nut »

AdrianTM wrote:There's no hacker in my grandma...

jrahma
Posts: 81
Joined: 2011-10-17 07:59

Re: how to start with my site?

#3 Post by jrahma »

Hi,

I got it but I now have another problem. I am unable to write anything there

I am getting Permission Denied when tryi9ng to copy my files.

User avatar
dilberts_left_nut
Administrator
Administrator
Posts: 5347
Joined: 2009-10-05 07:54
Location: enzed
Has thanked: 13 times
Been thanked: 66 times

Re: how to start with my site?

#4 Post by dilberts_left_nut »

You need to be a user that has write permissions to the dir you are trying to put files into.
Probably change ownership or group of the dir to suit.
Note that the www-data user needs read access to be able to display the files - usually not write access, for security.
AdrianTM wrote:There's no hacker in my grandma...

jrahma
Posts: 81
Joined: 2011-10-17 07:59

Re: how to start with my site?

#5 Post by jrahma »

How?

I am new to Debian

I have installed a fresh server and during the installation I set the user as mesk. This should be my root, right?

User avatar
dilberts_left_nut
Administrator
Administrator
Posts: 5347
Joined: 2009-10-05 07:54
Location: enzed
Has thanked: 13 times
Been thanked: 66 times

Re: how to start with my site?

#6 Post by dilberts_left_nut »

AdrianTM wrote:There's no hacker in my grandma...

jrahma
Posts: 81
Joined: 2011-10-17 07:59

Re: how to start with my site?

#7 Post by jrahma »

Hi,

It works. Thanks.

Last Question -- hopefully :) ---

Why I am getting:
Forbidden
You don't have permission to access /mesk/ on this server.
when trying to browse my files at var/www/mesk folder using http://my_ip/mesk?

User avatar
dilberts_left_nut
Administrator
Administrator
Posts: 5347
Joined: 2009-10-05 07:54
Location: enzed
Has thanked: 13 times
Been thanked: 66 times

Re: how to start with my site?

#8 Post by dilberts_left_nut »

Probably the www-data user doesn't have read permissions to the dir, or the vhost definition is denying access based on your connecting IP - the logfile (in /var/log/apache2/) should make clear which (probably the first).
AdrianTM wrote:There's no hacker in my grandma...

jrahma
Posts: 81
Joined: 2011-10-17 07:59

Re: how to start with my site?

#9 Post by jrahma »

Hi,

I found this:
usermod -a -G www-data (your username)
chgrp www-data /home/myuser/folderA
chmod g+rwxs /home/myuser/folderA
but is this for root or mesk?

because the file is var/www/mesk (mesk is a folder not user)

User avatar
koanhead
Posts: 109
Joined: 2013-06-20 16:54

Re: how to start with my site?

#10 Post by koanhead »

jrahma wrote:
usermod -a -G www-data (your username)
chgrp www-data /home/myuser/folderA
chmod g+rwxs /home/myuser/folderA
but is this for root or mesk?
because the file is var/www/mesk (mesk is a folder not user)
The question doesn't make sense, because "root" is the root user, and as you say, "mesk" is a directory and not a user.

`usermod` adds a user to a group.
`chgrp` changes the group ownership of a file- in your example, it makes /home/myuser/folderA belong to group www-data.
`chmod` changes the permission settings of a file- in your example it makes /home/myuser/folderA readable, writable, and executable by its owning group, and sets the sticky bit.

Post Reply