Can you please try out this fix and see if it solves the issue?
--- a/plugins/TwoFactorAuth/Validator.php
+++ b/plugins/TwoFactorAuth/Validator.php
@@ -8,6 +8,7 @@
namespace Piwik\Plugins\TwoFactorAuth;
+use Piwik\Common;
use Piwik\Piwik;
use Piwik\Session\SessionFingerprint;
use Exception;
@@ -27,6 +28,11 @@ public function __construct(TwoFactorAuthentication $twoFactorAuthentication)
public function canUseTwoFa()
{
+ if (Common::isPhpCliMode() && (!defined('PIWIK_TEST_MODE') || !PIWIK_TEST_MODE)) {
+ // eg when archiving or executing other commands
+ return false;
+ }
+
if (!SettingsPiwik::isPiwikInstalled()) {
return false;
}
white screen with HTTP 500. in Apache log I found memory_limit error. 128 M memory limit was set. I double this to 256M and it still shows white screen (HTTP 500) and memory_limit error in log file