Stayman's Blog

A blog belongs to a DevSecOps consultant, hacker, and entrepreneur.

Setup Percona Cluster With Chef

During the last few month, I suffered a lot to utilize Chef. Chef is a awesome tool that automates the process of building infrastructures and helps to achieve configuration consistency among all your environment, both infrastructure and dev. This is the home page of Chef

However, it’s troublesome to make it work for the first time, because both Chef and Percona are new for me. This makes the debugging procedure particularly hard, since it is not clear for me whether something’s wrong in my chef setup, or the cookbook I made, or the Percona setting. I started from the usage example described in the cookbook readme. Crap. After struggling for a week or two, I figured out how to use it to build my own percona cluster. Here, I wanna share the usage and my very own understanding of this cookbook and Percona.

How This Site Got Started: Setup EC2 (T2.micro) + Vagrant + Octopress (Ubuntu)

Today, I decided to start making my own blog. The major reason is that I can’t find enough blogs talking about Chef. This makes things perticularly difficult when I started working on Chef. Not to mention blogs in Chinese. Therefore, I wanna record what I learned, and share it with the IT folk in the world. I will write both in English & Chinese. Hopefully it could help the IT guys in China.

This post describes how I built the dev environment and the server stack of this blog.

The reasons why I chose EC2 + Vagrant + Octopress are that: 1) EC2: flexibility + 1 year free tier 2) Vagrant: easy-to-launch virtual environment + sync folder setting = fast start + favorite editor + no messing up my local env 3) OctoPress: IT-guys-oriented + everything static (no php, etc.) good for performance

今天决定要作个人博客。因为最近在做关于Chef的东西,网上很难找到相关的资料,所以chef做起来就异常艰难。更不用说什么中文的博客了。这个是主要原因。所以希望能够把我摸索出来的东西记录下来,分享给其他作IT的人。特别希望这个能帮助到中国的IT人。

这篇博客是关于我怎么搭建这个blog的开发环境和服务器stack的部署。

我用了 EC2 + Vagrant + Octopress,原因是: 1) EC2: 灵活性 + 一年免费 2) Vagrant: 最方便启用的虚拟环境 + 同步文件夹设定 = 立马开始 + 可以用最爱的编辑器 + 不会搞乱本地环境 3) OctoPress: IT人专用的blog + 纯静态 (不跑php等脚本) 性能好