Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!


Shells Virtual Desktop
BMail.ag - Secure Email Service
Server.net
CPLicense.net
VPS Server
Buy VPN
Vultr
VMs for AI
HostDare
HostDare
ReliableSite White-Label Dedicated Hosting for Resellers
25% Recurring Discount on NVMe VPS
InterServer VPS
BMail.ag - Secure Email Service
Best VPN
High-Performance Bare Metal Server Solutions
Karvl.com
Server Mania Cloud Hosting
DataWagon Hosting
AlphaVPS Hosting
Evoxt.com
Clouvider
VPS Hosting with NVMe
Residential IPs in the US & 4G Mobile Proxies in EU & US with Unlimited Bandwidth
ReliableSite White-Label Dedicated Hosting for Resellers
Rabisu - Hosting Solutions
Shells Virtual Desktop

In this Discussion

New on LowEndTalk? Please Register and read our Community Rules.

All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

553 error with vsftpd

khavkhav Member

I am scratching my head for hours trying to solve this.I can login in ftp just fine but i get the infamous 553 Could not create file. when i try to upload/create files.

Here is what i did

setsebool -P ftp_home_dir on

chown -R $ftp_user /var/www/$domain/public_html/www/

Here is my config

cat /etc/vsftpd/vsftpd.conf | grep -v ^#

anonymous_enable=NO

local_enable=YES

write_enable=YES

local_umask=022

dirmessage_enable=YES

xferlog_enable=YES

connect_from_port_20=YES

xferlog_std_format=YES

ascii_upload_enable=YES

ascii_download_enable=YES

ftpd_banner=Welcome to servergreek FTP service.

chroot_local_user=YES

listen=YES

cat /etc/passwd

$ftp_user:x:500:500::/var/www/$domain/public_html/www:/bin/bash

cat /var/log/xferlog

Sat Mar 15 07:34:33 2014 1 server_ip 0 /file_to_upload.txt b _ i r $ftp_user ftp 0 * i

I would be really thankful if someone could help me solve this

Comments

  • sleddogsleddog Member
    edited March 2014

    To help narrow the problem, I would test first with selinux disabled, then with chroot_local_user disabled.

    vsftpd should be logging its activity (not just xfers). If not you can change the logging config to:

    xferlog_std_format=YES
    dual_log_enable=YES
    vsftpd_log_file=/var/log/vsftpd.log
    xferlog_file=/var/log/xferlog

    /var/log/vsftpd.log should have clues as to what's happening.

  • khavkhav Member

    couldn't find /var/log/vsftpd.log :(

  • khavkhav Member

    @sleddog i will add the lines to the logging config and report back

    Ty

  • khavkhav Member
    edited March 2014

    /var/log/vsftpd.log
    Sat Mar 15 10:02:24 2014 [pid 12299] CONNECT: Client "server_ip"
    Sat Mar 15 10:02:25 2014 [pid 12298] [servergreek] OK LOGIN: Client "server_ip"
    Sat Mar 15 10:02:27 2014 [pid 12303] [servergreek] FAIL UPLOAD: Client "", "server_ip/nginx.sh", 0.00Kbyte/sec

    Really disappointed with the logs lolz

    Update
    I was able to fix it by disabling selinux.
    why is setsebool -P ftp_home_dir on not doing the trick
    Am i missing something??

  • khavkhav Member
    edited March 2014

    Fixed it .....ftp needed additional power:P

    `setsebool -P ftp_home_dir on`
    `setsebool -P allow_ftpd_full_access 1`
    

    Just needed to execute these 2 commands above to fix the ftp

    Hope this helps someone:)

  • Glad to hear you got it resolved :)

  • khavkhav Member

    @sleddog thanks for you input about logs files , it does come in handy for debugging

    I can't believe i took like 2hr to fix setup and fix ftp:P

    LET community seems pretty knowledgeable and full of greeks:)

    Glad to be part of the community

Sign In or Register to comment.