Showing entries 33556 to 33565 of 44797
« 10 Newer Entries | 10 Older Entries »
Memcached, but do you need it?

With all due respect to the technology and it's advocates (myself included), after a surge in articles describing the merits of using memcached I'm just pushing a thought breakpoint for developers to think whether they actually need it or not?

Recently, I ran into cases where the developers have decided to use memcached over MySQL style architecture after reading some/many good/nice articles about it without giving a damn to their requirements. I would like to list few things as a checklist for developers to decide on their architecture. There is still no precise answer but sometimes few cases can be just ruled out :).

  1. What is the total size of your data? It might be a possibility that you can keep the data in memory in each node, or MySQL can just keep the whole thing (data+indexes) in a buffer.
  2. How frequently your data is updated? Very frequent updates may lead to low cache hit ratio for memcached …
[Read more]
MySQL: Free Software but not Open Source

The title of MySQL’s website states that they are the world’s most popular open-source database. This is false; MySQL is not an open-source database. That assertion is a fact, not an opinion.

MySQL is Free Software, licensed under the GNU GPL. People frequently use the two phrases “Free Software” and “Open Source Software” as synonyms, but there are very large, very important differences.

The difference between Free and Open Source

Open Source is much more of a development methodology than a philosophical standpoint. The first thing on the Open Source Initiative’s website is this introduction:

Open source is a development method for software that harnesses the power of distributed peer review and transparency of …

[Read more]
Datagrid and arrays (again)

So I got bored and I've just added array support to the Datagrid class. You can see it in action by looking at example9.php. Instead of supplying the connection parameters and the SQL query to the static Create() method, you simply supply the array. The array should be two dimensional, like that returned by mysql_fetch_assoc(). Indexed first numerically, and then by "column name". Barring any problems, this will be "released" shortly.

Zenoss Deathmatch

I've been working for the last week on implementing Zenoss to replace Nagios and Cacti. Individually Nagios and Cacti are pretty good at what they do, but they don't integrate well.

Nagios is primarily an availability monitor, so it's good for notifying you when something goes down, or a disk is filling up, or the load average is too high. etc., but it's not so great for monitoring performance. Nagios 1.4 uses text configuration files. There is a templating system which can be helpful if you have a lot of identical systems.

Cacti, on the other hand, is pretty good at monitoring performance, as in how much bandwidth are you using, resource utilization, and so on with nice long-term graphs using RRDtool, but it's not so great for notifying if something is …

[Read more]
MySQL Log Rotation


Ok. So I just looked at two blog posts about MySQL log rotation. While not technically incorrect, I’d like to disagree with the final answer, mainly because recreating the wheel drives me crazy.

Rather than writing a custom script to do this and putting that script in cron, why not use logrotate?

We already ship fully functional log rotate scripts in the Debian MySQL packages. Here’s an example:

/var/log/mysql.log /var/log/mysql/mysql.log /var/log/mysql/mysql-slow.log {
        daily
        rotate 7
        missingok
        create 640 mysql adm
        compress
        sharedscripts
        postrotate
                test -x /usr/bin/mysqladmin || exit 0

                # If this fails, check debian.conf! …
[Read more]
Datagrid and arrays (again)

So I got bored and I've just added array support to the Datagrid class. You can see it in action by looking at example9.php. Instead of supplying the connection parameters and the SQL query to the static Create() method, you simply supply the array. The array should be two dimensional, like that returned by mysql_fetch_assoc(). Indexed first numerically, and then by "column name". Barring any problems, this will be "released" shortly.

Plaxo acquired by Comcast

I was about to bitch about Plaxo being bought by Comcast (and therefor creating an opportunity in the market)... but twitter was down!

I feel like I am slumming by blogging this, when for me this would be better off as twitter blather.

Twitter is giving me deja-vu memories of Friendster.

How did Friendster solve their problems?

They latched on their graph engine to the internals of MySQL, and pushed joins into the database.

Anybody up for writing a quick queue engine? I bet you can figure out which website really needs one about now...

Concurrent inserts on MyISAM and the binary log

Recently I had an interesting surprise with concurrent inserts into a MyISAM table. The inserts were not happening concurrently with SELECT statements; they were blocking and the process list was filling up with queries in Locked status.

My first thought was that the customer had deleted from the table, which leaves "holes" in the middle of it and prevents concurrent inserts. (You can configure the server to permit concurrent inserts even when there are holes, but it's disabled by default.) However, that turned out not to be the cause; the table was only inserted into (and selected from). Instead, the blocked statements were because of INSERT... SELECT statements that were running against the table, selecting data from it and inserting into another table.

Let's look at what happens here: suppose you have two tables tbl1 and tbl2 and concurrent inserts into tbl2 are running fine. If you now run the following query,

[Read more]
Dumping Duplicates

One of the more recent additions to the SiteCrafting CMS arsenal is a comprehensive error logger, tracking all PHP and MySQL errors (by default... other error types can be created on a case by case basis) that occur in new sites we build. Errors are stored in our own intranet system with a timestamp, error body and a site ID (assigned to each client at a different stage of our project workflow). The table looks something like this:+----+---------------------+---------------+---------+| id | logTime             | text          | project |+----+---------------------+---------------+---------+|  2 | 2008-05-14 14:42:15 | A PHP Error   |       1 ||  3 | 2008-05-14 14:42:26 | A PHP Error   |       1 ||  4 | 2008-05-14 14:42:34 | A PHP Error   …

[Read more]
CAOS Theory Podcast

The 451 Group’s Commercial Adoption of Open Source (CAOS) Research Service now has a podcast (iTunes or RSS feed).

A month or so ago, I was having a conversation with The 451 Group’s Vice President of Research Services, Simon Carruthers, about ways to expand the offerings of the CAOS Research Service. The CAOS Research Service includes aspects that are public (such as this blog), but the majority of the work that we do is accessible only to our paying clients, namely our research articles and reports, as well as our advisory service.

We made the decision to add a biweekly conference call …

[Read more]
Showing entries 33556 to 33565 of 44797
« 10 Newer Entries | 10 Older Entries »