mysql二进制安装,升级,多实例部署
- 理解线上部署考虑的因素
- 学会编译安装以及二进制安装mysql
- 学会升级mysql
- 学会多实例部署mysql数据库
- 学会合理部署mysql线上库
- 版本选择,5.1,5.5还是5.6?
- 分支选择,官方社区版?percona server?mariadb?
- 推荐官方版,简单易上手
- 安装方式,包安装?二进制包安装?源码安装?
- 线上推荐二进制包安装
- 路径配置,参数配置(尽量模板化,标准化)
- 一个实例多个库,or多个实例单个库?
- 下载软件安装包
- 解压放到指定目录(比如/usr/local)并将mysql目录放到PATH中
- 初始化实例,编辑配置文件 并启动
- 账号安全设置
#tar -zxf mysql-5.5.-linux2.-i686.tar.gz
#mv mysql-5.5.-linux2.-i686 /usr/local/
#cd /usr/local
#mv mysql-5.5.-linux2.-i686 mysql55
#cd mysql55/bin
#export PATH=/usr/local/mysql55/bin:$PATH
#mkdir -p /tmp/mysqldata/node1
#/usr/local/mysql55/script/mysql_install_db --user=mysql --basedir=/usr/local/mysql55 --datadir=/tmp/mysqldata/node1
#cd /tmp/mysqldata/node1
/tmp/mysql55/bin/mysqld: error while loading shared libraries: libaio.so.: cannot open shared object file: No such file or directory
aiapple@aiapple:/tmp$ sudo apt-cache search libaio
libaio-dev - Linux kernel AIO access library - development files
libaio1 - Linux kernel AIO access library - shared library
libaio1-dbg - Linux kernel AIO access library - debugging symbols
aiapple@aiapple:/tmp$ sudo apt-get install libaio1
aiapple@aiapple:/usr/local/mysql/data$ ls -l /tmp/mysqldata/node1/
total
drwx------ aiapple aiapple 7月 : mysql
drwx------ aiapple aiapple 7月 : performance_schema
drwx------ aiapple aiapple 7月 : test
cp /usr/local/mysql56/support-files/my-medium.cnf /tmp/mysqldata
/usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
aiapple@aiapple:/usr/local/mysql55/support-files$ /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
[]
aiapple@aiapple:/usr/local/mysql55/support-files$ :: mysqld_safe Logging to '/usr/local/mysql/data/aiapple.err'.
touch: cannot touch ‘/usr/local/mysql/data/aiapple.err’: No such file or directory
chmod: cannot access ‘/usr/local/mysql/data/aiapple.err’: No such file or directory
:: mysqld_safe The file /usr/local/mysql/bin/mysqld
does not exist or is not executable. Please cd to the mysql installation
directory and restart this script from there as follows:
./bin/mysqld_safe&
See http://dev.mysql.com/doc/mysql/en/mysqld-safe.html for more information
/usr/local/mysql55/bin/mysqld_safe: : /usr/local/mysql55/bin/mysqld_safe: cannot create /usr/local/mysql/data/aiapple.err: Directory nonexistent
^C
[]+ Exit /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple@aiapple:/usr/local$ sudo mkdir -p mysql/data
aiapple@aiapple:/usr/local/mysql$ sudo chown -R aiapple .
aiapple@aiapple:/usr/local/mysql$ sudo chgrp -R aiapple .
aiapple@aiapple:/usr/local/mysql$ /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
[]
aiapple@aiapple:/usr/local/mysql$ :: mysqld_safe Logging to '/usr/local/mysql/data/aiapple.err'.
:: mysqld_safe The file /usr/local/mysql/bin/mysqld
does not exist or is not executable. Please cd to the mysql installation
directory and restart this script from there as follows:
./bin/mysqld_safe&
See http://dev.mysql.com/doc/mysql/en/mysqld-safe.html for more information
^C
[]+ Exit /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple@aiapple:/usr/local/mysql$ cp -ar ../mysql55/* .
aiapple@aiapple:/usr/local/mysql$ /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
[]
aiapple@aiapple:/usr/local/mysql$ :: mysqld_safe Logging to '/usr/local/mysql/data/aiapple.err'.
:: mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data
:: mysqld_safe mysqld from pid file /usr/local/mysql/data/aiapple.pid ended []+ Done /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
且mysqld没有启动
aiapple@aiapple:~$ ps -ef | grep mysqld
aiapple : pts/ :: grep --color=auto mysqld
:: mysqld_safe Starting mysqld daemon with databases from /usr/local/mysql/data
:: [Note] /usr/local/mysql/bin/mysqld (mysqld 5.5.-log) starting as process ...
:: [Note] Plugin 'FEDERATED' is disabled.
/usr/local/mysql/bin/mysqld: Table 'mysql.plugin' doesn't exist
:: [ERROR] Can't open the mysql.plugin table. Please run mysql_upgrade to create it.
:: InnoDB: The InnoDB memory heap is disabled
:: InnoDB: Mutexes and rw_locks use GCC atomic builtins
:: InnoDB: Compressed tables use zlib 1.2.
:: InnoDB: Using Linux native AIO
:: InnoDB: Initializing buffer pool, size = 128.0M
:: InnoDB: Completed initialization of buffer pool
:: InnoDB: highest supported file format is Barracuda.
InnoDB: Log scan progressed past the checkpoint lsn
:: InnoDB: Database was not shut down normally!
InnoDB: Starting crash recovery.
InnoDB: Reading tablespace information from the .ibd files...
InnoDB: Restoring possible half-written data pages from the doublewrite
InnoDB: buffer...
InnoDB: Doing recovery: scanned up to log sequence number
:: InnoDB: Starting an apply batch of log records to the database...
InnoDB: Progress in percents:
InnoDB: Apply batch completed
:: InnoDB: Waiting for the background threads to start
:: InnoDB: 5.5. started; log sequence number
:: [Note] Recovering after a crash using mysql-bin
:: [Note] Starting crash recovery...
:: [Note] Crash recovery finished.
:: [Note] Server hostname (bind-address): '0.0.0.0'; port:
:: [Note] - '0.0.0.0' resolves to '0.0.0.0';
:: [Note] Server socket created on IP: '0.0.0.0'.
:: [ERROR] Fatal error: Can't open and lock privilege tables: Table 'mysql.host' doesn't exist
:: mysqld_safe mysqld from pid file /usr/local/mysql/data/aiapple.pid ended
aiapple@aiapple:/usr/local/mysql/data$ rm -rf test/
aiapple@aiapple:/usr/local/mysql/data$ cp -ar /tmp/mysqldata/node1/* .
aiapple@aiapple:/usr/local/mysql/data$ ps -ef | grep mysqld
aiapple : pts/ :: /bin/sh /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple : pts/ :: /usr/local/mysql/bin/mysqld --defaults-file=/tmp/mysqldata/my.cnf --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --log-error=/usr/local/mysql/data/aiapple.err --pid-file=/usr/local/mysql/data/aiapple.pid --socket=/tmp/mysql.sock --port=
aiapple : pts/ :: grep --color=auto mysqld
[client]
#password = your_password
port =
socket = /tmp/mysql.sock # Here follows entries for some specific programs # The MySQL server
[mysqld]
port =
socket = /tmp/mysql.sock
skip-external-locking
key_buffer_size = 16M
max_allowed_packet = 1M
table_open_cache =
sort_buffer_size = 512K
net_buffer_length = 8K
read_buffer_size = 256K
read_rnd_buffer_size = 512K
myisam_sort_buffer_size = 8M
my.cnf
port =
socket = /tmp/mysqldata/node1/mysql.sock [mysqld_safe]
user=aiapple # Here follows entries for some specific programs # The MySQL server
[mysqld]
port =
socket = /tmp/mysqldata/node1/mysql.sock
pid-file = /tmp/mysqldata/node1/mysqld.pid
basedir = /usr/local/mysql55
datadir = /tmp/mysqldata/node1
innodb_data_home_dir = /tmp/mysqldata/node1
innodb_log_group_home_dir =/tmp/mysqldata/node1
tmpdir = /tmp/mysqldata/node1
log-error = /tmp/mysqldata/node1/aiapple.log
log-bin = /tmp/mysqldata/node1/mysql-bin.log
aiapple@aiapple:/usr/local/mysql$ /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
Warning: World-writable config file '/tmp/mysqldata/my.cnf' is ignored
aiapple@aiapple:sudo chmod /tmp/mysqldata/my.cnf
aiapple@aiapple:/usr/local/mysql$ /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
:: mysqld_safe The file /usr/local/mysql/bin/mysqld does not exist or is not executable. Please cd to the mysql installation
directory and restart this script from there as follows: ./bin/mysqld_safe&
#my.cnf增加
ledir = /usr/local/mysql55
:: [Note] Plugin 'FEDERATED' is disabled.
:: InnoDB: The InnoDB memory heap is disabled
:: InnoDB: Mutexes and rw_locks use GCC atomic builtins
:: InnoDB: Compressed tables use zlib 1.2.
:: InnoDB: Using Linux native AIO
:: InnoDB: Initializing buffer pool, size = 128.0M
#my.cnf增加
nice =
mysql -uroot --socket=/tmp/mysql.sock
select user,host,password from mysql.user;
delete from mysql.user where user='';
delete from mysql.user where host<>'localhost'; mysql> select user,host,password from mysql.user;
+------+-----------+----------+
| user | host | password |
+------+-----------+----------+
| root | localhost | |
+------+-----------+----------+
row in set (0.00 sec)
mysql> set password for root@'localhost'=password('');
Query OK, rows affected (0.00 sec)
flush privileges;
创建test用户
#mysql -uroot -p123456--socket=/tmp/mysql.sock
grant select on *.* to test@'localhost' identified by ''; 使用test用户,在test库中建表
#mysql -utest -p123 --socket=/tmp/mysql.sock
use test
create table t1(id int);
mysql> show tables;
+----------------+
| Tables_in_test |
+----------------+
| t1 |
+----------------+
row in set (0.01 sec)
mysql> drop database test;
Query OK, row affected (0.01 sec)
- 下载mysql5.6安装包并配置mysql5.6安装包安装路径
- 关闭mysql5.5的实例,修改部分参数,使用mysql5.6软件启动
- 执行mysql5.6路径下mysql_upgrade脚本
- 验证是否成功升级
aiapple@aiapple:/tmp/mysqldata$ ps -ef | grep mysqld
aiapple : pts/ :: /bin/sh /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple : pts/ :: /usr/local/mysql/bin/mysqld --defaults-file=/tmp/mysqldata/my.cnf --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --plugin-dir=/usr/local/mysql/lib/plugin --log-error=/usr/local/mysql/data/aiapple.err --pid-file=/usr/local/mysql/data/aiapple.pid --socket=/tmp/mysql.sock --port=
aiapple : pts/ :: grep --color=auto mysqld
aiapple@aiapple:/usr/local/mysql$ mysqladmin -uroot --socket=/tmp/mysql.sock shutdown -p
Enter password:
:: mysqld_safe mysqld from pid file /usr/local/mysql/data/aiapple.pid ended
[]+ Done /usr/local/mysql55/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf (wd: /usr/local/mysql/data)
(wd now: /usr/local/mysql)
aiapple@aiapple:/usr/local/mysql$ ps -ef | grep mysqld
aiapple : pts/ :: grep --color=auto mysqld
#vim my.cnf(把55目录都改成56的)
aiapple@aiapple:/tmp/mysqldata$ /usr/local/mysql56/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf &
[]
aiapple@aiapple:/tmp/mysqldata$ :: mysqld_safe Logging to '/tmp/mysqldata/node1/aiapple.log'.
:: mysqld_safe Starting mysqld daemon with databases from /tmp/mysqldata/node1
aiapple@aiapple:/tmp/mysqldata$ ps -ef | grep mysql
aiapple : pts/ :: /bin/sh /usr/local/mysql56/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple : pts/ :: /usr/local/mysql56/bin/mysqld --defaults-file=/tmp/mysqldata/my.cnf --basedir=/usr/local/mysql56 --datadir=/tmp/mysqldata/node1 --plugin-dir=/usr/local/mysql56/lib/plugin --log-error=/tmp/mysqldata/node1/aiapple.log --pid-file=/tmp/mysqldata/node1/mysqld.pid --socket=/tmp/mysqldata/node1/mysql.sock --port=
aiapple : pts/ :: grep --color=auto mysql
mysql> status
--------------
mysql Ver 14.14 Distrib 5.6., for linux-glibc2. (x86_64) using EditLine wrapper Connection id:
Current database:
Current user: root@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ''
Using delimiter: ;
Server version: 5.6.-log MySQL Community Server (GPL)
Protocol version:
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: latin1
Client characterset: utf8
Conn. characterset: utf8
UNIX socket: /tmp/mysqldata/node1/mysql.sock
Uptime: min sec Threads: Questions: Slow queries: Opens: Flush tables: Open tables: Queries per second avg: 0.011
--------------
aiapple@aiapple:/tmp/mysqldata$ /usr/local/mysql56/bin/mysql_upgrade -uroot --socket=/tmp/mysqldata/node1/mysql.sock -p
Enter password:
Looking for 'mysql' as: /usr/local/mysql56/bin/mysql
Looking for 'mysqlcheck' as: /usr/local/mysql56/bin/mysqlcheck
Running 'mysqlcheck' with connection arguments: '--socket=/tmp/mysqldata/node1/mysql.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--socket=/tmp/mysqldata/node1/mysql.sock'
Warning: Using a password on the command line interface can be insecure.
mysql.columns_priv OK
mysql.db OK
mysql.event OK
mysql.func OK
mysql.general_log OK
mysql.help_category OK
mysql.help_keyword OK
mysql.help_relation OK
mysql.help_topic OK
mysql.host OK
mysql.ndb_binlog_index OK
mysql.plugin OK
mysql.proc OK
mysql.procs_priv OK
mysql.proxies_priv OK
mysql.servers OK
mysql.slow_log OK
mysql.tables_priv OK
mysql.time_zone OK
mysql.time_zone_leap_second OK
mysql.time_zone_name OK
mysql.time_zone_transition OK
mysql.time_zone_transition_type OK
mysql.user OK
Running 'mysql_fix_privilege_tables'...
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--socket=/tmp/mysqldata/node1/mysql.sock'
Warning: Using a password on the command line interface can be insecure.
Running 'mysqlcheck' with connection arguments: '--socket=/tmp/mysqldata/node1/mysql.sock'
Warning: Using a password on the command line interface can be insecure.
OK
aiapple@aiapple:/tmp/mysqldata$ /usr/local/mysql56/bin/mysql_upgrade -uroot --socket=/tmp/mysqldata/node1/mysql.sock -p
Enter password:
Looking for 'mysql' as: /usr/local/mysql56/bin/mysql
Looking for 'mysqlcheck' as: /usr/local/mysql56/bin/mysqlcheck
This installation of MySQL is already upgraded to 5.6., use --force if you still need to run mysql_upgrade
- 部署好mysql软件
- 编辑多个配置文件,初始化多个实例
- 启动mysql实例
- 充分利用系统资源
- 资源隔离
- 业务,模块隔离
#mkdir -p /mysqldata/node3
aiapple@aiapple:/tmp/mysqldata/node1$ /usr/local/mysql56/scripts/mysql_install_db --user=aiapple --basedir=/usr/local/mysql56 --datadir=/tmp/mysqldata/node3
#查看
aiapple@aiapple:/tmp/mysqldata/node1$ ls ../node3
ibdata1 ib_logfile0 ib_logfile1 mysql performance_schema test
cp my2.cnf my3.cnf
vim my3.cnf(修改相关参数)
[client]
#password = your_password
port =
socket = /tmp/mysqldata/node3/mysql.sock [mysqld_safe]
user=aiapple
ledir = /usr/local/mysql56/bin
#ledir = /usr/local/mysql55/bin
nice =
# Here follows entries for some specific programs # The MySQL server
[mysqld]
port =
socket = /tmp/mysqldata/node3/mysql.sock
pid-file = /tmp/mysqldata/node3/mysqld.pid
basedir = /usr/local/mysql56
#basedir = /usr/local/mysql55
datadir = /tmp/mysqldata/node3
innodb_data_home_dir = /tmp/mysqldata/node3
innodb_log_group_home_dir = /tmp/mysqldata/node3
tmpdir = /tmp/mysqldata/node3
log-error = /tmp/mysqldata/node3/aiapple.log
log-bin = /tmp/mysqldata/node3/mysql-bin.log
aiapple@aiapple:/tmp/mysqldata/node3$ /usr/local/mysql56/bin/mysqld_safe --defaults-file=/tmp/mysqldata/node3/my3.cnf &
[]
aiapple@aiapple:/tmp/mysqldata/node3$ :: mysqld_safe Logging to '/tmp/mysqldata/node3/aiapple.log'.
:: mysqld_safe Starting mysqld daemon with databases from /tmp/mysqldata/node3
aiapple@aiapple:/tmp/mysqldata/node3$ ps -ef | grep mysqld
aiapple : pts/ :: /bin/sh /usr/local/mysql56/bin/mysqld_safe --defaults-file=/tmp/mysqldata/my.cnf
aiapple : pts/ :: /usr/local/mysql56/bin/mysqld --defaults-file=/tmp/mysqldata/my.cnf --basedir=/usr/local/mysql56 --datadir=/tmp/mysqldata/node1 --plugin-dir=/usr/local/mysql56/lib/plugin --log-error=/tmp/mysqldata/node1/aiapple.log --pid-file=/tmp/mysqldata/node1/mysqld.pid --socket=/tmp/mysqldata/node1/mysql.sock --port=
aiapple : pts/ :: /bin/sh /usr/local/mysql56/bin/mysqld_safe --defaults-file=/tmp/mysqldata/node3/my3.cnf
aiapple : pts/ :: /usr/local/mysql56/bin/mysqld --defaults-file=/tmp/mysqldata/node3/my3.cnf --basedir=/usr/local/mysql56 --datadir=/tmp/mysqldata/node3 --plugin-dir=/usr/local/mysql56/lib/plugin --log-error=/tmp/mysqldata/node3/aiapple.log --pid-file=/tmp/mysqldata/node3/mysqld.pid --socket=/tmp/mysqldata/node3/mysql.sock --port=
aiapple : pts/ :: grep --color=auto mysqld 可以看到有两个端口的mysqld,分别是3306,;
aiapple@aiapple:/tmp/mysqldata/node3$ mysql -uroot --socket=/tmp/mysqldata/node3/mysql.sock
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is
Server version: 5.6.-log MySQL Community Server (GPL) Copyright (c) , , Oracle and/or its affiliates. All rights reserved. Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners. Type 'help;' or '\h' for help. Type '\c' to clear the current input statement. delete from msyql.user where user='';
delete from mysql.user where host<>'localhost';
set password for root@'localhost'=password('');
delete from mysql.db;
drop database test;
flush privileges;
- 根据需求选择合适的版本以及分支,建议使用或升级到较高版本5.5或5.6
- 如果需要定制mysql功能的话,可以考虑编译安装,否则的话建议使用二进制包安装,比较省事。
- 根据机器配置选择部署多个mysql实例还是单个实例,机器配置非常好的话,建议部署多实例
mysql二进制安装,升级,多实例部署的更多相关文章
- mysql二进制安装及基础操作
mysql二进制安装及基础操作 环境说明: 系统版本 CentOS 6.9 x86_64 软件版本 mysql-5.6.36-linux-glibc2.5-x86_64 1.安装 采用二进 ...
- Linux中MySQL二进制安装步骤
MySQL二进制安装步骤 安装依赖环境 [root@node3 ~]# yum -y install libaio 将mysql-5.7.26-linux-glibc2.12-x86_64.tar.g ...
- MySQL二进制安装脚本
MySQL二进制包自行百度,晚上很多查找办法 #!/bin/bash #二进制安装mysql并初始化密码为123456 mysql_name=mysql-5.7.31-linux-glibc2.12- ...
- MySQL二进制安装部署
#使用二进制包安装mysql -linux-glibc2.-x86_64.tar.gz /data/ -linux-glibc2.-x86_64.tar.gz -C /data/ -linux-gli ...
- mysql 二进制安装文件 下载
在linuex环境下安装mysql,二进制安装包是最合适的方式,下载下来不用编译就可用了. 官方说明文档:http://dev.mysql.com/doc/refman/5.1/en/binary-i ...
- MySQL二进制安装
前提 version mysql-5.5 platform centos6.x 添加用户 useradd -M -s /sbin/nologin mysql 安装需要的包 yum -y install ...
- mysql 二进制安装的基本步骤
-1 mysql数据库位置 二进制包:/usr/local/mysql/data 这里手动创建新的位置: 创建一个新的lv,挂在点:mydat ...
- MYSQL 二进制安装
系统环境:CentOs6.7 i386 Mysql版本:mysql-5.6.36 root登录linux cd pwd #/root/ wget http://mirrors.sohu.com/mys ...
- mysql二进制安装方法
Linux centos7环境下MySQL安装教程 一.安装依赖包: a.boost_1_59_0下载:wget http://nchc.dl.sourceforge.net/project/boos ...
随机推荐
- 【Combination Sum 】cpp
题目: Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C ...
- C语言其他知识总结
1.常指针与指针常量 诀窍:观察const修饰的是谁,那谁就不可更改. const int *p;//const 修饰*p,所以*p不能更改.通过指针不可更改指向的值 int const *p;//同 ...
- 用sqlmap跑post型注入
bugku-成绩单 题目地址 手工注入: ①看到题目,分别提交1,2,3,出现不同的成绩单,可见参数我们是可以控制,通过POST的方式. ②我们尝试输入1 and 1=1#和1 and 1=2#发现不 ...
- python矩阵和向量的转置问题
numpy有很多方法进行转置,这里由于时间和精力限制(主要是我实在比较懒,有一个基本上一直能使的,就懒得看其他的了),其他方法我没研究,这里我总结的东西,如果有问题,欢迎各路大佬拍砖 一.创建矩阵: ...
- Leetcode 623.在二叉树中增加一行
在二叉树中增加一行 给定一个二叉树,根节点为第1层,深度为 1.在其第 d 层追加一行值为 v 的节点. 添加规则:给定一个深度值 d (正整数),针对深度为 d-1 层的每一非空节点 N,为 N 创 ...
- RNQOJ Jam的计数法
题目:https://www.rqnoj.cn/problem/3 非递归做法:(严格递增 单调大于 不可等于 ) 做法:循环体 <1>操作字符串 str 从后往前找,k=1,如果s[w ...
- Excel的数据批量替换
该篇文章照抄自:http://www.cnblogs.com/xwgli/p/5845317.html 在 Excel 中使用正则表达式进行查找与替换 在 Excel 中,使用 Alt+F11 快捷 ...
- selenium webdriver——控制浏览器
from selenium import webdriver import time def controlBrowser(): #启动浏览器 driver = webdriver.Firefox() ...
- 201621123034 《Java程序设计》第2周学习总结
1. 本周学习总结 本周学习了基本数据类型.包装类,自动装箱与自动拆箱.数组.ArrayList.包装类可以更加方便的转换基本数据类型,而其存放的是对象的引用,而非对象本身,在对其内容进行比较时,要使 ...
- nginx访问控制allow、deny(ngx_http_access_module)
单看nginx模块名ngx_http_access_module,很多人一定很陌生,但是deny和allow相比没一个人不知道的,实际上deny和allow指令属于ngx_http_access_mo ...