I was using 50 concurrent users kept sending query `select number, toDateTime(number), toString(number) from numbers(10000)` using JDBC driver to ClickHouse http interface. After running the test for 10 minutes or so, ClickHouse server crashed leaving below error logs. I'll restart the container and re-run the test.

```bash
2022.02.21 00:30:26.676747 [ 691 ] {} <Fatal> BaseDaemon: ########################################
2022.02.21 00:30:26.682373 [ 691 ] {} <Fatal> BaseDaemon: (version 22.1.3.7 (official build), build id: D11BC54A7FE20E44) (from thread 689) (query_id: 47848c47-9c3a-4c1f-8770-dcc43974a88b) Received signal Arithmetic exception (8)
2022.02.21 00:30:26.682396 [ 691 ] {} <Fatal> BaseDaemon: Integer divide by zero.
2022.02.21 00:30:26.682403 [ 691 ] {} <Fatal> BaseDaemon: Stack trace: 0xa8671e8 0x7f69d289f3c0 0x7f69d289a376 0x175a2481 0xa8713e1 0xa871130 0x14927c5c 0x13d22da0 0x1156b348 0x1317a37e 0x13d18028 0x145a6b3a 0x145ab247 0x1480e59d 0x1745e52f 0x17460981 0x17611609 0x1760ed00 0x7f69d2893609 0x7f69d27ba293
2022.02.21 00:30:26.682436 [ 691 ] {} <Fatal> BaseDaemon: 2. ? @ 0xa8671e8 in /usr/bin/clickhouse
2022.02.21 00:30:26.682443 [ 691 ] {} <Fatal> BaseDaemon: 3. ? @ 0x7f69d289f3c0 in ?
2022.02.21 00:30:26.682448 [ 691 ] {} <Fatal> BaseDaemon: 4. pthread_cond_wait @ 0x7f69d289a376 in ?
2022.02.21 00:30:26.682462 [ 691 ] {} <Fatal> BaseDaemon: 5. Poco::EventImpl::waitImpl() @ 0x175a2481 in /usr/bin/clickhouse
2022.02.21 00:30:26.682473 [ 691 ] {} <Fatal> BaseDaemon: 6. ThreadPoolImpl<ThreadFromGlobalPool>::finalize() @ 0xa8713e1 in /usr/bin/clickhouse
2022.02.21 00:30:26.682477 [ 691 ] {} <Fatal> BaseDaemon: 7. ThreadPoolImpl<ThreadFromGlobalPool>::~ThreadPoolImpl() @ 0xa871130 in /usr/bin/clickhouse
2022.02.21 00:30:26.682484 [ 691 ] {} <Fatal> BaseDaemon: 8. DB::ParallelFormattingOutputFormat::~ParallelFormattingOutputFormat() @ 0x14927c5c in /usr/bin/clickhouse
2022.02.21 00:30:26.682490 [ 691 ] {} <Fatal> BaseDaemon: 9. ? @ 0x13d22da0 in /usr/bin/clickhouse
2022.02.21 00:30:26.682497 [ 691 ] {} <Fatal> BaseDaemon: 10. DB::SourceWithProgress::~SourceWithProgress() @ 0x1156b348 in /usr/bin/clickhouse
2022.02.21 00:30:26.682502 [ 691 ] {} <Fatal> BaseDaemon: 11. DB::QueryPipeline::reset() @ 0x1317a37e in /usr/bin/clickhouse
2022.02.21 00:30:26.682516 [ 691 ] {} <Fatal> BaseDaemon: 12. DB::executeQuery(DB::ReadBuffer&, DB::WriteBuffer&, bool, std::__1::shared_ptr<DB::Context>, std::__1::function<void (std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)>, std::__1::optional<DB::FormatSettings> const&) @ 0x13d18028 in /usr/bin/clickhouse
2022.02.21 00:30:26.682535 [ 691 ] {} <Fatal> BaseDaemon: 13. DB::HTTPHandler::processQuery(DB::HTTPServerRequest&, DB::HTMLForm&, DB::HTTPServerResponse&, DB::HTTPHandler::Output&, std::__1::optional<DB::CurrentThread::QueryScope>&) @ 0x145a6b3a in /usr/bin/clickhouse
2022.02.21 00:30:26.682540 [ 691 ] {} <Fatal> BaseDaemon: 14. DB::HTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0x145ab247 in /usr/bin/clickhouse
2022.02.21 00:30:26.682545 [ 691 ] {} <Fatal> BaseDaemon: 15. DB::HTTPServerConnection::run() @ 0x1480e59d in /usr/bin/clickhouse
2022.02.21 00:30:26.683736 [ 691 ] {} <Fatal> BaseDaemon: 16. Poco::Net::TCPServerConnection::start() @ 0x1745e52f in /usr/bin/clickhouse
2022.02.21 00:30:26.683755 [ 691 ] {} <Fatal> BaseDaemon: 17. Poco::Net::TCPServerDispatcher::run() @ 0x17460981 in /usr/bin/clickhouse
2022.02.21 00:30:26.683761 [ 691 ] {} <Fatal> BaseDaemon: 18. Poco::PooledThread::run() @ 0x17611609 in /usr/bin/clickhouse
2022.02.21 00:30:26.683768 [ 691 ] {} <Fatal> BaseDaemon: 19. Poco::ThreadImpl::runnableEntry(void*) @ 0x1760ed00 in /usr/bin/clickhouse
2022.02.21 00:30:26.683772 [ 691 ] {} <Fatal> BaseDaemon: 20. ? @ 0x7f69d2893609 in ?
2022.02.21 00:30:26.683776 [ 691 ] {} <Fatal> BaseDaemon: 21. __clone @ 0x7f69d27ba293 in ?
2022.02.21 00:30:26.836674 [ 691 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 38FD0E3944230CBD1E0C1028A9D68C83. There is no information about the reference checksum.
```

Update:
I wasn't able to reproduce the issue in second run, which took 50+ minutes(due to slow and unstable wifi between my laptop and VM).

Label | # Samples | Average | Median | 90% Line | 95% Line | 99% Line | Min | Max | Error % | Throughput | Received KB/sec | Sent KB/sec
-- | -- | -- | -- | -- | -- | -- | -- | -- | -- | -- | -- | --
JDBC Request | 500000 | 322 | 286 | 428 | 617 | 1007 | 25 | 15018 | 0.0 | 154.4752722163247 | 44852.43836513876 | 0.0

Update again:

Update image to 22.2 and ran into the issue:
```
2022.02.21 17:08:49.330757 [ 465 ] {} <Fatal> BaseDaemon: ########################################
2022.02.21 17:08:49.330791 [ 465 ] {} <Fatal> BaseDaemon: (version 22.2.2.1, build id: 5F3D9E4F48D4CC47) (from thread 299) (query_id: 7d79a97f-998d-400e-a4a7-2fc1a63be6fe) (query: select number, toDateTime(number), toString(number) from numbers(10000)) Received signal Arithmetic exception (8)
2022.02.21 17:08:49.330808 [ 465 ] {} <Fatal> BaseDaemon: Integer divide by zero.
2022.02.21 17:08:49.330818 [ 465 ] {} <Fatal> BaseDaemon: Stack trace: 0xaf01a08 0x7f0de90023c0 0x7f0de8ffd374 0x187ab341 0x15b27201 0x15a6cf8d 0x15a60ca3 0x15a54b7e 0x15a53ddb 0x15a53718 0x15a52244 0x14eec693 0x157a42bd 0x157a8a52 0x15a0d67b 0x18667a0f 0x18669e61 0x1881a549 0x18817c40 0x7f0de8ff6609 0x7f0de8f1d293
2022.02.21 17:08:49.330845 [ 465 ] {} <Fatal> BaseDaemon: 2. ? @ 0xaf01a08 in /usr/bin/clickhouse
2022.02.21 17:08:49.330859 [ 465 ] {} <Fatal> BaseDaemon: 3. ? @ 0x7f0de90023c0 in ?
2022.02.21 17:08:49.330865 [ 465 ] {} <Fatal> BaseDaemon: 4. pthread_cond_wait @ 0x7f0de8ffd374 in ?
2022.02.21 17:08:49.330880 [ 465 ] {} <Fatal> BaseDaemon: 5. Poco::EventImpl::waitImpl() @ 0x187ab341 in /usr/bin/clickhouse
2022.02.21 17:08:49.330892 [ 465 ] {} <Fatal> BaseDaemon: 6. DB::ParallelFormattingOutputFormat::finalizeImpl() @ 0x15b27201 in /usr/bin/clickhouse
2022.02.21 17:08:49.330898 [ 465 ] {} <Fatal> BaseDaemon: 7. DB::IOutputFormat::work() @ 0x15a6cf8d in /usr/bin/clickhouse
2022.02.21 17:08:49.330903 [ 465 ] {} <Fatal> BaseDaemon: 8. DB::ExecutionThreadContext::executeTask() @ 0x15a60ca3 in /usr/bin/clickhouse
2022.02.21 17:08:49.330910 [ 465 ] {} <Fatal> BaseDaemon: 9. DB::PipelineExecutor::executeStepImpl(unsigned long, std::__1::atomic<bool>*) @ 0x15a54b7e in /usr/bin/clickhouse
2022.02.21 17:08:49.330914 [ 465 ] {} <Fatal> BaseDaemon: 10. DB::PipelineExecutor::executeImpl(unsigned long) @ 0x15a53ddb in /usr/bin/clickhouse
2022.02.21 17:08:49.330919 [ 465 ] {} <Fatal> BaseDaemon: 11. DB::PipelineExecutor::execute(unsigned long) @ 0x15a53718 in /usr/bin/clickhouse
2022.02.21 17:08:49.330923 [ 465 ] {} <Fatal> BaseDaemon: 12. DB::CompletedPipelineExecutor::execute() @ 0x15a52244 in /usr/bin/clickhouse
2022.02.21 17:08:49.330937 [ 465 ] {} <Fatal> BaseDaemon: 13. DB::executeQuery(DB::ReadBuffer&, DB::WriteBuffer&, bool, std::__1::shared_ptr<DB::Context>, std::__1::function<void (std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&)>, std::__1::optional<DB::FormatSettings> const&) @ 0x14eec693 in /usr/bin/clickhouse
2022.02.21 17:08:49.331080 [ 465 ] {} <Fatal> BaseDaemon: 14. DB::HTTPHandler::processQuery(DB::HTTPServerRequest&, DB::HTMLForm&, DB::HTTPServerResponse&, DB::HTTPHandler::Output&, std::__1::optional<DB::CurrentThread::QueryScope>&) @ 0x157a42bd in /usr/bin/clickhouse
2022.02.21 17:08:49.331086 [ 465 ] {} <Fatal> BaseDaemon: 15. DB::HTTPHandler::handleRequest(DB::HTTPServerRequest&, DB::HTTPServerResponse&) @ 0x157a8a52 in /usr/bin/clickhouse
2022.02.21 17:08:49.331092 [ 465 ] {} <Fatal> BaseDaemon: 16. DB::HTTPServerConnection::run() @ 0x15a0d67b in /usr/bin/clickhouse
2022.02.21 17:08:49.331099 [ 465 ] {} <Fatal> BaseDaemon: 17. Poco::Net::TCPServerConnection::start() @ 0x18667a0f in /usr/bin/clickhouse
2022.02.21 17:08:49.331103 [ 465 ] {} <Fatal> BaseDaemon: 18. Poco::Net::TCPServerDispatcher::run() @ 0x18669e61 in /usr/bin/clickhouse
2022.02.21 17:08:49.331109 [ 465 ] {} <Fatal> BaseDaemon: 19. Poco::PooledThread::run() @ 0x1881a549 in /usr/bin/clickhouse
2022.02.21 17:08:49.331113 [ 465 ] {} <Fatal> BaseDaemon: 20. Poco::ThreadImpl::runnableEntry(void*) @ 0x18817c40 in /usr/bin/clickhouse
2022.02.21 17:08:49.331117 [ 465 ] {} <Fatal> BaseDaemon: 21. ? @ 0x7f0de8ff6609 in ?
2022.02.21 17:08:49.331122 [ 465 ] {} <Fatal> BaseDaemon: 22. __clone @ 0x7f0de8f1d293 in ?
2022.02.21 17:08:49.460881 [ 465 ] {} <Fatal> BaseDaemon: Calculated checksum of the binary: 03A21B8EF25D04A4DCD8C0FCA8310FDA. There is no information about the reference checksum.
```
{
        auto saved_errno = errno;   
#if defined(OS_LINUX)
        if (info)
        {
            int overrun_count = info->si_overrun;
            
            
            ++write_trace_iteration;
            if (overrun_count)
            {
                
                if (write_trace_iteration % (overrun_count + 1) == 0)
                {
                    ProfileEvents::increment(ProfileEvents::QueryProfilerSignalOverruns, overrun_count);
                }
                else
                {
                    ProfileEvents::increment(ProfileEvents::QueryProfilerSignalOverruns, overrun_count + 1);
                    return;
                }
            }
        }
#else
        UNUSED(info);
#endif
        const auto signal_context = *reinterpret_cast<ucontext_t *>(context);
        const StackTrace stack_trace(signal_context);
        TraceCollector::collect(trace_type, stack_trace, 0);
        ProfileEvents::increment(ProfileEvents::QueryProfilerRuns);