✓ Solved

Website gets ERR_CONNECTION_REFUSED

Hi,

I am trying to host my portfolio website through Linode. Everything worked fine until I recently tried to update data on the server and started to get ERR_CONNECTION_REFUSED error.

I rebuilt the whole Linode from start after taking a backup of all the files so now I have gotten it back to the point where the page opens in Chrome for teemupulkkinen.com but not consistently for www.teemupulkkinen.com

The issue is probably with my configs somewhere but I just cannot figure out the right place to fix it. I wish the page would load both with and without the www-prefix. Please help.

4 Replies

✓ Best Answer

Both the www and non-www versions work for me.

When you say it doesn’t load consistently, what do you see when it doesn’t load?

Also a bit of advice… choose whether the www or non-www is your “primary” address, and redirect the other one to it. Search engines may see this as duplicate content as the same content exists on two different addresses.

The site rendered fine for me.

That said, you coded it strangely.

You have many of your links above the "head" tag.

You also have multiple entries for fontawesome.

And why would you use the W3-School CSS file?

You also have a "style" tag between the ending "head" and the "body" which makes no sense to me.

Finally, you should pop a SSL certificate on the site from Let's Encrypt. Simple to do.

I don't know if any of this has to do with your issues, but you might want to make some coding changes and see if the issues go away.

Perhaps there are some browsers out there having issues with your coding and causing the errors?

-ANC

<!DOCTYPE html>
<html xmlns:og="http://ogp.me/ns#" xmlns:fb="http://www.facebook.com/2008/fbml">
<title>Teemu Pulkkinen - Portfolio</title>
<meta charset="UTF-8">
<html lang="fi">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" href="https://www.w3schools.com/w3css/4/w3.css">
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Montserrat">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">
<link rel="stylesheet" href="https://use.fontawesome.com/releases/v5.4.2/css/all.css"
  integrity="sha384-/rXc/GQVaYpyDdyxK+ecHPVYJSN9bmVFBvjA/9eOB+pb3F2w2N6fc5qB9Ew5yIns" crossorigin="anonymous">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css">

<head>
  <link rel="shortcut icon" type="image/x-icon" href="favicon.ico" />
  <meta property="og:title" content="Teemu Pulkkinen" />
  <meta property="og:image" content="http://www.teemupulkkinen.com/preview.jpg" />
</head>
<style>
  body,
  h1,
  h2,
  h3,
  h4,
  h5,
  h6 {
    font-family: "Montserrat", sans-serif
  }

  .w3-row-padding img {
    margin-bottom: 12px

  }

  /* Set the width of the sidebar to 120px */
  .w3-sidebar {
    width: 120px;
    background: #222;
  }

  /* Add a left margin to the "page content" that matches the width of the sidebar (120px) */
  #main {
    margin-left: 120px
  }

  /* Remove margins from "page content" on small screens */
  @media only screen and (max-width: 600px) {
    #main {
      margin-left: 0
    }
  }
</style>

<body class="w3-black">

Thank you guys for constructive replies. I tested the www non www-versions today myself and it might be that it had something related to my DNS. The problem seems to have gone away after I let the Linode just be as it is now after setting it back up. I used to get the "ERR_CONNECTION_REFUSED" error before but that doesn't seem to happen anymore for either versions.

The programming on the website isn't ideal, I do not consider myself a webcoder but rather someone who can do some basic stuff to meet my own ends. :) I did use W3 Schools CSS because the page is heavily based on a template I got from their website.

The info on Let's Encrypt was also great, I added the certificate to my page which honestly I had just left hanging because I wasn't really sure what to do with it in the past but now when I know how to do it I'll definitely let it be. Thanks. :)

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct