After lots of troubleshooting, I found out that proftpd has a faulty init.d script. (Only verified this on 1.2.9_rc2 and rc3. Current line: start-stop-daemon --start --quiet --exec /usr/sbin/proftpd -- -d -p /var/run/proftpd.pid Syntax: -d (debug) expects a value between 0-9 -p (persistant passwd) expects either 1 or 0 Proposed line: start-stop-daemon --start --quiet --exec /usr/sbin/proftpd -- -p 0 This forces proftpd to go by nsswitch.conf before looking users up, thus enabling lookups in other sources than /etc/passwd Reproducible: Always Steps to Reproduce: 1. 2. 3.
yes this is definetly true! this needs fixed asap! here is the source: case 'd': if (!optarg) { log_pri(PR_LOG_ERR, "Fatal: -d requires debugging level argument."); exit(1); } log_setdebuglevel(atoi(optarg)); break; case 'p': { if (!optarg || ((persistent_passwd = atoi(optarg)) != 1 && persistent_passwd != 0)) { log_pri(PR_LOG_ERR, "Fatal: -p requires boolean (0|1) argument."); exit(1); } break; } now why this doesnt trigger and error message is because proftpd has a fauly check. gentoo's init line: start-stop-daemon --start --quiet --exec /usr/sbin/proftpd -- -d -p /var/run/proftpd.pid so -d gets optarg as beeing "-p" and -p gets optarg as being "/var/run/proftpd.pid" proftpd code cheks using atoi() which for -d translates to 0 (atoi("-p") = 0), and for -p case translates to 0 too (atoi("/var/run/proftpd.pid") = 0). so I dont know if the person who wrote the init script intended to have proftpd use persistent passwd and debugging enabled but definetly it doesnt do that now :) it instructs getopt() that -d and -p must have params. then when it gets 'd' it checks for the param which exists (with gentoo's
ignore the last 2 lines of my previous comment... :)
You're absolutely right! ProFTPD has probably been ignoring the options completely, so I've removed them and will allow configuration directives and compile-time detection to do its work.
Fixed in CVS.