   (c/su 
     (info node "stopping hbase")
     ; call stop-hbase.sh is very slow, so here we kill java forcely.
-    (meh (cu/grepkill "java"))
+    (cu/grepkill "java")
+    (Thread/sleep 2000)
     ; (meh (c/exec "/root/hbase/bin/stop-hbase.sh"))
-    (meh (c/exec :rm :-rf "/root/hbase/logs/*"))
-    (meh (c/exec :rm :-rf "/var/lib/hbase/*"))
-    (meh (c/exec :rm :-rf "/tmp/hbase/*"))
+    ;(meh (c/exec :rm :-rf "/var/lib/hbase/"))
+    ;(meh (c/exec :rm :-rf "/root/hbase/logs/"))
+    (meh (c/exec :rm :-rf "/tmp/hbase/"))
     )
   (info node "hbase stopped"))
+
+(defn eval!
+  "Evals a sql string from the command line."
+  [s]
+  (c/exec :echo s | "/root/interpreter" 
+          :-lease 0 
+          :-store "hbase" 
+          (c/lit (str "-dbpath=\"" store-path "\""))
+          :> "/var/log/interpreter.log"))
+
+(defn setup-db!
+  "Initialize TiDB database."
+  [node]
+  (info node "begin to setup tidb database.")
+  (eval! (str "create table if not exists dirty
+              (id     int not null primary key,
+              x       bigint not null);")))
+
 
 (defn db
   "Sets up and tears down TiDB"

               (stop-tidb-server! node)
               (when (= node :n1)
                 (stop-tso-server! node)
                 ; (stop-hbase! node)
                 )
               (info node "tore down"))))


  [node]
  (c/su
    (info node "starting hbase")
    (c/exec :mkdir :-p "/tmp/hbase")
    (meh (c/exec "/root/hbase/bin/start-hbase.sh"))))

(defn stop-hbase!
