доступность локального репозитория по FTP

igorprint

New member
Сообщения
5
#1
Здравствуйте, решил создать собственный репозиторий с помощью apt-mirror
c apt-mirror - все ОК.
А вот как раздать его с помощью vsftpd - не получается в чем подвох (550 Failed to change directory.)
делаю mkdir -p /srv/ftp/stable && mount --bind /mnt/repo/astra/mirror/mirror.yandex.ru/astra /srv/ftp/stable на сервере использую LVM . mount выводит
- "/dev/mapper/samba--vg-root on /srv/ftp/stable type ext4 (rw,relatime,errors=remount-ro,data=ordered)'

настройка apt-mirror
/etc/apt/mirror.list :
############# config ##################
#
# set base_path /var/spool/apt-mirror
#
set base_path /mnt/repo/astra
#
# set mirror_path $base_path/mirror
# set skel_path $base_path/skel
# set var_path $base_path/var
# set cleanscript $var_path/clean.sh
# set defaultarch <running host architecture>
# set postmirror_script $var_path/postmirror.sh
set run_postmirror 0
set nthreads 3
set _tilde 0
#
############# end config ##############
###deb http://ftp.us.debian.org/debian unstable main contrib non-free
###deb-src http://ftp.us.debian.org/debian unstable main contrib non-free
# mirror additional architectures
#deb-alpha http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-amd64 http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-armel http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-hppa http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-i386 http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-ia64 http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-m68k http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-mips http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-mipsel http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-powerpc http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-s390 http://ftp.us.debian.org/debian unstable main contrib non-free
#deb-sparc http://ftp.us.debian.org/debian unstable main contrib non-free
###clean http://ftp.us.debian.org/debian

## ADD TO ASTRA LINUX##
#deb-i386 http://mirror.yandex.ru/astra/current/orel/repository orel main contrib non-free
#deb-amd64 http://mirror.yandex.ru/astra/current/orel/repository orel main contrib non-free
#deb-i386 http://mirror.yandex.ru/astra/stable/orel/repository orel main contrib non-free
deb-amd64 http://mirror.yandex.ru/astra/stable/orel/repository orel main contrib non-free
clean http://mirror.yandex.ru/astra

настройка /etc/vsftpd.conf:
listen=NO
listen_ipv6=YES

# Анонимный доступ разрешен
anonymous_enable=YES

local_enable=YES
#write_enable=YES
dirmessage_enable=YES
use_localtime=YES
xferlog_enable=YES
connect_from_port_20=YES
secure_chroot_dir=/var/run/vsftpd/empty
pam_service_name=vsftpd
rsa_cert_file=/etc/ssl/certs/ssl-cert-snakeoil.pem
rsa_private_key_file=/etc/ssl/private/ssl-cert-snakeoil.key
ssl_enable=NO

# Раскомментировать, чтобы указать на использование файловой системы UTF8
utf8_filesystem=YES
#####
chroot_local_user=NO
no_anon_password=YES


tail -f /var/log/vsftpd.log:

Wed Sep 18 16:13:56 2019 [pid 2841] CONNECT: Client "::ffff:10.10.120.17"
Wed Sep 18 16:13:56 2019 [pid 2840] [ftp] OK LOGIN: Client "::ffff:10.10.120.17", anon password "<no_password>"
Wed Sep 18 16:13:56 2019 [pid 2842] [ftp] FAIL DOWNLOAD: Client "::ffff:10.10.120.17", "/stable/orel/repository/dists/orel/InRelease", 0.00Kbyte/sec
 

igorprint

New member
Сообщения
5
#2
Раскопал в чем было дело в set base_path /mnt/repo/astra переделал на set base_path /var/spool/apt-mirror и все пошло - дело в vsftpd