通常我们使用centos来组建LNMP,但是我们开发时多使用ubuntu的桌面版本来调试,下面将详细介绍如何在ubuntu上安装一套LNMP。
一、下载并安装最新的ubuntu14.04桌面版本
二、安装mysql
1. 下载mysql的最新版本,例如:
wget
http://dl.mysql.cn/mysql5/5.5/mysql-5.5.25.tar.gz
2. 解压缩:
t...
分类:
其他好文 时间:
2014-05-13 08:07:02
阅读次数:
423
UC正式推广官方技术博客,隐藏多年的浏览器技术开始陆续对外发布。...
分类:
其他好文 时间:
2014-05-13 06:49:04
阅读次数:
199
mysql高性能优化之多表连接拆分为多个单表查询...
分类:
数据库 时间:
2014-05-13 05:22:57
阅读次数:
386
在MySql和Sqlite中,可以用limit来查询第m条开始取n条的记录,如select*frommytablelimit1,3;但是在SQLServer中不支持limit语句,SQLServer支持Top,可以通过使用Top的嵌套来实现与limit相同的功能。如要取mytable表中的前10条记录,SQL中的语句如下:selecttop10frommytable如..
分类:
数据库 时间:
2014-05-13 04:37:46
阅读次数:
397
#!/bin/bash
#checkmysqlslavestatus
USER="check"
PSW="***"
RUNTIME=3600
ADDR="192.168.*.*"
declare-aslave_is
forIPin$ADDR
do
slave_is=($(/usr/local/mysql/bin/mysql-h$IP-u${USER}-p${PSW}-e"showslavestatus\G"|grepRunning|awk‘{print$2}‘))
if["${slave_is[0]}"="Y..
分类:
数据库 时间:
2014-05-13 04:33:44
阅读次数:
374
#!/usr/bin/envpython#coding:utf8importos,sys,glob,time,MySQLdb,reDIRNAME=os.path.dirname(__file__)OPSTOOLS_DIR=os.path.abspath(os.path.join(DIRNAME,‘..‘))sys.path.append(OPSTOOLS_DIR)fromlibrary.mysqlconfigimportMySQLDConfig,getMyVariablesfromoptparseimport..
分类:
数据库 时间:
2014-05-13 02:46:59
阅读次数:
809
#!/usr/bin/envpython#coding:utf8importos,sysimportdatetime,shutil,subprocessfromconfig.configimportslow_configclasscut_mysql(object):mysql_user,mysql_pass,date_day,slow_log_name,slow_log_path,mysqlsla_log_name,mysqldumpslow_log_name,new_log_path,new_log_nam..
分类:
数据库 时间:
2014-05-13 02:39:47
阅读次数:
482
#!/usr/bin/envpythonimporttime,MySQLdbfromsubprocessimportPopenfromsubprocessimportPIPEimportdns.queryimportdns.messageimportdns.tsigimportdns.tsigkeyringimportdns.updatedefset_dns(ip_list):key=dns.tsigkeyring.from_text({"cui.com":"SIvcwHj3goqYl0vKS6yOtdugx..
分类:
数据库 时间:
2014-05-13 02:04:53
阅读次数:
377
#!/usr/bin/envpython#coding:utf8importos,sysimportmd5,tabfrommysql_co.my_dbimportset_mysqlfromssh_co.ssh_connectimportsshdfromssh_co.cfg.configimportssh_message,item_pathfromfileimportfindfiledefmy_mysql():db_file={}my_connect=set_mysql()f_file=findfile.mai..
分类:
编程语言 时间:
2014-05-13 01:44:22
阅读次数:
449
MySQL集群1、Mysql集群中服务器的角色:客户端:访问集群,访问工具mysql数据节点:存储表中的记录,至少2台Sql节点:客户端访问集群的接口,至少2台管理节点:管理集群中的所有主机,1台2、实验环境准备5台服务器,操作系统rhel6,能够正常通信ServicemysqlstopChkconfigmysql..
分类:
数据库 时间:
2014-05-13 01:17:39
阅读次数:
507