- October 19th, 2010
- Write comment
Though I don’t remember where, I recently read an article about starting your own technical blog as a way to further your career. I do a lot of development these days and so I also feel I have many experiences to share. So then, where to start? Well what a better segue into the blogging world then how I setup my own blogging environment!
After doing some research, all fingers pointed to WordPress. The decision came down to hosted (wordpress.com) or self-hosting (wordpress.org). Being the DIY kind of guy, I decided to roll my own. I am a Microsoft fan boy and loathe all that is Apple. Linux however, is a middle ground that I neither hate nor love, but have never heard anything bad about. Only that it has a steep learning curve. I have setup a Windows server in the past and found it quite difficult (assuming you wanted to do anything outside the box). Windows in and of itself is pretty flaky, there are so many factors and variables that things are bound to go boom! So it was an easy decision to give Linux a shot. I had briefly tried to setup a SuSe GUI server in the past, and it was quite simple, but I did little with it. Used it mainly to host my subversion code repository. This time around I decided to go purely shell and a friend recommended using Ubuntu. With a spare rack unit (though you could use any old box, especially since it is Linux) lying around, my OS decided upon and my blogging software of choice, I was now ready to setup my blogging system.
- Linksys Cisco Router [WRT54G2]
- Dell Poweredge 2800
The last 3 pieces of software I have not provided links to as they are installed as a package in Ubuntu. So first things first. Download Ubuntu server and burn it to a CD. I use Roxio as my burning software but of course you can use which ever you prefer. Installing Ubuntu is a snap. I used the canned package and just clicked next through the menus as they came up, installing no extra tasks when I was prompted. Everything went smoothly.
A static IP address had to be setup for the server box so I did that next. Time to setup the LAMP server. Assure that your internet is in working order by trying to ping google.com from within your shell. When I set my static IP, I messed up my routing tables. In order to correct the tables I needed to use the route command. After verifying that you have internet connectivity run sudo tasksel install lamp-server from the shell. After this command finishes, PHP, Apache and MySQL will be installed and ready to go on your server. Apache is initially configured to host on port 80. To test that your Apache is running correctly (as well as your PHP), make a simple php page and drop it into the /var/www directory.
user@server:~$ sudo vi /var/www/info.php
i (brings you into insert mode)
ESC (brings you out of insert mode)
:wq (saves the file and quits vi)
You should now be able to navigate to to the static IP address that you set for your server to see the page you just created. For example, if you set your static IP to 192.168.1.100 then (using a browser) navigate to http://192.168.1.100/info.php. If you are setup correctly, you should see a page full of information. All you have to do now is setup a port forward on your router to the static IP address you set for your server on port 80. Now whenever you navigate to your external IP, you will be brought to your hosted website. At this point I recommend, at the very least, signing up for a dynamic DNS address. As an alternative, you may wish to purchase a domain name. Personally, I have been using no-ip.com for a few years and I would recommend them to anyone looking to register and manage their DNS.
The next thing we want to do is setup our FTP. In part 2 I’ll show you what I went through setting up Pure-FTP and how to get ourselves ready for the final step, installing WordPress.