Thomas Mullaly

DevOps, Security and IT Leadership

Node.js and Nginx on an Amazon Linux EC2 Instance

I’m looking to automate a node.js application on amazon web services. I’m using the amazon linux ami, which is based off of centos 5. Notice that amazon has switched from using para-virtualized (pv) guests to hardware virtualized machine guests (hvm).

Launch the instance and ssh in, and become root (sudo -i).

Apache VCL Install on CentOS 6.5

I’ve been meaning to install Apache’s VCL (Virtual Computer Lab) in my new kvm environment. I’m looking to get a job in a college or university and this solution works incredibly well. How do I know? Well, becasue I recently went back to finish my undergraduate degree, I used all these new systems as a student and the VCL was one of them.

Add Disks to LVM

I haven’t been working on my new kvm virtualization setup in over a month becasue I’ve been working on my condo to sell in the spring. I took down my entire physical work enviroment to paint the walls and also as a basic cleaning out measure. I finally moved my old mac pro to a place where I can get it on the network without running any cables and I’ve begun where I’ve left off last.

The mac pro, as you remember, had ubuntu linux instaled on it and it has become my kvm host. There are three disks in the machine, I’ve only been using one until now. I want to add the other disks and I want the best performance and I’m not concerned about redundancy, so I’ve decided to stripe the disks. First off let’s look at the current environment:

Connect Foreman to Kvm Host Machine

We need to setup ssh keys so that the foreman vm can communicate with the host operating system. Becasue we’re running Ubuntu, the root account is disabled by default so I’m going to enable it by giving it a password. Then we’re going to create an ssh key on the foreman vm and transfer it to the kvm host. We’ll test the ssh key and then we’ll use the foremen web interface to add the ability to provision a kvm instance.

First log into the kvm host machine and sudo to root (sudo -i).

My New Virtualization Platform - KVM on Ubuntu 14.04.1 on My Old 2006 Mac Pro

My old Mac Pro is awesome, but I didn’t really want to contine using OSX 10.6 and VMware Fusion 3.0. So I wanted to reinstall a latest linux distro on it, but ran into some difficulty because of the efi thing. On my Mac pro the EFI is 32 bits which prevents booting a 64-bit bootloader, or something like that. When I tried a normal boot disk for CentOS 7 I got this:

Select CD-ROM Boot type:

Cloud Strategy

At this point in time you should be taking advantage of virtualization in your data center. The next step is to take it to the cloud and increase efficiencies even more. Your virtualization solution should have changed your view on servers. The IT devops lifecycle becomes more apparent when virtualizied. These aren’t the servers of old which noone touches and never reboots, these are your agile virtual appliances which can be taken down and redeployed with a push of button.

Simple Recursion Example in Python

I generally use loops when solving problems that do the same thing over and over again. I’s starting to use recursion when when a small part of the problem resembles the whole problem. I think I should think of using recursion more often.
def ask_recursively(question):
    reply = input(question)
    reply = reply.strip().lower()

    if reply == 'yes':
        return True
    elif reply == 'no':
        return False
        print('\nPlease answer "yes" or "no". \n')

def main():
    ask_recursively("Do you understand recursion? \n")

if __name__ == '__main__':

Here’s my attempt at solving the fibonacci sequence using recursion…

Foreman Install on CentOS 6.5

Host Setup

I created a new vm using KVM’s Virtual Machine Manager GUI. 8 GB HD, 1024 MB RAM, 1 CPU. Then I installed CentOS 6.5 minimal. The system boots:

Edit /etc/sysconfig/network and add the GATEWAY

CentOS 7 How to Disable the User List

I am starting a new virtualization project using kvm so as my host I wanted to use RedHat as the host operating system.

I downloaded CentOS 7.0 and installed it, it’s very slick. I installed off of the live disk, so I have a full desktop environment.

Here’s the first thing I’ve changed, I didn’t add a user, I’m logging-in as root and I wanted to get rid of the “not listed?” label and just have a text box to type the username in.

OpenVPN on Amazon Ec2

Create a new EC2 instance, I use the offical Amazon AMI images becasue it’s the least expensive option.

Login to the new instance using the pem and run the updates.

ssh -i my.pem
yum update

Let’s install openvpn