Solved

FTP problem

Posted on 2001-07-10
13
166 Views
Last Modified: 2010-03-18
I have set up an FTP account so I can post files to my Apache folder at /var/www/html but when I try
to upload a page, or rename a file I get Permission Denied.

If I use WebAdmin then I can go to the folder and do what I like.

Any suggestions as to what needs to be changed and where?

Richard.H
0
Comment
Question by:RICHARDH
  • 5
  • 5
  • 2
  • +1
13 Comments
 
LVL 17

Accepted Solution

by:
psimation earned 50 total points
ID: 6270253
You almost certainly have a user/permission problem.
Now, when you created the /var/www/html folder ( or if it was created by the system at install), as what user did you create it, ie, when you issued the command mkdir /var/www/html, as which user did you do it? (if the folder was created by the system, then it is almost certainly owned by "root" and will NOT allow any other user to enter it, except if you change the permissions to it.
A "cleaner" way would be to do the following.
Seeing that it is a bad idea to ftp or telnet or even ssh into a system directly as root, I would suggest you create a user for doing your web related things.
So, create a user called webmaster for instance, with which you will log into the system when you want to upload files to the webfolder. Further, make the default home folder for the webmaster user the /var/www/html folder.
To do this, issue the following commands as root.
adduser -d /var/www/html webmaster
passwd webmaster
(supply passwd twice for confirmation)
Now, just to make 100% sure that the entire /var/www/html folder and all it's contents are owned by webmaster, issue the following command as root.
chown -R webmaster:webmaster /var/www/html
chmod -R 755 /var/www/html
Now, when next you ftp into your server as user webmaster with password as you supplied, you should go directly into that folder and will be able to upload and if Apache is configured correctly, you will be able to view the pages on the internet immediately after uploading.
0
 

Author Comment

by:RICHARDH
ID: 6272134
Thanks for the help, will try all this and see what happens.

You did not say anything in the message about setting up an ftp account on the FTP sefver. Do I have to do anything with that.

Regards

Richard.
0
 
LVL 17

Expert Comment

by:psimation
ID: 6272233
That's what's nice about Linux, setting up a normal Linux user automatically sets up an "ftp" user. Actually it's not like there are 2 users now, one system and one ftp, they are both the same thing. The ftp daemon uses the systems passwd db to check for authentication.
0
 
LVL 14

Expert Comment

by:xberry
ID: 6274233
to ' psimation ' :

Hi ' psi ',

kindly asking you for giving advice  to ' nagasrinivas ' in the linux printing topic area:
http://www.experts-exchange.com/jsp/qShow.jsp?ta=linuxprinting&qid=20144008

To his previous Samba setup question I already gave srinivas the address of your Linuxhelp website.
Also I've already told him where to find the specific SMB HOWTOS. Still he doesn't know how to
get pages from within his Linux applications sent to & printed out on his Windows-Networkprinter.
Myself I do only have some experience with printing from Linux desktops but can't give explicit advice
if Samba-Networking is involved. You seem to be an expert for that.    
0
 
LVL 17

Expert Comment

by:psimation
ID: 6274559
Hi Xberry
Ok, I will go there and see what I can help with.
(thanks for the advertising ;) )
0
 
LVL 14

Expert Comment

by:xberry
ID: 6274575
Thank you (!) :-)
0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 17

Expert Comment

by:psimation
ID: 6274589
Xberry
OK, I've just posted a comment there that should have him printing all his ink out in no time.
Where are you BTW? Europe? Your response is fairly quick!
0
 

Expert Comment

by:amp072397
ID: 6782317
RICHARDH:

You have many open questions:

http://www.experts-exchange.com/jsp/qShow.jsp?qid=11342298
http://www.experts-exchange.com/jsp/qShow.jsp?qid=11355858
http://www.experts-exchange.com/jsp/qShow.jsp?qid=11382838
http://www.experts-exchange.com/jsp/qShow.jsp?qid=11415199
http://www.experts-exchange.com/jsp/qShow.jsp?qid=11670638
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20001107
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20004454
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20065368
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20073152
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20084825
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20084821
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20086663
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20086784
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20107892
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20109405
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20109357
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20109887
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20110886
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20117400
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20118020
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20118934
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20118648
http://www.experts-exchange.com/jsp/qShow.jsp?qid=11342618
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20130049
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20132692
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20142937
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20146293
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20147289
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20148615
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20149087
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20148609
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20150501
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20150630
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20154720
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20154865
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20154980
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20155947
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20180018
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20189434
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20193459
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20222409
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20235436
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20244279
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20244276
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20193051
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20256056
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20257136
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20257135
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20127746
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20259971
http://www.experts-exchange.com/jsp/qShow.jsp?qid=20259964

To assist you in your cleanup, I'm providing the following guidelines:

1.  Stay active in your questions and provide feedback whenever possible. Likewise, when feedback has not been provided by the experts, commenting again makes them receive an email notification, and they may provide you with further information. Experts have no other method of searching for questions in which they have commented, except manually.

2.  Award points by hitting the Accept Comment As Answer button located above and to the left of that expert's comment.

3.  When grading, be sure to read:
http://www.experts-exchange.com/jsp/cmtyQuestAnswer.jsp#3
to ensure that you understand the grading system here at EE. If you grade less than an A, you must explain why.

4.  Questions that were not helpful to you should be PAQ'd (stored in the database for their valuable content?even if not valuable to you) or deleted. To PAQ or delete a question, you must first post your intent in that question to make the experts aware. Then, if no experts object after three full days, you can post a zero-point question at community support to request deletion or PAQ. Please include the link(s) to the question(s).
CS:  http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt
At that point, a moderator can refund your points and PAQ or delete the question for you. The delete button does not work.

5.  If you fail to respond to this cleanup request, I must report you to the Community Support Administrator for further action.

Our intent is to get the questions cleaned up, and not to embarrass or shame anyone. If you have any questions or need further assistance at all, feel free to ask me in this question or post a zero-point question at CS. We are very happy to help you in this task!


thanks!
amp
community support moderator

1/27
0
 
LVL 14

Expert Comment

by:xberry
ID: 6782955
Hi Psi,

> Where are you BTW? Europe?

Yes, I'm in Europe.
Sorry, but two months ago I didn't receive e-mail notifications from quite a many postings, so only today I discovered your little comment.

> Your response is fairly quick !

May I take it as an indicator that you're resident in Europe, too ?
BTW, did the questioner that you helped with in the linuxprinting
TA already finalize his Q & grade your Comment ?


0
 
LVL 17

Expert Comment

by:psimation
ID: 6784937
Hi Xberry
No problem, have had a few mail probs myself...

I'm from South Africa (southern europe he he he); regarding the printing question; I have no idea whether that ever got closure, was too long ago...
0
 
LVL 14

Expert Comment

by:xberry
ID: 6785109
> I'm from South Africa (southern europe he he he)

Exactly !  Zoom factor on.

> regarding the printing question . . . too long ago

Well time has at least two ends, if you're thinking in linear succession . . .
& problems seem to be existent unless they are solved or turn into anything else, for the better.
So right now EE fairly seems  to resemble the model of an expanding universe as far as
open Q's are concerned.

So I'll look & see which way the Question went





 
0
 

Author Comment

by:RICHARDH
ID: 6790865
Sorry for the delay in crediting.
Thanks for the help.
Problem now solved.

Richard
0
 
LVL 14

Expert Comment

by:xberry
ID: 6791359
Hi Richard,

thanks for grading psimations answer.
You're welcome.

Regards,

xberry

(I'm not a moderator ; )
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
Note: for this to work properly you need to use a Cross-Over network cable. 1. Connect both servers S1 and S2 on the second network slots respectively. Note that you can use the 1st slots but usually these would be occupied by the Service Provide…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Illustrator's Shape Builder tool will let you combine shapes visually and interactively. This video shows the Mac version, but the tool works the same way in Windows. To follow along with this video, you can draw your own shapes or download the file…

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now