Monthly Archives: June 2012

Subsys lock problem with CentOS 6.2 and Apache

While I was improving my LAMP module I ran in to a problem with Apache 2.2.15 on CentOS 6.2.
Apache wasn’t working with my new module so I decided to install it normally via yum and see what’s going on.
Got it installed just fine with:
yum install httpd

Ran sudo service httpd restart.
All went fine.

But now when I checked status:

service httpd status
httpd dead but subsys locked

Read more of this post


Fabric – Wrappers and more error handling

I wrote about Fabric’s error handling in this post and there task execution errors were handled like this:


def cmd(cmd):
    if run(cmd).failed:

What if the task is a bit more complex and has multilple parts that can go wrong? You might want to abort the execution and do some kind of rollback action.

The task could be aborted by just using env.warn_only=False but then then the task would be aborted before we can do any rollback actions.

Without a wrapper it could be done like this:

Read more of this post