Skip to content

aboev/smalldb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SmallDB

SmallDB - sample in-memory storage engine for MySQL
Supports basic CRUD operations, data is stored in a linked list

Installation

Installation requires MySQL source code(same as installed version)
Following example is for MySQL Community 5.5.35

  1. Download & untar MySQL source code
  wget http://downloads.mysql.com/archives/get/file/mysql-5.5.35.tar.gz
  tar -zxvf mysql-5.5.35.tar.gz
  1. Clone smalldb into mysql-5.5.35/storage/smalldb directory
  cd mysql-5.5.35
  git clone https://github.com/aboev/smalldb.git storage/smalldb
  1. Run cmake
  cmake .
  1. (Optional) Install & run MySQL if you don't have one. Please follow instructions on http://dev.mysql.com/doc/refman/5.6/en/installing-source-distribution.html for post-install setup
  make  
  make install
  1. Compile smalldb
  cd storage/smalldb  
  make
  1. Copy smalldb.so file into MySQL plugin directory (You can check plugin directory through: SHOW VARIABLES LIKE "%plugin_dir%";)
  cp ha_smalldb.so /opt/mysql/server-5.5.35/lib/plugin/
  1. Install smalldb
  mysql -u root -p -e 'INSTALL PLUGIN smalldb soname "ha_smalldb.so";'

Now you can define smalldb as storage engine:

CREATE TABLE tbl (col VARCHAR(255)) ENGINE = smalldb;

About

Sample storage engine for MySQL

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages