[20170623]利用传输表空间恢复数据库2.txt

--//继续上午的测试,测试truncate,是否可行,理论讲应该没有问题.我主要的目的测试是否要切换日志.
--//参考链接 : http://blog.itpub.net/267265/viewspace-2141166/

1.环境:
SCOTT@book> @ &r/ver1
PORT_STRING                    VERSION        BANNER
------------------------------ -------------- --------------------------------------------------------------------------------
x86_64/Linux 2.4.xx            11.2.0.4.0     Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production

SCOTT@book> alter system archive log current ;
System altered.
--//测试前先切换一次日志.

SCOTT@book> select count(*) from t;
    COUNT(*)
------------
       84192

SCOTT@book> select current_scn,sysdate from v$database ;
 CURRENT_SCN SYSDATE
------------ -------------------
 13276962316 2017-06-23 15:21:54

SCOTT@book> truncate table t ;
Table truncated.

2.开始测试恢复:
$ mkdir /home/oracle/aux1

RMAN> transport tablespace tea tablespace destination '/home/oracle/aux1' auxiliary destination '/home/oracle/aux1' until scn 13276962316;

RMAN-05026: WARNING: presuming following set of tablespaces applies to specified point-in-time

List of tablespaces expected to have UNDO segments
Tablespace SYSTEM
Tablespace UNDOTBS1

Creating automatic instance, with SID='hFvw'

initialization parameters used for automatic instance:
db_name=BOOK
db_unique_name=hFvw_tspitr_BOOK
compatible=11.2.0.4.0
db_block_size=8192
db_files=200
sga_target=1G
processes=80
db_create_file_dest=/home/oracle/aux1
log_archive_dest_1='location=/home/oracle/aux1'
#No auxiliary parameter file used

starting up automatic instance BOOK

Oracle instance started

Total System Global Area    1068937216 bytes

Fixed Size                     2260088 bytes
Variable Size                285213576 bytes
Database Buffers             771751936 bytes
Redo Buffers                   9711616 bytes
Automatic instance created
Running TRANSPORT_SET_CHECK on recovery set tablespaces
TRANSPORT_SET_CHECK completed successfully

contents of Memory Script:
{
# set requested point in time
set until  scn 13276962316;
# restore the controlfile
restore clone controlfile;
# mount the controlfile
sql clone 'alter database mount clone database';
# archive current online log
sql 'alter system archive log current';
}
executing Memory Script

executing command: SET until clause

Starting restore at 2017-06-23 15:24:49
allocated channel: ORA_AUX_DISK_1
channel ORA_AUX_DISK_1: SID=127 device type=DISK
allocated channel: ORA_AUX_DISK_2
channel ORA_AUX_DISK_2: SID=133 device type=DISK
allocated channel: ORA_AUX_DISK_3
channel ORA_AUX_DISK_3: SID=139 device type=DISK

channel ORA_AUX_DISK_1: starting datafile backup set restore
channel ORA_AUX_DISK_1: restoring control file
channel ORA_AUX_DISK_1: reading from backup piece /u01/app/oracle/fast_recovery_area/BOOK/autobackup/2017_06_23/o1_mf_s_947414679_dns04qp7_.bkp
channel ORA_AUX_DISK_1: piece handle=/u01/app/oracle/fast_recovery_area/BOOK/autobackup/2017_06_23/o1_mf_s_947414679_dns04qp7_.bkp tag=TAG20170623T104439
channel ORA_AUX_DISK_1: restored backup piece 1
channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:01
output file name=/home/oracle/aux1/BOOK/controlfile/o1_mf_dnsjl28h_.ctl
Finished restore at 2017-06-23 15:24:51

sql statement: alter database mount clone database

sql statement: alter system archive log current

contents of Memory Script:
{
# set requested point in time
set until  scn 13276962316;
# set destinations for recovery set and auxiliary set datafiles
set newname for clone datafile  1 to new;
set newname for clone datafile  3 to new;
set newname for clone datafile  2 to new;
set newname for clone tempfile  1 to new;
set newname for datafile  6 to
 "/home/oracle/aux1/tea01.dbf";
# switch all tempfiles
switch clone tempfile all;
# restore the tablespaces in the recovery set and the auxiliary set
restore clone datafile  1, 3, 2, 6;
switch clone datafile all;
}
executing Memory Script

executing command: SET until clause

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

executing command: SET NEWNAME

renamed tempfile 1 to /home/oracle/aux1/BOOK/datafile/o1_mf_temp_%u_.tmp in control file

Starting restore at 2017-06-23 15:24:56
using channel ORA_AUX_DISK_1
using channel ORA_AUX_DISK_2
using channel ORA_AUX_DISK_3

channel ORA_AUX_DISK_1: starting datafile backup set restore
channel ORA_AUX_DISK_1: specifying datafile(s) to restore from backup set
channel ORA_AUX_DISK_1: restoring datafile 00003 to /home/oracle/aux1/BOOK/datafile/o1_mf_undotbs1_%u_.dbf
channel ORA_AUX_DISK_1: restoring datafile 00006 to /home/oracle/aux1/tea01.dbf
channel ORA_AUX_DISK_1: reading from backup piece /home/oracle/backup/full_20170623_f8s7gn1n_1_1.bak
channel ORA_AUX_DISK_2: starting datafile backup set restore
channel ORA_AUX_DISK_2: specifying datafile(s) to restore from backup set
channel ORA_AUX_DISK_2: restoring datafile 00001 to /home/oracle/aux1/BOOK/datafile/o1_mf_system_%u_.dbf
channel ORA_AUX_DISK_2: reading from backup piece /home/oracle/backup/full_20170623_f9s7gn1n_1_1.bak
channel ORA_AUX_DISK_3: starting datafile backup set restore
channel ORA_AUX_DISK_3: specifying datafile(s) to restore from backup set
channel ORA_AUX_DISK_3: restoring datafile 00002 to /home/oracle/aux1/BOOK/datafile/o1_mf_sysaux_%u_.dbf
channel ORA_AUX_DISK_3: reading from backup piece /home/oracle/backup/full_20170623_f7s7gn1n_1_1.bak
channel ORA_AUX_DISK_1: piece handle=/home/oracle/backup/full_20170623_f8s7gn1n_1_1.bak tag=TAG20170623T100023
channel ORA_AUX_DISK_1: restored backup piece 1
channel ORA_AUX_DISK_1: restore complete, elapsed time: 00:00:15
channel ORA_AUX_DISK_2: piece handle=/home/oracle/backup/full_20170623_f9s7gn1n_1_1.bak tag=TAG20170623T100023
channel ORA_AUX_DISK_2: restored backup piece 1
channel ORA_AUX_DISK_2: restore complete, elapsed time: 00:00:15
channel ORA_AUX_DISK_3: piece handle=/home/oracle/backup/full_20170623_f7s7gn1n_1_1.bak tag=TAG20170623T100023
channel ORA_AUX_DISK_3: restored backup piece 1
channel ORA_AUX_DISK_3: restore complete, elapsed time: 00:00:15
Finished restore at 2017-06-23 15:25:11

datafile 1 switched to datafile copy
input datafile copy RECID=17 STAMP=947431511 file name=/home/oracle/aux1/BOOK/datafile/o1_mf_system_dnsjl8cy_.dbf
datafile 3 switched to datafile copy
input datafile copy RECID=18 STAMP=947431511 file name=/home/oracle/aux1/BOOK/datafile/o1_mf_undotbs1_dnsjl8cp_.dbf
datafile 2 switched to datafile copy
input datafile copy RECID=19 STAMP=947431511 file name=/home/oracle/aux1/BOOK/datafile/o1_mf_sysaux_dnsjl8dc_.dbf
datafile 6 switched to datafile copy
input datafile copy RECID=20 STAMP=947431511 file name=/home/oracle/aux1/tea01.dbf

{
# set requested point in time
set until  scn 13276962316;
# online the datafiles restored or switched
sql clone "alter database datafile  1 online";
sql clone "alter database datafile  3 online";
sql clone "alter database datafile  2 online";
sql clone "alter database datafile  6 online";
# recover and open resetlogs
recover clone database tablespace  "TEA", "SYSTEM", "UNDOTBS1", "SYSAUX" delete archivelog;
alter clone database open resetlogs;
}
executing Memory Script

executing command: SET until clause

sql statement: alter database datafile  1 online

sql statement: alter database datafile  3 online

sql statement: alter database datafile  2 online

sql statement: alter database datafile  6 online

Starting recover at 2017-06-23 15:25:11
using channel ORA_AUX_DISK_1
using channel ORA_AUX_DISK_2
using channel ORA_AUX_DISK_3

starting media recovery
archived log for thread 1 with sequence 697 is already on disk as file /u01/app/oracle/archivelog/book/1_697_896605872.dbf
archived log for thread 1 with sequence 698 is already on disk as file /u01/app/oracle/archivelog/book/1_698_896605872.dbf
archived log for thread 1 with sequence 699 is already on disk as file /u01/app/oracle/archivelog/book/1_699_896605872.dbf
archived log for thread 1 with sequence 700 is already on disk as file /u01/app/oracle/archivelog/book/1_700_896605872.dbf
archived log for thread 1 with sequence 701 is already on disk as file /u01/app/oracle/archivelog/book/1_701_896605872.dbf
archived log for thread 1 with sequence 702 is already on disk as file /u01/app/oracle/archivelog/book/1_702_896605872.dbf
archived log for thread 1 with sequence 703 is already on disk as file /u01/app/oracle/archivelog/book/1_703_896605872.dbf
archived log for thread 1 with sequence 704 is already on disk as file /u01/app/oracle/archivelog/book/1_704_896605872.dbf
archived log for thread 1 with sequence 705 is already on disk as file /u01/app/oracle/archivelog/book/1_705_896605872.dbf
archived log for thread 1 with sequence 706 is already on disk as file /u01/app/oracle/archivelog/book/1_706_896605872.dbf
archived log for thread 1 with sequence 707 is already on disk as file /u01/app/oracle/archivelog/book/1_707_896605872.dbf
archived log for thread 1 with sequence 708 is already on disk as file /u01/app/oracle/archivelog/book/1_708_896605872.dbf
archived log for thread 1 with sequence 709 is already on disk as file /u01/app/oracle/archivelog/book/1_709_896605872.dbf
archived log file name=/u01/app/oracle/archivelog/book/1_697_896605872.dbf thread=1 sequence=697
archived log file name=/u01/app/oracle/archivelog/book/1_698_896605872.dbf thread=1 sequence=698
archived log file name=/u01/app/oracle/archivelog/book/1_699_896605872.dbf thread=1 sequence=699
archived log file name=/u01/app/oracle/archivelog/book/1_700_896605872.dbf thread=1 sequence=700
archived log file name=/u01/app/oracle/archivelog/book/1_701_896605872.dbf thread=1 sequence=701
archived log file name=/u01/app/oracle/archivelog/book/1_702_896605872.dbf thread=1 sequence=702
archived log file name=/u01/app/oracle/archivelog/book/1_703_896605872.dbf thread=1 sequence=703
archived log file name=/u01/app/oracle/archivelog/book/1_704_896605872.dbf thread=1 sequence=704
archived log file name=/u01/app/oracle/archivelog/book/1_705_896605872.dbf thread=1 sequence=705
archived log file name=/u01/app/oracle/archivelog/book/1_706_896605872.dbf thread=1 sequence=706
archived log file name=/u01/app/oracle/archivelog/book/1_707_896605872.dbf thread=1 sequence=707
archived log file name=/u01/app/oracle/archivelog/book/1_708_896605872.dbf thread=1 sequence=708
archived log file name=/u01/app/oracle/archivelog/book/1_709_896605872.dbf thread=1 sequence=709
media recovery complete, elapsed time: 00:00:04
Finished recover at 2017-06-23 15:25:16

database opened

contents of Memory Script:
{
# make read only the tablespace that will be exported
sql clone 'alter tablespace  TEA read only';
# create directory for datapump export
sql clone "create or replace directory STREAMS_DIROBJ_DPDIR as ''
/home/oracle/aux1''";
}
executing Memory Script

sql statement: alter tablespace  TEA read only

sql statement: create or replace directory STREAMS_DIROBJ_DPDIR as ''/home/oracle/aux1''
Performing export of metadata...
   EXPDP> Starting "SYS"."TSPITR_EXP_hFvw":
   EXPDP> Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
   EXPDP> Processing object type TRANSPORTABLE_EXPORT/TABLE
   EXPDP> Processing object type TRANSPORTABLE_EXPORT/POST_INSTANCE/PLUGTS_BLK
   EXPDP> Master table "SYS"."TSPITR_EXP_hFvw" successfully loaded/unloaded
   EXPDP> ******************************************************************************
   EXPDP> Dump file set for SYS.TSPITR_EXP_hFvw is:
   EXPDP>   /home/oracle/aux1/dmpfile.dmp
   EXPDP> ******************************************************************************
   EXPDP> Datafiles required for transportable tablespace TEA:
   EXPDP>   /home/oracle/aux1/tea01.dbf
   EXPDP> Job "SYS"."TSPITR_EXP_hFvw" successfully completed at Fri Jun 23 15:25:53 2017 elapsed 0 00:00:31
Export completed

/*
   The following command may be used to import the tablespaces.
   Substitute values for <logon> and <directory>.
   impdp <logon> directory=<directory> dumpfile= 'dmpfile.dmp' transport_datafiles= /home/oracle/aux1/tea01.dbf
*/
--------------------------------------------------------------
-- Start of sample PL/SQL script for importing the tablespaces
--------------------------------------------------------------
-- creating directory objects
CREATE DIRECTORY STREAMS$DIROBJ$1 AS  '/home/oracle/aux1/';
CREATE DIRECTORY STREAMS$DIROBJ$DPDIR AS  '/home/oracle/aux1';
/* PL/SQL Script to import the exported tablespaces */
DECLARE
  -- the datafiles
  tbs_files     dbms_streams_tablespace_adm.file_set;
  cvt_files     dbms_streams_tablespace_adm.file_set;
  -- the dumpfile to import
  dump_file     dbms_streams_tablespace_adm.file;
  dp_job_name   VARCHAR2(30) := NULL;
  -- names of tablespaces that were imported
  ts_names       dbms_streams_tablespace_adm.tablespace_set;
BEGIN
  -- dump file name and location
  dump_file.file_name :=  'dmpfile.dmp';
  dump_file.directory_object := 'STREAMS$DIROBJ$DPDIR';
  -- forming list of datafiles for import
  tbs_files( 1).file_name :=  'tea01.dbf';
  tbs_files( 1).directory_object :=  'STREAMS$DIROBJ$1';
  -- import tablespaces
  dbms_streams_tablespace_adm.attach_tablespaces(
    datapump_job_name      => dp_job_name,
    dump_file              => dump_file,
    tablespace_files       => tbs_files,
    converted_files        => cvt_files,
    tablespace_names       => ts_names);
  -- output names of imported tablespaces
  IF ts_names IS NOT NULL AND ts_names.first IS NOT NULL THEN
    FOR i IN ts_names.first .. ts_names.last LOOP
      dbms_output.put_line('imported tablespace '|| ts_names(i));
    END LOOP;
  END IF;
END;
/
-- dropping directory objects
DROP DIRECTORY STREAMS$DIROBJ$1;
DROP DIRECTORY STREAMS$DIROBJ$DPDIR;
--------------------------------------------------------------
-- End of sample PL/SQL script
--------------------------------------------------------------

Removing automatic instance
shutting down automatic instance
database closed
database dismounted
Oracle instance shut down
Automatic instance removed
auxiliary instance file /home/oracle/aux1/BOOK/datafile/o1_mf_temp_dnsjlx0l_.tmp deleted
auxiliary instance file /home/oracle/aux1/BOOK/onlinelog/o1_mf_3_dnsjlwnd_.log deleted
auxiliary instance file /home/oracle/aux1/BOOK/onlinelog/o1_mf_2_dnsjlwj5_.log deleted
auxiliary instance file /home/oracle/aux1/BOOK/onlinelog/o1_mf_1_dnsjlw9h_.log deleted
auxiliary instance file /home/oracle/aux1/BOOK/datafile/o1_mf_sysaux_dnsjl8dc_.dbf deleted
auxiliary instance file /home/oracle/aux1/BOOK/datafile/o1_mf_undotbs1_dnsjl8cp_.dbf deleted
auxiliary instance file /home/oracle/aux1/BOOK/datafile/o1_mf_system_dnsjl8cy_.dbf deleted
auxiliary instance file /home/oracle/aux1/BOOK/controlfile/o1_mf_dnsjl28h_.ctl deleted
--//OK,没有问题,上午不知道第一次问题在那里.

$ ls -l //u01/app/oracle/archivelog/book
total 215340
-rw-r----- 1 oracle oinstall    79360 2017-06-23 09:54:41 1_695_896605872.dbf
-rw-r----- 1 oracle oinstall 11775488 2017-06-23 09:59:36 1_696_896605872.dbf
-rw-r----- 1 oracle oinstall   101888 2017-06-23 10:01:06 1_697_896605872.dbf
-rw-r----- 1 oracle oinstall     7680 2017-06-23 10:01:18 1_698_896605872.dbf
-rw-r----- 1 oracle oinstall    13824 2017-06-23 10:01:43 1_699_896605872.dbf
-rw-r----- 1 oracle oinstall 11830272 2017-06-23 10:07:44 1_700_896605872.dbf
-rw-r----- 1 oracle oinstall   298496 2017-06-23 10:10:11 1_701_896605872.dbf
-rw-r----- 1 oracle oinstall    99328 2017-06-23 10:12:26 1_702_896605872.dbf
-rw-r----- 1 oracle oinstall   745984 2017-06-23 10:15:53 1_703_896605872.dbf
-rw-r----- 1 oracle oinstall 50181632 2017-06-23 10:24:41 1_704_896605872.dbf
-rw-r----- 1 oracle oinstall 50181632 2017-06-23 10:24:42 1_705_896605872.dbf
-rw-r----- 1 oracle oinstall 50181632 2017-06-23 10:24:44 1_706_896605872.dbf
-rw-r----- 1 oracle oinstall 38688768 2017-06-23 13:55:30 1_707_896605872.dbf
-rw-r----- 1 oracle oinstall  5877760 2017-06-23 15:21:37 1_708_896605872.dbf
-rw-r----- 1 oracle oinstall   141824 2017-06-23 15:24:55 1_709_896605872.dbf

--//从时间看,在做传输时自动执行了一次日志切换.从alert中也可以看出来:
Fri Jun 23 15:21:37 2017
ALTER SYSTEM ARCHIVE LOG
Fri Jun 23 15:21:37 2017
Beginning log switch checkpoint up to RBA [0x2c5.2.10], SCN: 13276962295
Thread 1 advanced to log sequence 709 (LGWR switch)
  Current log# 3 seq# 709 mem# 0: /mnt/ramdisk/book/redo03.log
Archived Log entry 1248 added for thread 1 sequence 708 ID 0x4fb7d86e dest 1:
Fri Jun 23 15:21:38 2017
Completed checkpoint up to RBA [0x2c5.2.10], SCN: 13276962295
Fri Jun 23 15:24:55 2017
ALTER SYSTEM ARCHIVE LOG
Fri Jun 23 15:24:55 2017
Beginning log switch checkpoint up to RBA [0x2c6.2.10], SCN: 13276962601
Thread 1 advanced to log sequence 710 (LGWR switch)
  Current log# 1 seq# 710 mem# 0: /mnt/ramdisk/book/redo01.log
Archived Log entry 1249 added for thread 1 sequence 709 ID 0x4fb7d86e dest 1:
Fri Jun 23 15:25:04 2017
Incremental checkpoint up to RBA [0x2c5.2.0], current log tail at RBA [0x2c6.a.0]
Fri Jun 23 15:29:53 2017
Completed checkpoint up to RBA [0x2c6.2.10], SCN: 13276962601

3.导入数据:
SCOTT@book> grant dba to ttt IDENTIFIED BY ttt;
Grant succeeded.

$ cp /home/oracle/aux1/dmpfile.dmp /u01/app/oracle/admin/book/dpdump/

impdp system/oracle dumpfile=dmpfile.dmp transport_datafiles=/home/oracle/aux1/tea01.dbf REMAP_TABLESPACE=TEA:MILK
REMAP_SCHEMA=scott:ttt logfile=impdp.log

$ impdp system/oracle dumpfile=dmpfile.dmp transport_datafiles=/home/oracle/aux1/tea01.dbf REMAP_TABLESPACE=TEA:MILK
REMAP_SCHEMA=scott:ttt logfile=impdp.log

Import: Release 11.2.0.4.0 - Production on Fri Jun 23 15:36:59 2017

Copyright (c) 1982, 2011, Oracle and/or its affiliates.  All rights reserved.

Connected to: Oracle Database 11g Enterprise Edition Release 11.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
Master table "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" successfully loaded/unloaded
Starting "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01":  system/a****** dumpfile=dmpfile.dmp
transport_datafiles=/home/oracle/aux1/tea01.dbf REMAP_TABLESPACE=TEA:MILK REMAP_SCHEMA=scott:ttt logfile=impdp.log
Processing object type TRANSPORTABLE_EXPORT/PLUGTS_BLK
Processing object type TRANSPORTABLE_EXPORT/TABLE
Processing object type TRANSPORTABLE_EXPORT/POST_INSTANCE/PLUGTS_BLK
Job "SYSTEM"."SYS_IMPORT_TRANSPORTABLE_01" successfully completed at Fri Jun 23 15:37:03 2017 elapsed 0 00:00:03

--//ok,成功!!

4.测试:
SCOTT@book> select count(*) from scott.t;
    COUNT(*)
------------
           0

SCOTT@book> select count(*) from ttt.t;
    COUNT(*)
------------
       84192

--//可以发现测试ok.可以发现rman的transport tablespace还是很简单的,封装的复杂的命令.
--//至于上午第一次失败,无法在重新再现了,放弃探究.

[20170623]利用传输表空间恢复数据库2.txt的更多相关文章

  1. [20170623]利用传输表空间恢复部分数据.txt

    [20170623]利用传输表空间恢复部分数据.txt --//昨天我测试使用传输表空间+dblink,上午补充测试发现表空间设置只读才能执行impdp导入原数据,这个也很好理解.--//这样的操作模 ...

  2. 转://RMAN跨平台可传输表空间和数据库

    参考链接: http://blog.itpub.net/23135684/viewspace-776048/ http://blog.sina.com.cn/s/blog_69e7b8d7010164 ...

  3. 如何通过RMAN使用传输表空间迁移到不同的Endian平台 (Doc ID 371556.1)

    How to Migrate to different Endian Platform Using Transportable Tablespaces With RMAN (Doc ID 371556 ...

  4. mysql5.6之 传输表空间迁移表或恢复误删除的表

    一,简单说明: 1),传输表空间的限制:  1,mysql 版本 5.6.6 及其以上,并且版本建议源和目标版本建议都是GA版并且大版本一样  2,表引擎为innodb并且开启独立表空间  innod ...

  5. 转 Oracle Transportable TableSpace(TTS) 传输表空间 说明

    ############1   迁移数据库的集中方法 三.相关技术 迁移方式 优势 不足1 Export and import • 对数据库版本,以及系统平台没有要求 • 不支持并发,速度慢• 停机时 ...

  6. 【TTS】传输表空间AIX asm -> linux asm

    [TTS]传输表空间AIX asm -> linux asm 一.1  BLOG文档结构图       一.2  前言部分   一.2.1  导读和注意事项 各位技术爱好者,看完本文后,你可以掌 ...

  7. 【TTS】传输表空间Linux asm -> AIX asm

    [TTS]传输表空间Linux asm -> AIX asm 一.1  BLOG文档结构图       一.2  前言部分   一.2.1  导读和注意事项 各位技术爱好者,看完本文后,你可以掌 ...

  8. oracle expdp/impdp/可传输表空间

    oracle expdp/impdp/可传输表空间/及一些参数 Oracle data pump 导出操作能够将表.索引.约束.权限.PLSQL包.同义词等对象从数据库导出,并将它们保存在一种非文本格 ...

  9. oracle操作之传输表空间

    一.传输表空间概述 什么是传输表空间,传输表空间技术始于oracle9i,不论是数据字典管理的表空间还是本地管理的表空间,都可以使用传输表空间技术:传输表空间不需要在源数据库和目标数据库之间具有同样的 ...

随机推荐

  1. Nginx + Keepalived负载均衡

    第一步: 下载keepalived地址:http://www.keepalived.org/download.html 解压安装: tar -zxvf keepalived-1.2.18.tar.gz ...

  2. tcp 三次握手 四次挥手

    TCP协议中的三次握手和四次挥手 建立TCP需要三次握手才能建立,而断开连接则需要四次挥手. 三次握手,建立连接 首先Client发送连接请求报文,Server端接收连接后回复ACK报文,并为这次连接 ...

  3. gulp和grunt 分享ppt

    gulp是前端开发过程中对代码进行构建的工具,是自动化项目的构建利器:她不仅能对网站资源进行优化,而且在开发过程中很多重复的任务能够使用正确的工具自动完成:使用她,我们不仅可以很愉快的编写代码,而且大 ...

  4. myslide 插件开发知识点总结和 css3 动画性能问题的研究

    myslide 插件开发知识点总结和 css3 动画性能问题的研究 这篇文章主要是总结最近开发过程中遇到的问题.有几个问题又是不容易发现原因的问题,但是最后的结果又是很简单的. 1.手机端的 slid ...

  5. PHP-CPP开发扩展(二)

    PHP-CPP是一个用于开发PHP扩展的C++库.本节讲解PHP输出和函数的实现. 输出和错误 上面的helloworld示例里,我们使用Php::out进行输出,并使用了std::endl换行刷新缓 ...

  6. Haproxy+Heartbeat 高可用集群方案操作记录

    之前详细介绍了haproxy的基础知识点, 下面记录下Haproxy+Heartbeat高可用web集群方案实现过程, 以加深理解. 架构草图如下: 1) 基本环境准备 (centos6.9系统) 1 ...

  7. Java 容器源码分析之Map-Set-List

    HashMap 的实现原理 HashMap 概述 HashMap 是基于哈希表的 Map 接口的非同步实现.此实现提供所有可选的映射操作,并允许使用 null 值和 null 键.此类不保证映射的顺序 ...

  8. 将应用代码由eclipse导入Android studio的方法NDK-Build和Cmake两种方法(以android_serialport_api为例)

    网上翻了几百篇博客,看了半天,要不就是写的乱七八糟看不懂,要不就是隐藏了一些细节,要不就是实现不了,最后还是在Android官网上看明白了,而且说得有条有理,以后遇到不懂的一定要先翻官网. 参考资料: ...

  9. 多啦爱梦~多啦A梦CSS3测试源代码

    先直接看图片,感觉一下!一直以来,我们都在说浏览器对CSS3支持度这个问题.可是,鉴于知识认识水平问题,又没几个人真正了解CSS3是什么东西,和它在网站显示上的重要性.现在好了,日本某位大神写了个CS ...

  10. 数据库设计---PowerDesigner(物理模型和概念模型)

    内容 第一种方法:概念模型转物理模型 1.首先新建模型--选择概念模型(CDM)   2.新建实体(学生和卡),设置相应的属性         3.一共四种关系(1:1,1:n,n:1,n:n),根据 ...