Fixes #4670, use popen in import_logs.py to run updatetokenfile.php instead of check_output.
Refs #4670, remove 2.7 header requirement.