Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I followed the instructions of these documentations meticulously:

However, my site is still unresponsive when entering the following in URL:

But the following does work:

Using HTTPS, in Firefox I get the timeout message "The connection has timed out".

I tried some troubleshooting. There is nothing in /var/log/apache2/error.log that is related to this, and since the request is never acknowledged by my site, there is nothing in its logger either.

When I run sudo netstat -tulpn, I do notice this entry:

tcp        0      0   *               LISTEN      3911/apache2

That makes me think apache2 is listening on 443.

So I think I need to do more than what the above instructions provided. This is what I did so far on my ubuntu server:

openssl genrsa -des3 -out server.key 1024

openssl rsa -in server.key -out server.key.insecure

mv server.key

mv server.key.insecure server.key

openssl req -new -key server.key -out server.csr

openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt

sudo cp server.crt /etc/ssl/certs

sudo cp server.key /etc/ssl/private

/etc/ssl/certs $ ls -l | grep "server.crt"
-rw-r--r-- 1 root root   1001 Jun 26 00:39 server.crt

/etc/ssl $ sudo su
➜  ssl  cd private
➜  private  ls
server.key  ssl-cert-snakeoil.key

sudo a2ensite default-ssl

sudo /etc/init.d/apache2 restart

This is what my virtual host looks like:

/etc/apache2/sites-enabled $ cat
<VirtualHost *:80>

  DocumentRoot /home/guarddoggps/public_html/
  <Directory /home/guarddoggps/public_html/>
    AllowOverride all
    Options -MultiViews

  <LocationMatch "^/assets/.*$">
    Header unset ETag
    FileETag None
    # RFC says only cache for 1 year
    ExpiresActive On
    ExpiresDefault "access plus 1 year"

Am I missing any steps?

share|improve this question
Did you open port 443 on your server / router / network for that connection IP? – Thomas W. Jun 26 '13 at 23:42
@ThomasW. I did use ufw to allow tcp connections on port 443 on the machine in which the web server is running. However, the production web server, the staging web server, the database server, and the server currently running my socket server and sms server (all of which are running ubuntu) are behind another server, which is acting as a firewall for all the servers. And that server might be blocking 443. Unfortunately, I do not have password on me right now to check and it is also running fedora so I might have to use direct iptables rather than ufw. – JohnMerlino Jun 27 '13 at 2:15
That is what you need to check, to see if the server that is the "gateway" to the boxes (the system acting as the firewall) needs to be forwarding 443 to the specific servers for them to correctly respond to the HTTPS requests. Let me know what you find out there. – Thomas W. Jun 27 '13 at 2:26

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.