`
文章列表
# coding=utf-8 """装饰器: """ def deco(func): """无参数装饰器,接受一个函数,返回一个新的函数。 """ def f(*args, **kwargs): print "----", func.__name__ result = func(*args, **kwargs) print "++++", func.__ ...
git中可以设置的选项颜色值: red green blue yellow magenta cyan black white git中状态行可以设置的选项: color.status.added/updated color.status.changed color.status.untracked diff.tool指定git difftool时,使用的<tool>difftool.<tool>.cmddifftool使用的<tool>命令行difftool.<tool>.pathdifftool使用的<tool>命令的路径diff ...
目标端: alter table t discard tablesapce; 源端: flush tables t for export; 复制 t.ibd, t.cfg到目标端。 源端: unlock tables; 目标端: alter table t import tablespace; 参考地址: 14.2.5.5 Copying Tablespaces to Another Server (Transportable Tablespaces) http://dev.mysql.com/doc/refman/5.6/en/tablespace-copying.html
数据库的buffer pool中的数据重启后,会丢失。因此,再次启动后,需要重新通过应用对数据库的访问,逐渐加载到buffer pool中。这个过程称为数据库预热。如果库较大,该过程花费时间较长,期间应用的性能也受到影响。 MySQL 5.6中,可以将buffer pool的内容(文件页的索引)dump到文件中,然后快速load到buffer pool中。避免了数据库的预热过程,提高了应用访问的性能。 mysql> show variables like 'innodb_buffer%'; +-------------------------------------+------ ...
1、alter table一次可以添加多个索引,create index一次只能创建一个。创建多个索引时,alter table只对表扫描一次,效率较高。 2、alter table可以不指定索引名,此时将使用索引列的第一列的列名;create index必须指定索引名。 因此,alter table添加索引更灵活。
运行时加载validate_password插件: mysql> select * from information_schema.plugins where plugin_name='validate_password'; Empty set (0.05 sec) mysql> show variables like 'validate_password%'; Empty set (0.00 sec) 安装validate_plugin插件: mysql> install plugin validate_password soname 'vali ...
local_infile服务器变量指示能否使用load data local infile命令。该变量默认为ON。 该变量为OFF时,禁用客户端的load data local infile命令。 mysql> show create table test.t\G *************************** 1. row *************************** Table: t Create Table: CREATE TABLE `t` ( `id` int(11) DEFAULT NULL, `name` varchar( ...

git的clone

    博客分类:
  • git
从A代码库clone出来的B代码库,不能直接从A代码库push到B代码库。因为不可以push到B代码库已经checkout的(当前)分支上。 可以从B代码库pull、fetch A代码库的更新。 可以创建bare代码库,可以直接push到bare代码库中。 直接创建bare代码库: git init --bare 克隆创建bare代码库: git clone --bare git clone --mirror
模块(module) 包(package) 模块的创建 创建一个可被重用的Python脚本文件,即创建了一个模块。模块名即为脚本的(无后缀)文件名。可用import <modname>导入模块。 模块的属性 __name__ 对于导入的模块,与模块名相同。对于直接执 ...
1、安装Python 2.7.6 tar -xzvf Python-2.7.6.tar.gz -C /tmp cd /tmp/Python-2.7.6 ./configure -enable-shared make make install 2、安装cx_Oracle 5.1.2 tar -xzvf cx_Oracle-5.1.2.tar.gz -C /tmp cd /tmp/cx_Oracle-5.1.2 export ORACLE_HOME=/home/oracle/app/oracle/product/11.2.0/dbhome_2 export LD_LIBRARY_PATH= ...

GitEye字体设置

    博客分类:
  • git
Windows -> Preferences General -> Appearance -> Colors and Font 2013/06/13  17:46           787,737 MySQL for Beginners (Introduction to MySQL).pdf 2013/06/13  17:43         4,404,289 MySQL for Developers Ed 1 (Student Guide - Volume 1).pdf 2013/06/13  17:46         5,201,401 MySQL for De ...

mysqlbinlog

mysqlbinlog 会解析日志,并生成BINLOG语句,可以用于重新执行。 既可以解析binary log,也可以解析relay log。因为relay log与binary log格式相同。 一、从远端服务器获取binlog 需要以下参数: --read-from-remote-server(等价于--read-from-remote-master=BINLOG-DUMP-NON-GTIDS) 以下参数为连接参数,用法与mysql客户端相同 --host --user --password --port --protocol --socket 二、显示选项 --verbose,-v ...

mysqlfabric

MySQL Fabric: Presentations http://www.slideshare.net/mkindahl/mysql-sharding-tools-and-best-practices-for-horizontal-scaling http://www.slideshare.net/nixnutz/mysql-57-fabric-high-availability-and-sharding MySQL Fabric: Blogs http://mysqlmusings.blogspot.com/2013/09/brief-introduction-to-mysql-fa ...

B-TREE

 
用crtdbg定位内存泄露错误 http://blog.sina.com.cn/s/blog_6ce6d0bf01016w33.html 定位内存泄露 http://blog.sina.com.cn/s/blog_6ce6d0bf01016vm1.html B树的C实现 http://blog.csdn.net/v_july_v/article/details/6735293 从B树、B+树、B*树谈到R 树 http://blog.csdn.net/v_JULY_v/article/details/6530142 B+树(C++实现) http://blog.csdn.net/l ...
Introduction to Transaction Locks in InnoDB Storage Engine https://blogs.oracle.com/mysqlinnodb/entry/introduction_to_transaction_locks_in Multiple granularity locking http://en.wikipedia.org/wiki/Multiple_granularity_locking Oracle多粒度锁机制 http://blog.csdn.net/xuxiaofei77/article/details/5569736 O ...
Global site tag (gtag.js) - Google Analytics