Showing entries 37831 to 37840 of 43775
« 10 Newer Entries | 10 Older Entries »
replicate-rewrite-db

So, in my dev environment I have 1 server to represent a particular cluster. I need to change the code to represent that a single table has been moved a new cluster. So, since I have one server I create a new database and put the table there.

Steps

get a snapshot of a table. I could use innodb-backup, but the table is not in it's own table space yet so I need to take a snapshot of it via mysqldump



mysqldump -uroot DATABASE TABLE --single-transaction > file.sql



Now I add the contents of file.sql to the new database and rename the old table to oldtable_bu

Okay now dev is working but production it's a bit different. I'm building new clusters out of an old single cluster. My goal is to switch writing to the old cluster that has the old database name to the new cluster that has the new database name without downtime.

[Read more]
April Fool's, well sort of, Postgres for MySQL

Last August I was sitting in a talk at OSCON listening to a PostgreSQL talk about their innards and got an idea.

I would put together an April Fool's joke about the existence of a MySQL Postgres engine. I put a note in iCal to begin working on it on March 1st.

March 1st came around and I got the reminder. I spoke at the time with Patrick Galbraith about doing a quick federated MySQL -- Postgres connector. It would be incredibly easy to do. Patrick though was more interested in doing an ODBC style generic engine and handle many engines at once (which he is getting close to releasing).

Not wanting to barge in on Patrick's work, I decided to just mock up a basic skeleton of an engine. All of about 10 …

[Read more]
Updates to NDB/Connectors

The NDB/Connectors have added support for Ruby, as well as Asynchronous Transaction support for Java, Python and Perl.

The Ruby support, of course, means that new you can interact with your MySQL Cluster installation using the NDBAPI from all your Ruby code.

The async stuff is especially cool, because it means you can send transactions to the Cluster and get responses by way of callbacks defined in the connector language. So you can do something like this:

class testaclass(object):

  def __init__(self, recAttr):
    self.recAttr=recAttr

  def __call__(self, ret, myTrans):
    print "value = ", self.recAttr.get_value()

#snip

myTrans = myNdb.startTransaction()

myOper = myTrans.getNdbOperation("mytablename")
myOper.readTuple(ndbapi.NdbOperation.LM_Read)

myOper.equal("ATTR1", 245755 )

myRecAttr= myOper.getValue("ATTR2")

a = testaclass(myRecAttr) …
[Read more]
Updates to NDB/Connectors

The NDB/Connectors have added support for Ruby, as well as Asynchronous Transaction support for Java, Python and Perl.

The Ruby support, of course, means that new you can interact with your MySQL Cluster installation using the NDBAPI from all your Ruby code.

The async stuff is especially cool, because it means you can send transactions to the Cluster and get responses by way of callbacks defined in the connector language. So you can do something like this:

PLAIN TEXT

  1. class testaclass(object):     
  2.   def __init__(self, recAttr):
  3.     self.recAttr=recAttr     
  4.   def __call__(self, ret, myTrans):
  5.     print "value = ", self.recAttr.get_value()
  6.  
  7. #snip
  8.  
  9. myTrans …
[Read more]
DRBD in the real world.

I’ve noticed a few blog posts recently about people saying how great DRBD is as a fail over mechanism for MySQL. My experience with DRBD has been the complete opposite. It offers almost no benefit over binary log replication for typical MySQL setups and prevents a few things that are possible with binary log replication.

Kaj Arnö has written an excellent blog post on the basics of DRBD. DRBD has one great feature that binary log replication doesn’t have. It can ensure that a write is synced to disk on two different hosts before allowing the application to continue. This is great for data redundancy but it introduces potential for instability in the setup. In a good fail over scenario a problem on the backup master should never cause an issue on the primary master. With DRBD the second master lagging behind because of a degraded raid, network issue, operator error, name …

[Read more]
Custom output formats in mod_ndb

Often enough, it seems like you can begin working on software project with the assumption that you won't need to, say, design a little language and build a parser for it -- and yet, before long, that's exactly what you end up doing.

In the case of mod_ndb, my web services gateway for MySQL Cluster, the little language turns out to involve page-description -- it describes how to take a table of results from a database query and present it within an HTTP response. Inside an httpd.conf file, it looks something like this:

<OutputFormat XML> 
   Table  scan = '<NDBScan>\n$row$\n...\n</NDBScan>\n' 
   Row    row  = ' <NDBTuple> $attr$ \n  ...  </NDBTuple>'
   Record attr = '<Attr name=$name/Q$ value=$value/Qx$ />' or '<Attr name=$name/Q$ isNull="1" />'
</OutputFormat> 

<OutputFormat JSON> 
   Table  array  = '[\n …
[Read more]
Oracle?s Tom Kyte on MySQL error messages and sorting rules

Those of you who, like we do here at Pythian, have the pleasure of supporting both MySQL and Oracle environments (among others) will definitely know who Tom Kyte is. He is a VP of Oracle in the Public Sector group, but he’s much more well-known for his Ask Tom site, where he has been the [...]

GPLv3, Microsoft/Novell language

By Allison Randal

In November of last year Microsoft and Novell announced a collaboration deal between the two companies. The exact terms of the deal haven't been released yet, so it's difficult to evaluate it in any substantial way. The two companies report that the deal involves some form of cooperative marketing, development in virtualization and interoperability, document format compatibility, and a patent agreement. It's that last item that has sparked all the controversy.

There's no question that the announcement could have been handled better. What is still an open question is whether the deal represents a threat to free software. We just won't know until we see the terms. (A recommendation for the future: releasing the full terms of the deal at …

[Read more]
Forge gets an update, Summer of Code progressing well

MySQL Forge has been recently worked on. The Wiki got updated, there are some new extensions sitting around, and its “secure” as MediaWiki can get. The Forge itself has a nice little MySQL Conference & Expo banner, kudos to Lenz. Incidentally, register now, already. MediaWiki doesn’t have great banner support, so you’ve actually got to go in and hack on the PHP to display banners (MediaWiki:Sidebar itself, doesn’t support image loading! Then how do you link to an image?).

Been doing so much other stuff at MySQL recently, its a bit refershing to work on Forge. We’re safely off the 1.6 branch, and single sign on should be a goal next.

From the Google Summer of Code point of view, we’ve got a firmed up “wanting to …

[Read more]
Open Source ?Unconference? in India

On Saturday, 24th March ‘07, Open Source ?Unconference? was held at Mumbai, India.

It was great learning experience for everyone and a good event to network with MySQL users and developers in India. K. K. George, the project leader for open source Zmanda Recovery Manager for MySQL, gave a talk about MySQL backup and recovery. Zmanda Recovery Manager is Zmanda’s MySQL backup and recovery project that has become quite popular with MySQL administrators. It has scheduling, reporting and monitoring functionalities for MySQL databases. In addition, it can do incremental backups and can also parse the complex binary log files of MySQL dump. Remote MySQL server backup is also supported through SSH and socket options. There was lot of …

[Read more]
Showing entries 37831 to 37840 of 43775
« 10 Newer Entries | 10 Older Entries »