LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-02-2009, 04:29 AM   #1
dshap
LQ Newbie
 
Registered: May 2009
Posts: 7

Rep: Reputation: 0
FTP client can't access files in /var/www/html (Apache )


I'm running CentOS 5.3 and I have pure-ftpd as my FTP server. I'm using the FlashFXP FTP client on Windows and I'm trying to access files on my server. Every file I've tried to access has worked fine except the files in the Apache /www/html folder. FlashFXP just says "Unable to open specified file." My guess is that this is some kind of file permission issue or maybe an Apache configuration issue that I'm not aware of.

Obviously I'm very new to Linux/Apache and if anyone could shed some light on this issue I'd appreciate it very much.

Thanks.

- dshap
 
Old 06-02-2009, 05:06 AM   #2
LaroPol
LQ Newbie
 
Registered: Aug 2008
Location: Belgium
Distribution: debian, (open)suse, ubuntu, ...aix..
Posts: 15

Rep: Reputation: 1
do a

ls -l /www/ | grep html

look at the permissions.
Does the user (you are using to ftp) have permissions to that folder ?
 
Old 06-02-2009, 05:41 AM   #3
dshap
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by LaroPol View Post
do a

ls -l /www/ | grep html

look at the permissions.
Does the user (you are using to ftp) have permissions to that folder ?
Thanks for the reply. I'm not sure where I should enter this command. I've tried it in numerous directories and I always get "ls: /www/: No such file or directory".

The user I am using to FTP is "root" which I thought had permission to everything - is this not true?

Please let me know where I should enter that command so that I can see what the problem is.

Thanks.
 
Old 06-02-2009, 07:50 PM   #4
chrism01
LQ Guru
 
Registered: Aug 2004
Location: Sydney
Distribution: Centos 6.8, Centos 5.10
Posts: 17,240

Rep: Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324Reputation: 2324
That's because your title says /var/www (which I'd expect on centos) ..
 
Old 06-02-2009, 08:58 PM   #5
dshap
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by chrism01 View Post
That's because your title says /var/www (which I'd expect on centos) ..
Sorry about that, my bad.

[root@localhost /]# ls -l /var/www/ | grep html
drwxr-xr-x 4 root root 4096 Jun 2 01:18 html


Does this output indicate that I wouldn't be able to view/edit files with the "root" FTP account? If so, how can I change that?

Thanks.
 
Old 06-03-2009, 01:30 AM   #6
rikxik
Member
 
Registered: Dec 2007
Posts: 88

Rep: Reputation: 19
The file permissions on html directory mean that the files can be edited by "root" user and everyone else can only read them. So in short, you should be able to edit them provided the individual files in this html directory are writable.

Post output of:

Code:
ls -la /var/www/html
 
Old 06-03-2009, 02:30 AM   #7
dshap
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by rikxik View Post
The file permissions on html directory mean that the files can be edited by "root" user and everyone else can only read them. So in short, you should be able to edit them provided the individual files in this html directory are writable.

Post output of:

Code:
ls -la /var/www/html
Okay your post got me thinking...I tried a different FTP client made by SSH Secure Shell and it let me edit the files. Why would this be? I'd like to use FlashFXP. FlashFXP can edit any files OTHER than the html directory files it seems.

Here is the output you asked for:

Code:
[root@localhost /]# ls -la /var/www/html
total 40
drwxr-xr-x  4 root root 4096 Jun  2 01:18 .
drwxr-xr-x  8 root root 4096 May 28 09:54 ..
-rwxr-xr-x  1 root root 5747 Dec 29 10:21 atomic-release-1.0-10.el5.art.noarch.rpm
-rwxr-xr-x  1 root root   35 May 29 22:51 index.php
drwxr-xr-x 10 root root 4096 Jun  2 01:19 phpMyAdmin
drwxr-xr-x 11 root root 4096 Jun  2 00:52 phpPgAdmin
-rwxr-xr-x  1 root root 1344 Nov  8  2004 RPM-GPG-KEY.art.txt
Thanks.
 
Old 06-03-2009, 02:42 AM   #8
rikxik
Member
 
Registered: Dec 2007
Posts: 88

Rep: Reputation: 19
Doesn't make any sense to me - changing ftp clients shouldn't make any difference in basic get/put operations. Btw, what you mean exactly by "edit"? You are doing a "put" to /var/www/html?

It would be useful if you can cut/paste the output generated by your ftp client - that'll let us see exactly what your inputs are and the output from the session.
 
Old 06-03-2009, 01:12 PM   #9
dshap
LQ Newbie
 
Registered: May 2009
Posts: 7

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by rikxik View Post
Doesn't make any sense to me - changing ftp clients shouldn't make any difference in basic get/put operations. Btw, what you mean exactly by "edit"? You are doing a "put" to /var/www/html?

It would be useful if you can cut/paste the output generated by your ftp client - that'll let us see exactly what your inputs are and the output from the session.
You know what? I'm an idiot.

I'm on a new computer and I just copied over all of my FlashFXP settings from my old computer and the client is configured to open .php files with an editor that doesn't exist on my new computer. That's what "FlashFXP cannot open this file" means. I should have tried more file types which is why, as I said before, I am an idiot.

I appreciate all of your help, as always.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Symbolic Link For FTP Access To /var/www/html ERRRRRRRRRRRR! JustinK101 Linux - Software 3 01-31-2007 12:32 PM
How do I give access to an ftp user to the var/www/html dir shootinstr8 Linux - Newbie 1 10-13-2006 04:32 AM
apache server setup and how to place files in the var/www/html directory dramous Linux - Newbie 7 09-28-2004 05:18 AM
apache server setup and how to place files in the var/www/html directory dramous Linux - Software 3 09-25-2004 03:38 AM
apache server setup and how to place files in the var/www/html directory dramous Linux - General 2 09-25-2004 02:29 AM


All times are GMT -5. The time now is 03:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration