Wednesday, June 6, 2012

Bought a Domain

I recently bought a domain name, c-jar.es, and set up a web server on my laptop (note that I actually took the server back down now). I'll go over some issues I faced and some things I learned, so you can avoid some of the bad things that come with buying a domain and setting up a server.

Reader beware: this is a long post. I started rambling, so what? So skim if you get too weary from my boring writing! First, we'll need to go over some vocabulary that you'll need to know (or will find out) when you buy a domain name.

  • IP Address - a series of numbers that represents a machine that is connected to the internet. You'll usually encounter IPv4, but soon IPv6 will be standard.
  • IPv4 - four numbers ranging from 0 to 255 separated by periods: 145.223.274.105
  • Domain Name - a name that maps a name of a website (ie. www.google.com) to its IP Address.
  • TLD - Top Level Domain. You probably know most of these: com, net, org, edu, gov, info, me, co, etc. Some are for specific purposes, such as edu and gov, but most have had their restrictions lifted. For example: com, net, and org are no longer for commercial applications, organizations involving network technologies, and non-profit organizations, respectively.
  • Sub-Domains - A domain that is a member of a higher-order domain. For example, Google is a sub-domain of com, www is a sub-domain of google.com, and images is a sub-domain of www.google.com
  • Ports - Every machine has a set of places it can receive and send information. Each of these is a port. Web pages are sent over port 80. Mail is port 25. Microsoft's Remote Desktop is 3389.
  • Server - An actual machine that is hosting a service over the internet. Most servers are hosting either web servers, email servers, database server, etc...
  • ISP - Internet service provider. Think Comcast, Century Link, Quest...

That's all you need to get through the rest of the post!

I've never bought a domain name before, so I was really clueless when I first looked into it. I didn't know how servers hosted websites, how domain names were sold, or anything about actually telling the internet where c-jar.es was located!

I started off by looking for domain names at Go Daddy, and I found the one I wanted. I used Spain's top level domain: ES. It fit with the rest of my name: c-jar. When you look for domain names, try to look for weird combinations, maybe you want your first name and last initial. So Sylas B. could go for syla.sb. Not a bad use of the Solomon Islands TLD, and you got a 6-letter domain! Maybe you can snag your last name in an obscure top level domain, and then create a sub-domain for each member of your family (or just you). If your last name is Smith, than smith.rw is still open! And that's the first TLD I tried.

A great tool for searching domain names is domai.nr. I would definitely recommend it over Go Daddy because while Go Daddy directly sells domains, it doesn't lease all of the TLD's. Domai.nr finds lots of great domains and a lot of times sites will offer a discount when you click the link from domai.nr to go to their website!

Once I bought my domain for $15/year (most domains are cheap like this, unless you get a shorter domain name), I had to figure out how to tell the Internet that the website for c-jar.es was being hosted on my IP address. To do this (in Go Daddy) I went to
  1. Go Daddy
  2. Domain Manager
  3. DNS Manager (Zone File Editor)
  4. Selected Add Record
  5. A - Host
  6. Filled out my IP address and I was done!
Note here that my IP address could actually change at any time. Most residential ISPs only offer dynamic IP addresses. This means I'm not guaranteed to keep my IP address. Every time I reconnect, they could change it. Real web servers are hosted behind static IP addresses. They don't change, so you can always access their site.

Server Setup Tips


I won't get into the nitty-gritties of the setup for the server setup, but for those who care, here's a little info. I used the latest versions of Apache, PHP, and mySQL (all 32-bit, for compatibility with PHP). I ran into a lot of trouble, so here's some advise. Double check your ports. Make sure port 80 is open for TCP/UDP in and out (Router settings and Windows Firewall + any other firewalls you may have). Make sure that your HOSTS file contains "*internal IP address* web server you're pointing to". So in my case it was:

10.0.0.2     c-jar.es

Make sure you follow all the instructions very carefully, and if you hit trouble, look for log files! They're so so so so very helpful. I was stuck for the longest time before I checked the log files.

Actually Making the Webpage


If you want to do some real good web editing, I suggest upgrading your Notepad++ (or god forbid notepad.exe) to Aptana Studio 3. Not only does it come with a great dark theme, but it comes with its own Apache, Ruby, Python, PHP, (and more) servers, while still allowing you to specify the versions of apache, php, etc. It then allows you to update your server. It makes it so easy!

I have some projects I want to work on, now that I have a web server. Specifically, I'm going to make a link shortener, probably on the c-jar.es/s/ directory of my web site. I also want to make a social aggregate site that allows me to manage all of my accounts easier. Maybe that will fail, I'm not sure :). It's a lot to do. I also want a home page with links to stuff I like, my accounts, blogs, resume, etc. Lastly, I want to host my own blog there.

Lastly, you may be wondering why you can't access c-jar.es! This is because I was cheap and didn't want to pay for the hosting. I did set up a server on my own laptop, but now I'm not sure it's the best idea for security and energy reasons. I may eventually pay for hosting (I'm a fan of HostGator), but I might just as well use my parents' old desktop once I get back to UNL in the fall.

That's it! Thanks for reading, and I hope you learned something. Follow me on twitter and tweet to me. You can subscribe to my posts either by RSS. If you don't have an RSS feed reader you can use http://www.feedmyinbox.com/ to send the RSS straight to your email! It's easy as pie.

Friday, May 11, 2012

First Thoughts on Portland

First Blog Post!

I'm just going to start by saying this is my first blog post! There, now that I have the first sentence down, the rest should come easy! So a little info about me and this blog. I'm a Coloradoan gone Husker gone Oregonian. That's a mouthful! I've lived in Colorado for most of my life, and I consider it my home. I moved to Lincoln last year to attend UNL. I am still in the process of pursuing a B.S. in Computer Engineering. This summer, I get to intern with Intel and in the process explore a whole new part of the United States that I've never been to!

This blog will be about coding, my experiences at Intel, UNL, and any other things that may spring to mind (I'll try to keep it mostly technology-related!). Hopefully blogging regularly will make me more productive, improve my writing, and improve my understanding of topics I blog about.


To Portland!

Here's what the drive looked like:

View Larger Map


It was 1200 miles, we split it into two days of 14 and 4 hour chunks. We saved four hours for the last day so we could get the beautiful view of Oregon and the Blue Mountains and the Cascade Range. I only started taking pictures halfway through Oregon, partly because we drove through Wyoming, Utah, and Idaho. Long drive short: wind, dirt, and trucks. When you cross into Oregon, you can instantly notice a change in vegetation. Everything is green and there's moss on everything.

On the second day we hit the Columbia River. For those of you who don't know (like myself earlier today), the Columbia River is what divides the northern border of Oregon from the southern border of Washington. I don't have a picture to show this, but you can clearly see the difference between the two states. On I-84, the Oregon side, there was moss and shrubbery covering the side of the mountains. On the Washington side, however, there was little greenery to be found, and everything was brown. On the Oregon side we saw a Mountain Goat (first one I've seen, and I'm from Colorado). I think the ridiculous rainfall just attracts more wildlife in Oregon.

The drive through Portland was hectic and busy, but we were greeted by a beautiful view driving over the Willamette River, which runs right through the heart of the city. There are many bridges that cross the river, and when we got to the other side, we saw huge houses on top of hill peaks. It was amazing. To the right is a picture of a tunnel soon after the bridge.

After that we took NW Sunset Highway into Hillsboro, a western suburb of Portland. Then we took NE Cornell Road to my apartment, and let me tell you, the traffic was horrible. It seemed like we stopped at every stop light, and the wait time for each one was 30-60 seconds. I thought it was possibly rush hour (at 12:00?). But we drove again at 4:00, then at 4:30 and 6:00. Every time we got stuck at every possible stop light. It took us at least 12 minutes to drive 2.5 miles.

Besides the traffic, I love Oregon and Portland. This is a giant city. There are thousands of restaurant options, and I only have three months to explore them! I already saw an Oyster shop today, and that got me excited! I think the weekend my roommate gets here, I'll introduce him to Oysters. He's from Wisconsin and gets here in two weeks. He's in for a treat!

I start work at Intel Monday and I couldn't be more excited. We went and saw the Jones Farm campus and there was a hawk perching on the Intel sign and munching on its catch. How cool is that?!



I think that's it for now. If you read any or all of this post, thank you! I couldn't be happier finishing my first blog post and taking this awesome new step in my life.

Edit: I almost forgot, I wanted to share the photo album. Here's the Oregon Album.