- ISPs charging Netflix and Hulu more for people to access their sites
- Comcast slowing all traffic to Netflix to promote their own streaming service
I want to map my Domain name to my apartment’s IP address. There are a couple reasons for this. First, I think it would be fun, and it is the first step to hosting a website 100% at home, so I only rely on my ISP to provide an Internet connection.
DNS serves as the phone book of the internet.
Lets say I want to visit Mike. So, I pull out a phone book. I look up Mike, and learn he lives at 123 Main St. Now I can visit him!
DNS works in a similar fashion. I want to visit Google. I type Google.com into my web browser, and thanks to DNS, my browser knows to go to Google’s IP address! So, DNS connects a Domain to an IP Address.
Now, how can I send my domain, to my apartment’s IP address? BTW, this whole posts assumes you are using a Debian-based Linux system and that Google is your Domain Registrar.
- Buy a domain name
- Setup DNS settings
- Map to web server
- Setup Dynamic DNS
1. Buy a domain name
There are several registrars out there who you can purchase domains from. Godaddy is a large name in this industry, known for their ridiculous ads and poor treatment of women. I choose to go a more ethical route, and went with Google. This was easy enough, I started by going to domains.google.com for the domains I wanted. In this case, mikehelmers.com and helmershomestead.org. Each of these ran at $12 a pop. But you can get nearly any domain that’s available. I entered my credit card info, bought my domains. Easy.
2. Setup DNS settings
Now that I had my domains, I had to point them at my websites. Since WordPress is hosting mikehelmers.com, I need to set up that domain to use WordPress DNS servers. WordPress provided their server names, and most companies make it pretty easy. For helmershomestead.org, I kept it on the default Google provided DNS servers.
3. Map to web server
For the WordPress hosted mikehelmers.com, I’m done. They’ll take care of everything else. But for the soon to be self-hosted helmershomestead.org, there’s still quite a bit more. Under the ‘Registered Hosts’ part of the DNS Settings page, I added my IP address. I did this for both http://www.helmershomestead.org and helmershomestead.org because people might enter both URLs.
I also updated the Customer Resource records, the ‘A’ records, the ‘TXT’ record, and the ‘CNAME’ record. The A Record is the primary method that a Domain maps to an IP address. The TXT Record is added because I have my sites connected to Keybase to verify that I own them. I’ll write about Keybase at a later time. CNAME further helps with mapping subdomains (www) to the primary domain.
4. Setup Dynamic DNS (Optional for most people)
One of the issues with mapping a domain name to your homes IP address is that it is not static, meaning that it can spontaneously change. Now, is that likely? No. But it can happen, and at some point, will happen. ISP’s are loathe to give someone like me a static IP address and, generally speaking, home servers are frowned upon. But whatever, they’re shady companies. To get around this issue I am going to use Dynamic DNS(DynDNS). This technology uses software to automatically check what a devices IP Address is, and then tell the DNS server what the IP address is. At domains.google.com go to the DNS settings for your domain name. Go to the ‘Synthetic Records’ section of the page and select ‘Dynamic DNS’ from the dropdown menu. This will generate the username and password that you will use after installing DDClient.
Next, install DDclient from the command line:
sudo apt-get install ddclient
You will be asked some questions, fill them out the best you can, but it doesn’t really matter. Once installation is complete open up the ‘ddclient.conf’ file:
sudo nano /etc/ddclient.conf
Overwrite the existing text with the following lines:
protocol=dyndns2 use=web server=domains.google.com ssl=yes login=Google_generated_username password=Google_generated_password whateveryourdomainis.com
Save and close the document and run the following command:
sudo ddclient -verbose -foreground
This will let you know if ddclient has successfully updated Google’s DNS servers with your external IP address.
There we go. now when I go to mikehelmers.com, is hosted by WordPress.com and helmershomestead.org independently in my apartment. Now if my public IP address changes for any reason, DDClient will check and update Google’s DNS servers accordingly.
Takeaways and future thoughts
There was some hiccups with setting up the Dynamic DNS service, but it was because I mistyped some words.
Nothing at this time. This porject does exactly what I expected it to do.
The other day I was updating the Raspberry Pi, and some updates got pushed out to the Pi running ownCloud. And it broke… Apparently, ownCloud itself was updated, but the update pushed the application into Maintenance Mode. I had to fix it.
Went to /var/www/owncloud/config/config.php and changed ‘maintenance’ ==> true, to ‘maintenance’ ==> false, and then returned to the ownCloud login page. Fortunately for me, from there it was easy. ownCloud asked if I wanted to install the update, and I said yes. Next thing you know, I was up and running.
That’s one of the cool things about these projects, new issues keep coming up. It’s good to always have an opportunity to try something new practice my troubleshooting skills.
My wife Kristin and I were talking about our dog, Wendy. We were wondering, what does she do all day while we’re at work?
This inspired the WendyCam. Our little pup is insanely curious, and always trying to get people food. In fact, we only recently learned that she can leap onto our kitchen table! But does she do this when we’re gone? Using a Raspberry Pi and some extra hardware, I built an always-on webcam to stream and take pictures when motion is detected.
One of the really cool things about this project was how much I learned about Linux as an OS. I learned more about how permissions work, and this was a great exercise in using Bash, as I did this entire project by logging in through SSH.
For this project I used the following:
– Raspberry Pi Zero
– USB wireless network adapter
– Raspberry Pi Camera module (You could also use a PS3 Eye Camera or any other USB camera)
Steps I followed:
- Prep Raspberry Pi Zero
- Install Motion
- Configure Motion
- Watch dog and be happy
1. Prep Raspberry Pi Zero
I choose the Pi Zero because of its small size. I want the computer to be fast so I loaded it with Raspbian Jessie Lite. This image of Raspbian does not come with a GUI, so you have to access it totally through the command line. Once the Pi was setup correctly, I connected my Pi Camera module camera. I went with this camera because of its small form factor. To use it, I had to go into the Raspberry Pi’s configuration to activate the camera. I could use almost any other USB camera. Additionally, I have tested it out with an old PS3 Eye camera I had lying around with no issues. I then plugged in a USB WiFi adapter so that the WendyCam can connect to the internet.
After getting Raspibian ready to go I created a case. It’s pretty fancy. I used electrical tape and a lunchmeat container.
2. Install Motion
Why Motion? Well, Motion is an open-source software that is pretty simple. It does not take many resources to run, and there is a ton of documentation out there.
sudo apt-get install motion
That installs the program. Next, I opened up a file that would allow the daemon to run on startup.
3. Configure Motion
Save the changes and open up the /etc/default/motion file and make the following changes:
sudo nano /etc/default/motion
Next, I opened up the program’s configuration file. This is what really controls the software. Starting out I edited a few things to get a higher resolution and allow streaming.
sudo nano /etc/motion/motion.conf
# Image width (pixels). Valid range: Camera dependent, default: 352
# Image height (pixels). Valid range: Camera dependent, default: 288
# Restrict stream connections to localhost only (default: on)
# Threshold for number of changed pixels in an image that
# triggers motion detection (default: 1500)
# Picture frames must contain motion at least the specified number of frames
# in a row before they are detected as true motion. At the default of 1, all
# motion is detected. Valid range: 1 to thousands, recommended 1-5
# Target base directory for pictures and films
# Recommended to use absolute path. (Default: current working directory)
After this, I forwarded port 8081 from the internet to the Wendy Pi’s internal IP address. This allows me to view the WendyCam from my phone.
4. Watch dog and be happy
To start I type:
And there we go! Kristin and I can watch Wendy all day long! Turns out she mostly sleeps. But, she looks adorable doing it.
Takeaways and future thoughts
The settings within Motion are all over the place. It took a bit of time to optimize it for the Raspberry Pi camera module. The default settings also took a ton of pictures. At least 1GB a day. Tweaking the settings slowed this down.
I also learned that I couldn’t easily delete the photos in the /var/lib/motion folder. Although this was eventually solved by changing the app permissions
sudo chown pi /var/lib/motion
sudo chmod 777 /var/lib/motion
I also stopped it from taking pictures all together so we only use it to stream now.
As always, what happens if my IP address changes?
I need a camera case! It’s great that I have the camera up and running, but I want to protect the camera cable, and maybe mount the Wendycam on the wall.
I received a much help from the authors of the following sites:
There was a phishing email going through Gmail earlier today, and Google pretty much solved the problem, but… Here’s some thoughts.
Don’t open it. It is from email@example.com, and looks like someone is sharing a document with you. They’re not.
If you already opened it, change your password ASAP.
Also go here: https://myaccount.google.com/permissions and remove permissions for “Google Docs” if it appears there. This is a really well-done phishing attack.
Hey, there! I’ve got a brief update. I’ve added a “Tech Terms” page the website. As I write these articles, I find that I’m constantly defining some terms that I use. Now, this blog is for beginners and tinkerers alike, so I want to cater to everyone. Going forward, if you are wondering what I’m talking about, click on over to the Tech Terms page and learn something new.
In the coming weeks, I have several articles in the works, and I can’t wait to share my new projects with you!
This is a project I wanted to do for a long time. When I started studying for my CompTIA A+ cert, I was shocked at how much I learned about the hardware side of computing. My current laptop, a great Sony Vaio, was bought in 2009 after my college laptops motherboard finally croaked. Freshly loaded with the new Windows 7 OS, my Vaio served me faithfully until a month ago when the errors started to pile up. In an effort to health the machine, I attempted to load Ubuntu onto it. Ubuntu is a Debian-based Linux operating system that requires fewer resources than Windows to run. But alas, the strain was too much for the Vaio, and it is no more.
But now what? At home, we have a Chromebook and a laptop that kind-of-works. But I want something with a little more power. Something that I can upgrade over time. Computing constantly changes, and it would be able to improve my machine over time. Spend $200 every few years instead of $700+. Plus, building would be a fun project.
Where do I start?
1. Defining my needs: To know what to build, I need to know why I’m building it.
2. Choosing and buying the parts: I need to buy each individual part of my machine. So I need to decide what will meet my needs, and where to purchase it.
3. Assemble the computer: I need to put the parts together, duh!
4. Install the OS: To use the computer I need to install Windows or a Linux system.
5. Configure PC for use: Setting up the PC to my preferences.
1. Defining my needs:
What do I plan on using this computer for? Coding, generic Raspberry Pi support, picture/video editing, and some gaming. For my purposes, picture/video editing will probably require the most power, due to the size of the files. But, I’m not a professional, and nor do I play games that are new so I can make some sacrifices there for power.
2. Choosing and buying the parts:
To assemble my plan, I went to PC Part Picker ###pcpartpicker.com. You can view my parts list here: https://pcpartpicker.com/list/jbPZD8. This list is actually modified from a build featured at Lifehacker. I’ll go down this list talk about each component, and why I chose it.
- Intel Core i3 6100 3.7GHz Dual-Core: The processor is the heart of a computer. It’s what controls how the computer functions. Much of what I read suggested that I go for an i5 quad-core processor, which is a newer and more updated processor from Intel. As stated above, I don’t think I need that power. the i3 should work fine for me. If it turns out it isn’t enough, I can always replace it, or by a video card at a later date. In the near-term, going with the i3 saves me $100-$150.
- MSI H110M Gaming MicroATX LGA1151 Motherboard: While there are a million options when picking a motherboard, I feel a few questions really narrows it down. First, are you using an AMD or Intel Processor? These two companies use different designs, which limits the type of board you can use. Next, what form factor do you want? I wanted a MicroATX, as this is the current standard. And finally, what type of interfaces do you want? VGA, HDMI, USB 2.0, USB 3.0, USB C, and audio connections are all items to take into consideration. The MSI board suggested by LifeHacker ticked off everything I wanted, so I decided to go with it.
- Corsair Vengeance LPX 8GB (1 x 8GB) DDR4-2400 Memory: RAM (Random Access Memory) is the memory that used by PCs to run programs. RAM generally comes into play when running programs, so I want to have enough. Modern 64-bit operating systems have an upper limit over 17 million GB of memory, but I don’t need that much. Yet. 8GB is plenty, and should I need more, there’s an extra slot to place another stick of RAM in the future.
- Kingston SSDNow UV400 120GB 2.5″ Solid State Drive: SSD’s (Solid-state Drive) are the future. Probably. They are starting to replace traditional hard drives. They are less prone to data loss from being moved around, and the memory in the SSD can actually be used in place of RAM in some cases. The other advantage is a faster read/write capability. Programs loaded onto the SSD will load faster than ones loaded on a traditional HDD. This is where my Operating System will be loaded.
- Seagate BarraCuda 1TB 3.5″ 7200RPM Internal Hard Drive: Here is the traditional hard drive (HDD- Hard disk drive). Any media I have (pictures, movies, music) will be stored here. Why bother having this when I have an SSD? Byte for byte, a traditional HDD is significantly cheaper. That’s why this 1TB HDD drive is less than a 120GB SDD.
- Cooler Master N200 MicroATX Mini Tower Case: I went with the suggest tower here. This is the case that will hold all of the components described above. This one has plenty of space inside and two fans to ensure adequate airflow through the computer. That’s important because computers can get hot. Sometimes they get so hot, parts melt. Then it gets really expensive.
- EVGA 500W 80+ Bronze Certified ATX Power Supply: Again, I went with the suggested PSU (Power Supply Unit). 500W is more than enough power, with plenty to spare, and allows me to expand in the future.
Once I made this list I went to Amazon and purchased them. With PC Part Picker, you can actually track the prices of different components over time from several different sites. I found that Amazon tended to have the cheapest price at any given time. On the odd chance that they were more expensive, it was only by $1-$4.
Now it’s time to Build!!!
3. Assemble the computer
This whole process went much smoother than I anticipated. I followed several online instruction lists, watched a couple YouTube videos, but at the end of the day, the paperwork that came with the components was the most useful tool I could have asked for. So I grabbed my trusty screwdriver and got to work.
I started with assembling the motherboard first. I place the processor in its slot and followed that up with placing the cooling fan on top. This fan will pull heat off the processor, stopping it from, well, overheating.
Next, I plugged in my stick of RAM. Too easy.
Following that, I installed the PSU into the bottom of the case, and then connected the motherboard to the side of the case.
I followed up with installing the SSD and HDD.
The last step was plugging everything in. This took quite awhile, but fortunately, nearly every connection has a unique shape, and most cables were labeled.
I plugged in the PSU, pressed the power button, and voila! I got the BIOS!!!
4. Install the OS
I decided to use Ubuntu as the OS for my PC. I wanted to save $120 by not using Windows, and I wanted a traditional desktop feel. Ubuntu is great. It’s easy to use, it’s stable, and there is a huge community of support. Plus, it’s built on the Debian branch of Linux, which I’m familiar with thanks to my time using Raspbian.
I downloaded the image off of the Ubuntu website. I used an arcane Windows program called Win32DiskImager to flash the image to a USB Drive. The Raspberry Pi Foundation suggests using a program called Etcher. After installing Ubuntu, I will learn I don’t need extra programs, the OS has an amazing formatting tool and writer built in!
Once the flash drive was created, I booted up the computer and received instructions to try Ubuntu, or install it. I chose to install it. I followed the instructions, and I was ready to go quickly.
As an aside, most modern computers will boot an OS and run it from a flash drive. This is an excellent opportunity to try out different flavors of Linux, and see what you like the most.
5. Configure PC for use
Now that my computer has an OS, I can use it! I took some time to set up the display as I wanted, and download any additional programs that I want. Ubuntu comes with LibreOffice already installed, so I had an MS Office type suite installed. I also downloaded Chromium to use as a web browser. This list will grow as I move forward using this machine more and more, but until then, I’m psyched to play with my new toy.
Takeaways and future thoughts
There was some difficulty loading Ubuntu. I was able to load it on my first boot, but then something broke during the install. Turns out my flash drive was bad. So grabbed a new drive, flashed a new image, and was good to go.
There is a small concern Ubuntu won’t work for me, and I’ll need to switch to Windows. But that’s a bridge I’ll cross when I need to. Otherwise, I can’t think of anything that I’m worried about right now.
I may get a graphics card in the future, that could extend the life of the computer for little money. I’ll also probably add a webcam. Why not chat with people?
I received a much help from the authors of the following sites: