I have an issue in production server debian 10 in google cloud platform. SSL not working Apache but these conditions are already fulfilled:

  • mod ssl already enabled
  • firewall GCP already opened.
  • already listen to 443 in ports.conf
  • port 443 already open, can be telnet from inside (localhost) or outside (another server/pc)
  • certbot already published
  • apache configuration vhost already correct (in my opinion)

So the weird things is, I create this VPS based on image previous VPS that https apache already working. let say the issue is in server C. First time I have Server A and https works, I duplicate the image and make Server B also https works. Then I duplicate image from Server B become Server C, but https not working.

The spec are:

  • GCP Cloud compute
  • apache 2.4
  • cloudflare free plan (also works in server A and B)
  • debian 10

Is there anything step that I missed? Thank you


this is the error from Chrome: ERR_SSL_PROTOCOL_ERROR

and this is from firefox: SSL_ERROR_RX_RECORD_TOO_LONG

result for curl myserverIP -sv:

* Rebuilt URL to: MyServerIp/
*   Trying MyServerIp...
* Connected to MyServerIp (MyServerIp) port 80 (#0)
> GET / HTTP/1.1
> Host: MyServerIp
> User-Agent: curl/7.55.1
> Accept: */*
< HTTP/1.1 200 OK
< Date: Wed, 11 Nov 2020 03:09:31 GMT
< Server: Apache/2.4.38 (Debian)
< Last-Modified: Sun, 20 Sep 2020 11:53:07 GMT
< ETag: "3ee-5afbd609741c1"
< Accept-Ranges: bytes
< Content-Length: 1006
< Vary: Accept-Encoding
< Content-Type: text/html
<!DOCTYPE html>
                <title>MISTAR on Google Cloud</title>
                <link rel="icon" href="favicon_exi.png" type="image/gif" sizes="16x16">
        html, body {
        height: 100%;
        body {
        margin: 0;
        .flex-container {
        height: 100%;
        padding: 0;
        margin: 0;
        display: -webkit-box;
        display: -moz-box;
        display: -ms-flexbox;
        display: -webkit-flex;
        display: flex;
        align-items: center;
        justify-content: center;
        .row {
        width: auto;
        /*border: 1px solid blue;*/
        .flex-item {
        /*background-color: tomato;*/
        padding: 5px;
        width: 300px;
        height: 50px;
        margin: 10px;
        line-height: 20px;
        color: white;
        font-weight: bold;
        font-size: 2em;
        text-align: center;
                <div class="flex-container">
                        <div class="row">
                                <div class="flex-item"><img src="mistar-main.493699d8.png" height="60px" /></div>
                                <div class="flex-item"><img src="cloud-logo.svg" width="280px" /></div>
</html>* Connection #0 to host MyServerIp left intact

the result of openssl:

140205097211008:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../ssl/record/ssl3_record.c:332:
no peer certificate available
No client certificate CA names sent
SSL handshake has read 5 bytes and written 313 bytes
Verification: OK
New, (NONE), Cipher is (NONE)
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 0 (ok)
  • 1
    What do you mean, it doesn't work? What errors do you see? Show us the output of curl -sv or openssl s_client. Nov 11, 2020 at 3:03
  • 1
    curl -sv for the HTTPS would be more relevant. Nov 11, 2020 at 5:53
  • 1
    what do the logs of apache say ? From the output of openssl s_client - could it be, that apache doesn't find the SSL certificates at the path configured ?
    – Martin
    Nov 11, 2020 at 7:59
  • 1
    you missunderstood me: The results you posted looked like apache didn't find the correct certificate, that's why I suggested to look in the system logfiles... Issue a restart of apache and see if it throws any errors / warnings in the syslog...
    – Martin
    Nov 11, 2020 at 8:19
  • 1
    you have an let's encrypt certificate, but the servername (from the warning above) ends in .internal ? Check that the path to the certificates is correct and that these certificates exist (openssl x509 -in <file> -text -noout to verify that it is correct), check that the ServerName setting is correct... we cannot help you more than that without more information.
    – Martin
    Nov 11, 2020 at 8:54

1 Answer 1


Thank you for all the comment the help me debugging, the ssl now working after I change the certificate from snake oil to new generated in default-ssl file inside sites-available.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.