Here is a watchdog snippet that should be clear enough.
Code:
move_to_target ()
{
debug "Move to target"
DIRNAME="${TORRENT%/*}"
DEST="${TARGET}/${DIRNAME##*/}"
mkdir -p "${DEST}"
chmod 775 "${DEST}"
grep -q ${GROUP} /etc/group && chgrp ${GROUP} "${DEST}"
grep -q ${USER} /etc/passwd && chown ${USER} "${DEST}"
cd "${TORRENT%/*}"
grep -q ${GROUP} /etc/group && chgrp ${GROUP} * .info .status
grep -q ${USER} /etc/passwd && chown ${USER} * .info .status
chmod 775 * .info .status
notice "Moving files to: ${DEST}"
mv * .info .status "${DEST}"
chmod 775 "${DEST}"
STATUS="Ok"
}
So If you do not have proper group and user in /etc/passwd and /etc/group then changing permissions will not be taken. If tou use Oleg firmware then you shout have /etc/passwd and /etc/group specified in /usr/local/.files
I suggest to have the same group in ftp clients. Leave owner admin. chgrp and chown should have -R for recursion. Will chenge this in future releases.