PXE using vsftpd and symlinks

Issues related to applications and software problems
Posts: 10
Joined: 2018/01/24 18:43:24

PXE using vsftpd and symlinks

Postby Zer0Cool » 2018/04/11 19:47:51

Centos 7.4 latest updates

I have a disk mounted at /mnt/data
it has folders, among which are:
* yum
* pxe

Long story short, yum is rsynced each day to an online repo. In the /mnt/data/pxe/centos7/ I have created a symlink such that:
* /mnt/data/pxe/centos7/x86_64/ -> /mnt/data/yum/7/os/x86_64/

This works fine when in my PXE menu I use http as the method. However when I try with ftp for the method it fails. Investigation leads me to see that ftp cannot work with symlinks, ie it cant see the /x86_64 as a folder and its contents, thus PXE client cant download files and run install via ftp (but can via http).

To clarify, /mnt/data is the "root" folder for anonymous users configured via vsftpd.conf using the line:

Code: Select all


I also do NOT have any chroot lines uncommented in the config. As the data folder is the root, I presumed it would be able to follow symlinks which "start" and "end" within its subfolders.

Oddly enough, within the yum folder /mnt/data/yum/7/ is actually a symlink to whatever the latest version of CentOS 7 is (ex: /mnt/data/yum/7.4.1708/), and I can follow that in ftp without issue. however it appears I cant follow symlinks across sub folders of /mnt/data

I have set SELinux as;

Code: Select all

setsebool -P allow_ftpd_full_access 1

I have allowed the ftp service through firewall-cmd. I have restarted all services and reloaded the firewall.

Any help would be great, Thanks