summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRyan Chu <ryan.chu@qt.io>2019-01-09 00:19:10 +0100
committerRyan Chu <ryan.chu@qt.io>2019-01-16 18:24:01 +0000
commitfe29a6a6ebbf28505df7cdf1de24fa540fd3745e (patch)
treed97e5b945ae8e243094075af651f6847327fdda4 /src
parent2c875efa999527b5d1419ea06d786b0a462c7133 (diff)
Fix the timing issue of vsftpd during boot (probably invalid config)
This appears to be a timing issue of vsftpd's initial script (/etc/init.d/vsftpd). When starting the vsftpd service, the script uses a while loop to make sure that the vsftpd process has been created with the expected PID. The problem is that it should sleep if it can't grep the same PID via ps command. while [ ${n} -le 5 ] do _PID="$(if [ -e ...vsftpd.pid ]; then cat ...vsftpd.pid; fi)" if ! ps -C vsftpd | grep -qs "${_PID}" then break fi sleep 1 n=$(( $n + 1 )) done if ! ps -C vsftpd | grep -qs "${_PID}" then log_warning_msg "vsftpd failed - probably invalid config." exit 1 fi However, synchronization based on time is not working in general. This change will rewrite the while loop to an infinite loop and remove the exclamation symbol (!) from the if condition. Upgrading the version of vsftpd is not helpful here because vsftpd_3.0.3-11 (Ubuntu 18.10) didn't resolve it yet. Change-Id: I07382709c33bd9bab61fcea76ab7deca5f630084 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Diffstat (limited to 'src')
0 files changed, 0 insertions, 0 deletions