problem of uploading webpage with ftp

Discussion regarding the installation and configuration of Linux distributions.
Post Reply
fahadul
Cadet
Posts: 4
Joined: Thu Jul 17, 2008 9:46 pm
Location: Bangladesh
Contact:

problem of uploading webpage with ftp

Post by fahadul »

i install in a Redhat enterprise 3 es webserver(Apache)and i want to give access with ftp to a user for uploading,deleting privilage to /var/www/html/ directory only .plz tell me the prosedure.
Fahadul haque
LinuxFreaK
Site Admin
Posts: 5132
Joined: Fri May 02, 2003 10:24 am
Location: Karachi
Contact:

Re: problem of uploading webpage with ftp

Post by LinuxFreaK »

Dear fahadul,
Salam,
fahadul wrote:i install in a Redhat enterprise 3 es webserver(Apache)and i want to give access with ftp to a user for uploading,deleting privilage to /var/www/html/ directory only .plz tell me the prosedure.
You can not login into FTP Server as "root". The directory which you have mentioned is owned by root. So, you can not upload any thing in this folder due to privileges.

Best Regards.
Farrukh Ahmed
x2oxen
Major General
Posts: 1114
Joined: Wed Aug 22, 2007 3:17 pm
Location: Faisalabad
Contact:

Post by x2oxen »

create a new user with the home directory of path which you want to give access to user. set some permissions and ask ur buddy to login with that new user name.
Muhammad Usman
+92-321-6640501
Chemonics International
http://usmanpk.com
shahzor
Naik
Posts: 72
Joined: Thu Jun 29, 2006 11:33 am
Location: Quetta
Contact:

Post by shahzor »

and also get your user under chroot jail
LinuxBoy
ranatanveer
Subedar
Posts: 355
Joined: Sat May 07, 2005 11:54 am
Location: Lahore
Contact:

Post by ranatanveer »

Hi Fahad,

if you dont yet get, Do the following

Code: Select all

useradd -G root ftpuser
passwd ftpuser

now edit the /etc/passwd like

Code: Select all

ftpuser:x:51:51::/var/www/html:/sbin/nologin

Code: Select all

chmod 2775 /var/www/html 
try to connect ftp and upload files.

last thing is ur firewall, open up port 21 and passive ports ( > 1024)
you can also open selected passive ports, google out it.
Regards

Rana Tanveer
+923224194457
Linux Student

For Affordable Web Development http://www.affordableprogrammers.com
http://www.qualityprogrammers.com
xeon
Cadet
Posts: 10
Joined: Tue Feb 24, 2009 9:02 pm
Location: Pakistan
Contact:

As Salamo Alekum

Post by xeon »

You should check this URL there is complete solution.

http://www.linuxhomenetworking.com/wiki ... rver_Setup

Regards,
Asif Ali
Pink Link Network
+92-333-7849320
www.pinklinknetwork.com
Post Reply