Author: webgeek

  • Building Thrift on RedHat/CentOS 5.x

    What’s Thrift you ask? Well to quote their website.

    Thrift is a software framework for scalable cross-language services development. It combines a software stack with a code generation engine to build services that work efficiently and seamlessly between C++, Java, Python, PHP, Ruby, Erlang, Perl, Haskell, C#, Cocoa, Smalltalk, and OCaml.

     

    And why do I needed it? Well I have been testing Cassandra for at work and one of the developers want to generate some csharp code using the Thrift API, so of course he wanted me to do it, since he was having problems getting it to work on his Window box.

     

    So here is the short notes for what I did.

     

    Downloaded Thrift code:
    thrift-incubating-0.2.0.tar.gz

    Installed/Updated required packages:
    sudo yum install automake libtool flex bison pkgconfig gcc-c++ boost-devel libevent-devel zlib-devel python-devel ruby-devel

    Unpacked the code, compiled, and installed it:
    tar -zxf thrift-incubating-0.2.0.tar.gz
    cd thrift-incubating-0.2.0
    ./configure
    make
    sudo make install

    That’s it, have fun. Next project going to look at Lucandra: A Cassandra-based Lucene backend.

  • Couchdb vs. Cassandra.

    And Cassandra wins by a knock out and the crowd goes wild. http://couchdb.apache xenical buy online.org/ vs.http://incubator.apache.org/cassandra/.

    Couchdb is more user friendly, but Cassandra is way more advanced.

  • MySQL Workbench..

    The MySQL Workbench has been out for a little while now, and I kind of put it to the back of my mind, because when it come out it was on Windows only. I, myself use Linux about 90% of the time, so I figured I would wait until they had a Linux version. The other day I was surfing MySQL website and noticed that they have a Linux, and OS X version now. So I figured I would give it a try.

    I have use the MySQL GUI tools before and while they are great for simplifying administration and have a lot of basic functionality, they are lacking in the design and development areas. Now enters MySQL Workbench. It’s a data modeling and design tool. To quote the MySQL website.

    “MySQL Workbench enables a DBA, developer, or data architect to visually design, generate, and manage all types of databases including Web, OLTP, and data warehouse databases. It includes everything a data modeler needs for creating complex ER models, and also delivers key features for performing difficult change management and documentation tasks that normally require much time and effort” 

    All in all it’s not a bad tool. It’s easy to use and fills a hole in the MySQL toolkit. Of course there are two version of it Community and Standard, of which the standard has $99 a year subscription and has additional plugins.

    Check it out: http://www.mysql.com/products/workbench/

  • SchemaSpy

    “Do you hate starting on a new project and having to try to figure out someone else’s idea of a database? Or are you in QA and the developers expect you to understand all the relationships in their schema? If so then this tool’s for you.”

    This is actually really nice and fast. Also makes it easy to visually see what your developers are doing.

    http://schemaspy.sourceforge.net/

  • Finding the HBA WWN on RHEL 5.x

    Nice and easy one line command.

    shell> cat /sys/class/scsi_host/host*/device/fc*/port_name

  • So many to choose from.

    For the last month or so. There has been a debate amongst, my peers and I, on which is the better file system on Linux and how to benchmark and test it. So digging through my back log of emails I notice that Linux Magazine was running a series on the this some topic. So I thought I would sure.

    Lies, Damn Lies and File System Benchmarks

    Metadata Performance of Four Linux File Systems

    Metadata Performance Exploration Part 2: XFS, JFS, ReiserFS, ext2, and Reiser4

  • Reinstalling the Boot Loader on RHEL

    In many cases, the GRUB boot loader can mistakenly be deleted, corrupted, or replaced by other operating systems.

    The following steps detail the process on how GRUB is reinstalled on the master boot record:

    1. Boot the system from an installation boot medium.
    2. Type linux rescue at the installation boot prompt to enter the rescue environment site link.
    3. Type chroot /mnt/sysimage to mount the root partition.
    4. Type /sbin/grub-install /dev/hda to reinstall the GRUB boot loader, where /dev/hda is the boot partition.
    5. Review the /boot/grub/grub.conf file, as additional entries may be needed for GRUB to control additional operating systems.
    6. Reboot the system.
  • Cloud computing

    Cloud computing is a style of computing in which dynamically scalable and often virtualized resources are provided as a service over the Internet.
    Cloud computing can be confused with:

    1. grid computing—”a form of distributed computing whereby a ‘super and virtual computer’ is composed of a cluster of networked, loosely coupled computers, acting in concert to perform very large tasks”;
    2. utility computing—the “packaging of computing resources, such as computation and storage, as a metered service similar to a traditional public utility such as electricity”;
    3. autonomic computing—”computer systems capable of self-management”.
  • MySQL Table Maintenance.

    This morning I was asked by one of the other Engineers in my group about an easy way to analyze all the tables in a database. So I pointed him to mysqlcheck. Which is a great command line client for performing table mainteneance on mysql database tables. It checks, repairs, optimizes, or analyzes tables, all from the command line. Like any other program it has a ton of flags, but here are three general ways to invoke it.

    shell> mysqlcheck [options] db_name [tables]
    shell> mysqlcheck [options] –databases db_name1 [db_name2 db_name3…]
    shell> mysqlcheck [options] –all-databases

    For more information check out.

    MySQL 5.0 Reference Manual :: 4 MySQL Programs :: 4.5 MySQL Client Programs :: 4.5.3 mysqlcheck — A Table Maintenance Program

  • Unfreezing media in Netbackup on Solaris.

    Here is something you don’t use everyday or at least I don’t. 🙂

    First find the frozen media IDs.

    shell>/usr/openv/netbackup/bin/goodies/available_media | grep FROZEN

    A00060  HCART3   TLD      1       37     –       1     0        FROZEN
    –snip–

    Then unfreeze them with this command xenical otc.

    shell> /usr/openv/netbackup/bin/admincmd/bpmedia -unfreeze -m A00060