**How to reproduce**
Clickhouse version 21.5

```
cat /etc/clickhouse-server/users.xml
<?xml version="1.0"?>
<yandex>
    <!-- Profiles of settings. -->
    <profiles>
        <!-- Default settings. -->
        <default>
            <data_type_default_nullable>1</data_type_default_nullable>
            <load_balancing>random</load_balancing>
        </default>
....

2021.04.04 01:23:42.453678 [ 29048 ] {} <Error> Application: DB::Exception: Nested type Array(UInt64) cannot be inside Nullable type: Cannot attach table `system`.`crash_log` from metadata file /var/lib/clickhouse/metadata/system/crash_log.sql from query ATTACH TABLE system.crash_log (`event_date` Date, `event_time` DateTime, `timestamp_ns` UInt64, `signal` Int32, `thread_id` UInt64, `query_id` String, `trace` Array(UInt64), `trace_full` Array(String), `version` String, `revision` UInt32, `build_id` String) ENGINE = MergeTree ORDER BY (event_date, event_time) SETTINGS index_granularity = 8192: while loading database `system` from path /var/lib/clickhouse/metadata/system
```
case Type::FLUSH_LOGS:
        {
            getContext()->checkAccess(AccessType::SYSTEM_FLUSH_LOGS);
            executeCommandsAndThrowIfError(
                    [&] () { if (auto query_log = getContext()->getQueryLog()) query_log->flush(true); },
                    [&] () { if (auto part_log = getContext()->getPartLog("")) part_log->flush(true); },
                    [&] () { if (auto query_thread_log = getContext()->getQueryThreadLog()) query_thread_log->flush(true); },
                    [&] () { if (auto trace_log = getContext()->getTraceLog()) trace_log->flush(true); },
                    [&] () { if (auto text_log = getContext()->getTextLog()) text_log->flush(true); },
                    [&] () { if (auto metric_log = getContext()->getMetricLog()) metric_log->flush(true); },
                    [&] () { if (auto asynchronous_metric_log = getContext()->getAsynchronousMetricLog()) asynchronous_metric_log->flush(true); },
                    [&] () { if (auto opentelemetry_span_log = getContext()->getOpenTelemetrySpanLog()) opentelemetry_span_log->flush(true); }
            );
            break;
        }
        case Type::STOP_LISTEN_QUERIES:
        case Type::START_LISTEN_QUERIES:
            throw Exception(String(ASTSystemQuery::typeToString(query.type)) + " is not supported yet", ErrorCodes::NOT_IMPLEMENTED);
        default:
            throw Exception("Unknown type of SYSTEM query", ErrorCodes::BAD_ARGUMENTS);
    }
    return BlockIO();
}
StoragePtr InterpreterSystemQuery::tryRestartReplica(const StorageID & replica, ContextPtr system_context, bool need_ddl_guard)
{
    getContext()->checkAccess(AccessType::SYSTEM_RESTART_REPLICA, replica);
    auto table_ddl_guard = need_ddl_guard ? DatabaseCatalog::instance().getDDLGuard(replica.getDatabaseName(), replica.getTableName()) : nullptr;
    auto [database, table] = DatabaseCatalog::instance().tryGetDatabaseAndTable(replica, getContext());
    ASTPtr create_ast;