Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 11th May 2006, 15:13
latcarf latcarf is offline
Senior Member
 
Join Date: Jul 2005
Posts: 215
Thanks: 0
Thanked 1 Time in 1 Post
Default vsftp - 550 Failed to change directory

I have been running an anonymous ftp for some time and all of a sudden any files recently added give a "550 Failed to change directory" when I or anyone else try to download them.

I just discovered this when someone sent me a file to place on my ftp then they tried to download it after. Files seem to be uploading fine and any files previously put out there seem to be downloading okay.

I have not opened the config file in some time, wasn't broke so there was no reason to fix it!

Anyone have an idea why this is happening?
Reply With Quote
Sponsored Links
  #2  
Old 11th May 2006, 17:07
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,745 Times in 2,578 Posts
Default

Are there errors related to this in your logs?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #3  
Old 11th May 2006, 22:51
latcarf latcarf is offline
Senior Member
 
Join Date: Jul 2005
Posts: 215
Thanks: 0
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by falko
Are there errors related to this in your logs?
Hi Falko,

After some more investigation I found out that when anonymous users upload a file the files are "owned" by the user group ftp and it is only assigning rw permissions to the file. I assume all I need to do is either, 1) change the user group "ftp", or 2) change the config file, or both!

Tips and hints are welcome!
Reply With Quote
  #4  
Old 12th May 2006, 11:02
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,745 Times in 2,578 Posts
Default

What's in your /etc/vsftpd.conf?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #5  
Old 12th May 2006, 14:34
latcarf latcarf is offline
Senior Member
 
Join Date: Jul 2005
Posts: 215
Thanks: 0
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by falko
What's in your /etc/vsftpd.conf?
Here is the config file
Code:
# Standalone mode
listen=YES
max_clients=200
max_per_ip=4
# Access rights
anonymous_enable=YES
local_enable=NO
write_enable=YES
anon_upload_enable=YES
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
# Security
anon_world_readable_only=YES
connect_from_port_20=YES
hide_ids=YES
pasv_min_port=50000
pasv_max_port=60000
# Features
xferlog_enable=YES
ls_recurse_enable=NO
ascii_download_enable=NO
async_abor_enable=YES
# Performance
one_process_model=YES
idle_session_timeout=120
data_connection_timeout=300
accept_timeout=60
connect_timeout=60
anon_max_rate=50000
I wonder if this line anon_other_write_enable=NO was changed to YES if that would do the trick? Note it is not running xinetd...
Reply With Quote
  #6  
Old 12th May 2006, 21:36
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,745 Times in 2,578 Posts
Default

I'd change

Code:
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
to YES and try again (restart vsftpd).
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #7  
Old 12th May 2006, 22:32
latcarf latcarf is offline
Senior Member
 
Join Date: Jul 2005
Posts: 215
Thanks: 0
Thanked 1 Time in 1 Post
Default

Quote:
Originally Posted by falko
I'd change

Code:
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
to YES and try again (restart vsftpd).
I gave that a shot and the error message changed from "550 Failed to change directory" to "550 Failed to open file" plus it gave anon users the ability to delete files which is a no-no. After changing the config and restart I passed a doc to the ftp and then tried to download it from the ftp. Here is the log showing the transactions...
Code:
Fri May 12 14:55:31 2006 [pid 10277] CONNECT: Client "192.168.2.4"
Fri May 12 14:55:31 2006 [pid 10277] [ftp] OK LOGIN: Client "192.168.2.4", anon password "wsftp605@"
Fri May 12 14:55:45 2006 [pid 10277] [ftp] FAIL UPLOAD: Client "192.168.2.4", "/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 14:55:54 2006 [pid 10277] [ftp] OK UPLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 10761 bytes, 44.52Kbyte/sec
Fri May 12 14:56:06 2006 [pid 10277] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 14:56:29 2006 [pid 10277] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 14:56:32 2006 [pid 10277] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 14:56:52 2006 [pid 10277] [ftp] OK DOWNLOAD: Client "192.168.2.4", "/HowTo's/FunkyFlames.pdf", 509784 bytes, 55.78Kbyte/sec
Fri May 12 14:56:55 2006 [pid 10277] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:06:47 2006 [pid 5699] CONNECT: Client "192.168.2.4"
Fri May 12 15:06:47 2006 [pid 5699] [ftp] OK LOGIN: Client "192.168.2.4", anon password "wsftp605@"
Fri May 12 15:06:50 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:07:22 2006 [pid 5699] [ftp] OK DELETE: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG"
Fri May 12 15:07:30 2006 [pid 5699] [ftp] OK UPLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 10965 bytes, 47.44Kbyte/sec
Fri May 12 15:07:39 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:07:48 2006 [pid 5699] [ftp] OK DELETE: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG"
Fri May 12 15:08:00 2006 [pid 5699] [ftp] OK UPLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 11067 bytes, 47.35Kbyte/sec
Fri May 12 15:08:08 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:08:15 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:08:16 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:08:18 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG", 0.00Kbyte/sec
Fri May 12 15:08:26 2006 [pid 5699] [ftp] OK DELETE: Client "192.168.2.4", "/HowTo's/WS_FTP.LOG"
Fri May 12 15:09:10 2006 [pid 5699] [ftp] OK UPLOAD: Client "192.168.2.4", "/Scripts/WS_FTP.hlp", 246726 bytes, 48.46Kbyte/sec
Fri May 12 15:09:17 2006 [pid 5699] [ftp] FAIL DOWNLOAD: Client "192.168.2.4", "/Scripts/WS_FTP.hlp", 0.00Kbyte/sec
Fri May 12 15:09:26 2006 [pid 5699] [ftp] OK DELETE: Client "192.168.2.4", "/Scripts/WS_FTP.hlp"
Reply With Quote
  #8  
Old 13th May 2006, 12:36
falko falko is offline
Super Moderator
 
Join Date: Apr 2005
Location: Lüneburg, Germany
Posts: 41,701
Thanks: 1,900
Thanked 2,745 Times in 2,578 Posts
Default

Can you try
Code:
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
# Security
anon_world_readable_only=NO
then?
__________________
Falko
--
Download the ISPConfig 3 Manual! | Check out the ISPConfig 3 Billing Module!

FB: http://www.facebook.com/howtoforge

nginx-Webhosting: Timme Hosting | Follow me on:
Reply With Quote
  #9  
Old 14th May 2006, 02:05
latcarf latcarf is offline
Senior Member
 
Join Date: Jul 2005
Posts: 215
Thanks: 0
Thanked 1 Time in 1 Post
 
Default

Quote:
Originally Posted by falko
Can you try
Code:
anon_mkdir_write_enable=NO
anon_other_write_enable=NO
# Security
anon_world_readable_only=NO
then?
cool beans! that worked!! I feel a little embarassed since I did not see that anon line in security...

thanks for the help!
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

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 On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Mysterious Install Problem tgansert Installation/Configuration 5 9th May 2006 15:35
How to install BFD (Brute Force Detection) domino Tips/Tricks/Mods 9 31st March 2006 22:40
setup fails on debian 3.1 dtrumbower Installation/Configuration 7 7th March 2006 13:42
Update to 2.2.0 question brianetilley Installation/Configuration 10 4th March 2006 17:02
ISP install problems Debian sarge 3.1 lerra Installation/Configuration 1 5th January 2006 16:37


All times are GMT +2. The time now is 02:42.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.