sql2005降级sql2000 (没有亲手测试过)
[
|
2009/12/08 12:01]
|
2009/12/08 12:01]
查看文章
SQL Server 2005数据库降级转到SQL Server 2000
2008-11-07 14:37
SQL Server 2000 数据库 => SQL Server 2005 数据库
在SQL Server 2005的Management Studio中新建一个数据库,右键选择“任务”->“复制数据库”。
SQL Server 2005 数据库 => SQL Server2000 数据库
安装SQL2000, 然后把数据库重新附加,存储过程(如果在2005中你没有使用新增功能,这个在2000中是能完全运行的),这样就行了,你可以试试
上面的方法不行,报错:
“错误602:未能在sysindexes 中找到数据库ID 15 中对象ID 1的索引ID 1 对应的行。请对sysindexes运行DBCC CHECKTABLE。”
解决方案:
因为数据库附加到2005的时候, 数据库文件已经自动升级到2005, 所以在2000下是无法再附加的(没有向上兼容的)直接restore或附加是不行的, 用脚本+导数据肯定没有问题。
2005转到2000的步骤步骤
1. 生成for 2000版本的数据库脚本
2005 的manger studio
-- 打开"对象资源管理器"(没有的话按F8), 连接到你的实例
-- 右键要转到2000的库
-- 任务
-- 生成脚本
-- 在"脚本向导"的"选择数据库"中, 确定选择的是要转到2000的库
-- 勾选"为所选数据库中的所有对象编写脚本"
-- 在接下来的"选择脚本选项"中, 找到"为服务器版本编写脚本"项, 选择"SQL Server 2000"
-- 其他选项根据需要设置
-- 最后把脚本保存到一个 .sql 脚本文件
2. 在2000中创建目标数据库
在查询分析器(或2005的manger studio在打开脚本文件), 连接到SQL Server 2000,新建一个空数据库,执行上面生成的脚本.以创建所有的数据对象。
3. 将数据从2005导到2000
2005 的manger studio
-- 打开"对象资源管理器"(没有的话按F8), 连接到你的实例
-- 右键要转到2000的库
-- 任务
-- 导出数据
-- 在"SQL Server 导入和导出向导"的"选择数据源"步骤中, 确定选择的是要导出的数 据库
-- 在"选择目标"步骤中, 连接到 2000, 并选择步骤2新建的库
-- 在"选择源表和源视图"中, 选择所有的表
(要排除掉视图(View),而且要“启用标识插入”,只启用一两个就行了)
SQL Server 2005数据库降级转到SQL Server 2000
2008-11-07 14:37
SQL Server 2000 数据库 => SQL Server 2005 数据库
在SQL Server 2005的Management Studio中新建一个数据库,右键选择“任务”->“复制数据库”。
SQL Server 2005 数据库 => SQL Server2000 数据库
安装SQL2000, 然后把数据库重新附加,存储过程(如果在2005中你没有使用新增功能,这个在2000中是能完全运行的),这样就行了,你可以试试
上面的方法不行,报错:
“错误602:未能在sysindexes 中找到数据库ID 15 中对象ID 1的索引ID 1 对应的行。请对sysindexes运行DBCC CHECKTABLE。”
解决方案:
因为数据库附加到2005的时候, 数据库文件已经自动升级到2005, 所以在2000下是无法再附加的(没有向上兼容的)直接restore或附加是不行的, 用脚本+导数据肯定没有问题。
2005转到2000的步骤步骤
1. 生成for 2000版本的数据库脚本
2005 的manger studio
-- 打开"对象资源管理器"(没有的话按F8), 连接到你的实例
-- 右键要转到2000的库
-- 任务
-- 生成脚本
-- 在"脚本向导"的"选择数据库"中, 确定选择的是要转到2000的库
-- 勾选"为所选数据库中的所有对象编写脚本"
-- 在接下来的"选择脚本选项"中, 找到"为服务器版本编写脚本"项, 选择"SQL Server 2000"
-- 其他选项根据需要设置
-- 最后把脚本保存到一个 .sql 脚本文件
2. 在2000中创建目标数据库
在查询分析器(或2005的manger studio在打开脚本文件), 连接到SQL Server 2000,新建一个空数据库,执行上面生成的脚本.以创建所有的数据对象。
3. 将数据从2005导到2000
2005 的manger studio
-- 打开"对象资源管理器"(没有的话按F8), 连接到你的实例
-- 右键要转到2000的库
-- 任务
-- 导出数据
-- 在"SQL Server 导入和导出向导"的"选择数据源"步骤中, 确定选择的是要导出的数 据库
-- 在"选择目标"步骤中, 连接到 2000, 并选择步骤2新建的库
-- 在"选择源表和源视图"中, 选择所有的表
(要排除掉视图(View),而且要“启用标识插入”,只启用一两个就行了)
cisco 2500路由器实现ADSL接入
[
|
2009/11/30 11:28]
|
2009/11/30 11:28]
工程环境架构:adsl modem 一个 cisco 2500 路由器一个 公司内部地址网段为192.168.0./24
实验目的:公司内部网段可以通过路由器拨号上网。
实验步骤:
第一步: 配置虚拟专用拨号网络-VPDN
1 vpdn enable 开启路由器的虚拟专用拨号网络-vpdn
2 vpdn-group office 建立一个vpdn组
3 request-dialin 初始化一个vpdn tunnel
4 protocol pppoe 设置拨号协议为PPPoE
实验目的:公司内部网段可以通过路由器拨号上网。
实验步骤:
第一步: 配置虚拟专用拨号网络-VPDN
1 vpdn enable 开启路由器的虚拟专用拨号网络-vpdn
2 vpdn-group office 建立一个vpdn组
3 request-dialin 初始化一个vpdn tunnel
4 protocol pppoe 设置拨号协议为PPPoE
路由器的NAT配置
[
|
2009/11/27 17:44]
|
2009/11/27 17:44]
任务一:配 置静态NAT(用虚拟机做时,首先要将虚拟交换机关闭路由功能—no ip
routing)
Step1:配置路由器A 的端口IP 地址。
routerA#conf t
routerA(config)#int f0/0
routerA(config-if)#ip add 10.1.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#int s1/1
routerA(config-if)#ip add 192.168.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#exit
routerA(config)#exit
routerA#show run
Step2:路由器A 上配置到达子网172.16.1.0 的默认路由
routerA(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerA#show ip route
Step3:设置内部局部地址10.1.1.2 和内部全局地址192.168.1.10 之间的静态地址
转换
routerA(config)#ip nat inside source static 10.1.1.2 192.168.1.10
设置内部局部地址10.1.1.3 和内部全局地址192.168.1.11 之间的静态地址
转换
routerA(config)#ip nat inside source static 10.1.1.3 192.168.1.11
查看NAT 配置信息
routerA(config)#show ip statistics
在内部端口及外部端口上启用NAT
routerA(config)#int f0/0
routerA(config-if)#ip nat inside
routerA(config)#int s1/1
routerA(config-if)#ip nat outside
step4:配置路由器B 端口IP 地址。
routerB#conf t
routerB(config)#int f0/0
routerB(config-if)#ip add 172.16.1.1 255.255.255.0
routerB(config-if)#no sh
routerB(config-if)#int s1/1
routerB(config-if)#ip add 192.168.1.2 255.255.255.0
routerB(config-if)#no sh
routerB(config-if)#exit
routerB(config)#exit
routerB#show run
Step5:路由器B 上配置到达子网10.1.1.0 的默认路由
routerB(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.1
查看路由表信息
routerB#show ip route
Step6:设置内部局部地址172.16.1.2 和内部全局地址192.168.1.20 之间的静态地
址转换
routerB(config)#ip nat inside source static 172.16.1.2 192.168.1.20
设置内部局部地址172.16.1.3 和内部全局地址192.168.1.21 之间的静态地
址转换
routerB(config)#ip nat inside source static 172.16.1.3 192.168.1.21
查看NAT 配置信息
routerB(config)#show ip statistics
在内部端口及外部端口上启用NAT
routerB(config)#int f0/0
routerB(config-if)#ip nat inside
routerB(config)#int s1/1
routerB(config-if)#ip nat outside
Step7:验证.
在主机10.1.1.2 上ping192.168.1.2
在主机172.16.1.3 上ping192.168.1.1
查看路由器A 的 NAT 地址转换表
routerA#show ip nat translations
查看路由器B 的NAT 地址转换表
routerB#show ip nat translations
任务二:配置动态NAT
step1.RuteA 端置IP 地址
routerA#conf t
routerA(config)#int f0/0
routerA(config-if)#ip add 10.1.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#int s1/1
routerA(config-if)#ip add 192.168.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#exit
routerA(config)#exit
routerA#show run
Step2:路由器A 上配置到达子网172.16.1.0 的默认路由
routerA(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerA#show ip route
step3.定义内部网络中允许访问外部的控制列表
routerA(config)#access-list 1 permit 10.1.1.0 0.0.0.255
step4.定义合法的IP 地址池
routerA(config)#ip nat pool test0 192.168.1.100 192.168.1.150
netmask 255.255.255.0
step5.指定网络地址转换映射
routerA(config)#ip nat inside source list 1 pool test0
step6.在内部和外部端口上启用NAT
routerA(config)#int f0/0
routerA(config-if)#ip nat inside
routerA(config)#int s1/1
routerA(config-if)#ip nat outside
step7. RouteB 端置IP 地址
routerB#conf t
routerB(config)#int f0/0
routerB(config-if)#ip add 172.16.1.1 255.255.255.0
routerB(config-if)#no sh
routerB(config-if)#int s1/1
routerB(config-if)#ip add 192.168.1.2 255.255.255.0
routerB(config-if)#no sh
routerB(config-if)#exit
routerB(config)#exit
routerA#show run
Step8:路由器B 上配置到达子网172.16.1.0 的默认路由
routerB(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.1
查看路由表信息
routerB#show ip route
step9.定义内部网络中允许访问外部的控制列表
routerB(config)#access-list 1 permit 172.16.1.0 0.0.0.255
step10.定义合法的IP 地址池
routerB(config)#ip nat pool test0 192.168.1.151 192.168.1.200
netmask 255.255.255.0
step11.指定网络地址转换映射
routerB(config)#ip nat inside source list 1 pool test0
step12.在内部和外部端口上启用NAT
routerB(config)#int f0/0
routerB(config-if)#ip nat inside
routerB(config)#int s1/1
routerB(config-if)#ip nat outside
step13. 验证.
在主机10.1.1.2 上ping192.168.1.2
在主机172.16.1.3 上ping192.168.1.1
查看路由器A 的 NAT 地址转换表
routerA#show ip nat translations
查看路由器B 的NAT 地址转换表
routerB#show ip nat translations
任务三:PAT 配置(使用外部全局地址)
step1. RuteA 端置IP 地址
routerA#conf t
routerA(config)#int f0/0
routerA(config-if)#ip add 10.1.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#int s1/1
routerA(config-if)#ip add 192.168.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#exit
routerA(config)#exit
routerA#show run
Step2:路由器A 上配置到达子网172.16.1.0 的默认路由
routerA(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerA#show ip route
step3.定义内部网络中允许访问外部的控制列表
routerA(config)#access-list 1 permit 10.1.1.0 0.0.0.255
step4.定义合法的IP 地址池
routerA(config)#ip nat pool only 192.168.1.3 192.168.1.3 netmask
255.255.255.0
step5.指定网络地址转换映射
routerA(config)#ip nat inside source list 1 pool only overload
step6.在内部和外部端口上启用NAT
routerA(config)#int f0/0
routerA(config-if)#ip nat inside
routerA(config)#int s1/1
routerA(config-if)#ip nat outside
step7. RuteB 端置IP 地址
routerB #conf t
routerB (config)#int f0/0
routerB (config-if)#ip add 10.1.1.1 255.255.255.0
routerB (config-if)#no sh
routerB (config-if)#int s1/1
routerB (config-if)#ip add 192.168.1.1 255.255.255.0
routerB (config-if)#no sh
routerB (config-if)#exit
routerB (config)#exit
routerB#show run
Step8:路由器B 上配置到达子网172.16.1.0 的默认路由
routerB (config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerB #show ip route
step9.定义内部网络中允许访问外部的控制列表
routerB (config)#access-list 1 permit 172.16.1.0 0.0.0.255
step10.定义合法的IP 地址池
routerB (config)#ip nat pool only 192.168.1.4 192.168.1.4 netmask
255.255.255.0
step11.指定网络地址转换映射
routerB (config)#ip nat inside source list 1 pool only overload
step12.在内部和外部端口上启用NAT
routerB (config)#int f0/0
routerA(config-if)#ip nat inside
routerB (config)#int s1/1
routerB (config-if)#ip nat outside
step13. 验证.
在主机10.1.1.2 上ping192.168.1.2
在主机172.16.1.3 上ping192.168.1.1
查看路由器A 的 NAT 地址转换表
routerA #show ip nat translations
查看路由器B 的NAT 地址转换表
routerB#show ip nat translations
任务四:PAT 配置(复用路由器外部接口地址)
step1. RuteA 端置IP 地址
routerA#conf t
routerA(config)#int f0/0
routerA(config-if)#ip add 10.1.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#int s1/1
routerA(config-if)#ip add 192.168.1.1 255.255.255.0
routerA(config-if)#no sh
routerA(config-if)#exit
routerA(config)#exit
routerA#show run
Step2:路由器A 上配置到达子网172.16.1.0 的默认路由
routerA(config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerA#show ip route
step3.指定网络地址转换映射
routerA(config)#ip nat inside source list 1 int erface s1/1 overload
step4.在内部和外部端口上启用NAT
routerA(config)#int f0/0
routerA(config-if)#ip nat inside
routerA(config)#int s1/1
routerA(config-if)#ip nat outside
step5. routerB 端置IP 地址
routerB #conf t
routerB (config)#int f0/0
routerB (config-if)#ip add 10.1.1.1 255.255.255.0
routerB (config-if)#no sh
routerB (config-if)#int s1/1
routerB (config-if)#ip add 192.168.1.1 255.255.255.0
routerB (config-if)#no sh
routerB (config-if)#exit
routerB (config)#exit
routerB #show run
Step6:路由器A 上配置到达子网172.16.1.0 的默认路由
routerB (config)#ip route 0.0.0.0 0.0.0.0 192.168.1.2
查看路由表信息
routerB #show ip route
step7.指定网络地址转换映射
routerB (config)#ip nat inside source list 1 interface s1/1 overload
step8.在内部和外部端口上启用NAT
routerB (config)#int f0/0
routerB (config-if)#ip nat inside
routerB (config)#int s1/1
routerB (config-if)#ip nat outside
step9. 验证.
在主机10.1.1.2 上ping192.168.1.2
在主机172.16.1.3 上ping192.168.1.1
查看路由器A 的 NAT 地址转换表
routerA#show ip nat translations
查看路由器B 的NAT 地址转换表
routerB#show ip nat translations
任务五:TCP 负载均衡实验拓扑图
Step1.配置各设备的IP 地址(略),关闭交换机的路由功能(no ip routing)
Step2.RouteA 上配置静态路由,下一跳指向172.16.1.2
RouteA(config)#ip route 0.0.0.0 0.0.0.0 172.16.1.2
step3.为虚拟主机定义一个标准的IP 访问控制列表
RouteA(config)#access-list 1 permit 10.1.1.127
Step4.为真实主机定义一个NAT 地址集
RouteA(config)#ip nat pool real 10.1.1.2 10.1.1.4 prefix-length 24
type rotary
Step5.设置访问控制列表与NAT 地址集之间的映射
RouteA(config)#ip nat inside destination list 1 pool real
Step6. 验证.
在主机10.1.1.2 上ping192.168.1.2
在主机172.16.1.3 上ping192.168.1.1
查看路由器A 的 NAT 地址转换表
routerA#show ip nat translations
查看路由器B 的NAT 地址转换表
routerB#show ip nat translations
设置端口镜像
[
|
2009/11/27 13:09]
|
2009/11/27 13:09]
华为交换机端口监听配置
华为交换机用户手册中,端口监听被称为“端口镜像”(Port Mirroring)。
使用Huawei Lanswitch View管理系统添加一个镜像端口:
选择 Device Setup或Stack Setup。
点击 Port Mirroring。
点击 Add按钮。对于堆叠,点击Switch并从列表选择一个交换机。
点击 Reflect from并选择流量将被镜像的端口。
点击 Reflect to并选上面所选择的端口上的
华为路由器端口监听配置
镜像是一个端口的数据射被映到另一个端口,进行数据分析。
[Quidway]monitor-port e0/8
[Quidway]port mirror e0/1
或:
[Quidway]port mirror e0/1 to e0/2 observing-port e0/8
一、思科交换机端口监听配置
CISCO交换机分为两种,在CATALYST家族中称监听端口为分析端口(analysis port)。
1、Catalyst 2900XL/3500XL/2950系列交换机端口监听配置(基于CLI)
以下命令配置端口监听:port monitor
例如,F0/1和F0/2、F0/5同属VLAN1,F0/1监听F0/2、F0/5端口:
interface FastEthernet0/1
port monitor FastEthernet0/2
port monitor FastEthernet0/5
port monitor VLAN1
2、Catalyst 4000/5000/6000系列机端口监听配置(基于交换IOS)
以下命令配置端口监听:
set span
例如,模块6中端口1和端口2同属VLAN1,端口3在VLAN2,端口4和5在VLAN2,端口2监听端口1和3、4、5,
set span 6/1,6/3-5 6/2
华为交换机用户手册中,端口监听被称为“端口镜像”(Port Mirroring)。
使用Huawei Lanswitch View管理系统添加一个镜像端口:
选择 Device Setup或Stack Setup。
点击 Port Mirroring。
点击 Add按钮。对于堆叠,点击Switch并从列表选择一个交换机。
点击 Reflect from并选择流量将被镜像的端口。
点击 Reflect to并选上面所选择的端口上的
华为路由器端口监听配置
镜像是一个端口的数据射被映到另一个端口,进行数据分析。
[Quidway]monitor-port e0/8
[Quidway]port mirror e0/1
或:
[Quidway]port mirror e0/1 to e0/2 observing-port e0/8
一、思科交换机端口监听配置
CISCO交换机分为两种,在CATALYST家族中称监听端口为分析端口(analysis port)。
1、Catalyst 2900XL/3500XL/2950系列交换机端口监听配置(基于CLI)
以下命令配置端口监听:port monitor
例如,F0/1和F0/2、F0/5同属VLAN1,F0/1监听F0/2、F0/5端口:
interface FastEthernet0/1
port monitor FastEthernet0/2
port monitor FastEthernet0/5
port monitor VLAN1
2、Catalyst 4000/5000/6000系列机端口监听配置(基于交换IOS)
以下命令配置端口监听:
set span
例如,模块6中端口1和端口2同属VLAN1,端口3在VLAN2,端口4和5在VLAN2,端口2监听端口1和3、4、5,
set span 6/1,6/3-5 6/2
思科3640 配置单臂路由
[
|
2009/11/26 17:32]
|
2009/11/26 17:32]
1.利用路由器R1、R2模拟PC,关闭其路由功能;
2.将路由器R1的Fa0/0端口的ip设为:192.168.1.2/24,默认网关设为:192.168.1.1;
3.将路由器R2的Fa0/0端口的ip设为:192.168.0.2/24,默认网关设为:192.168.0.1;
4.将交换机SW1关闭路由功能,作为二层交换机使用,并划分VLAN14、VLAN15两个VLAN;
5.将交换机SW1的Fa1/14端口加入到VLAN14中,将Fa1/15端口加入到VLAN15中;
6.在路由器R3的Fa0/0接口启用子接口Fa0/0.14(ip设为:192.168.0.1/24)、Fa0/0.15(ip设为:192.168.1.1/24)并封装相应的VLAN号;
图如下:
实验配置过程:
交换机SW1的配置清单:
1.划分VLAN:
SW1#vlan data
SW1(vlan)#vlan 14
SW1(vlan)#vlan 15
SW1(vlan)#exit
2.将端口加入到相应的VLAN:
SW1(config)#int fa1/14
SW1(config-if)#speed 100
SW1(config-if)#duplex full
SW1(config-if)#switchport mod acc
SW1(config-if)#switchport acc vlan 14
SW1(config-if)#exit
SW1(config)#int fa1/15
SW1(config-if)#duplex full
SW1(config-if)#switchport mod acc
SW1(config-if)#switchport acc vlan 15
SW1(config-if)#exit
3.为Fa1/13端口配置干道:
SW1(config)#int fa1/13
SW1(config-if)#switchport mod trunk
SW1(config-if)#switchport trunk encapsulation dot1q
SW1(config-if)#no shut
SW1(config-if)#exit
4.关闭交换机的路由功能:
SW1(config)#no ip routing
路由器R3的配置清单:
1.开启路由器R3的路由功能:
R3(config)#ip routing
2.启用子接口、封装VLAN并设置ip:
R3(config)#int fa0/0.14
R3(config-subif)#encapsulation dot1q 14
R3(config-subif)#ip add 192.168.0.1 255.255.255.0
R3(config-subif)#no shut
R3(config-subif)#exit
R3(config)#int fa0/0.15
R3(config-subif)#encapsulation dot1q 15
R3(config-subif)#ip add 192.168.1.1 255.255.255.0
R3(config-subif)#no shut
R3(config-subif)#exit
3.配置Fa0/0端口并启动该端口:
R3(config)#int fa0/0
R3(config-if)#duplex full
R3(config-if)#no shut
路由器R2的配置清单:
R2(config)#no ip routing
R2(config)#ip default-gateway 192.168.0.1
R2(config)#int fa0/0
R2(config-if)#duplex full
R2(config-if)#ip add 192.168.0.2 255.255.255.0
R2(config-if)#no shut
路由器R1的配置清单:
R1(config)#no ip routing
R1(config)#ip default-gateway 192.168.1.1
R1(config)#int fa0/0
R1(config-if)#duplex full
R1(config-if)#ip add 192.168.1.2 255.255.255.0
R1(config-if)#no shut
R1(config-if)#exit
2.将路由器R1的Fa0/0端口的ip设为:192.168.1.2/24,默认网关设为:192.168.1.1;
3.将路由器R2的Fa0/0端口的ip设为:192.168.0.2/24,默认网关设为:192.168.0.1;
4.将交换机SW1关闭路由功能,作为二层交换机使用,并划分VLAN14、VLAN15两个VLAN;
5.将交换机SW1的Fa1/14端口加入到VLAN14中,将Fa1/15端口加入到VLAN15中;
6.在路由器R3的Fa0/0接口启用子接口Fa0/0.14(ip设为:192.168.0.1/24)、Fa0/0.15(ip设为:192.168.1.1/24)并封装相应的VLAN号;
图如下:
实验配置过程:
交换机SW1的配置清单:
1.划分VLAN:
SW1#vlan data
SW1(vlan)#vlan 14
SW1(vlan)#vlan 15
SW1(vlan)#exit
2.将端口加入到相应的VLAN:
SW1(config)#int fa1/14
SW1(config-if)#speed 100
SW1(config-if)#duplex full
SW1(config-if)#switchport mod acc
SW1(config-if)#switchport acc vlan 14
SW1(config-if)#exit
SW1(config)#int fa1/15
SW1(config-if)#duplex full
SW1(config-if)#switchport mod acc
SW1(config-if)#switchport acc vlan 15
SW1(config-if)#exit
3.为Fa1/13端口配置干道:
SW1(config)#int fa1/13
SW1(config-if)#switchport mod trunk
SW1(config-if)#switchport trunk encapsulation dot1q
SW1(config-if)#no shut
SW1(config-if)#exit
4.关闭交换机的路由功能:
SW1(config)#no ip routing
路由器R3的配置清单:
1.开启路由器R3的路由功能:
R3(config)#ip routing
2.启用子接口、封装VLAN并设置ip:
R3(config)#int fa0/0.14
R3(config-subif)#encapsulation dot1q 14
R3(config-subif)#ip add 192.168.0.1 255.255.255.0
R3(config-subif)#no shut
R3(config-subif)#exit
R3(config)#int fa0/0.15
R3(config-subif)#encapsulation dot1q 15
R3(config-subif)#ip add 192.168.1.1 255.255.255.0
R3(config-subif)#no shut
R3(config-subif)#exit
3.配置Fa0/0端口并启动该端口:
R3(config)#int fa0/0
R3(config-if)#duplex full
R3(config-if)#no shut
路由器R2的配置清单:
R2(config)#no ip routing
R2(config)#ip default-gateway 192.168.0.1
R2(config)#int fa0/0
R2(config-if)#duplex full
R2(config-if)#ip add 192.168.0.2 255.255.255.0
R2(config-if)#no shut
路由器R1的配置清单:
R1(config)#no ip routing
R1(config)#ip default-gateway 192.168.1.1
R1(config)#int fa0/0
R1(config-if)#duplex full
R1(config-if)#ip add 192.168.1.2 255.255.255.0
R1(config-if)#no shut
R1(config-if)#exit
交换机路由器2系列,以及防火墙525命令汇总
[
|
2009/11/17 14:43]
|
2009/11/17 14:43]
交换机支持的命令:
交换机基本状态:
switch: ;交换机的ROM状态
rommon> ;路由器的ROM状态
hostname> ;用户模式
hostname# ;特权模式
hostname(config)# ;全局配置模式
hostname(config-if)# ;接口状态
交换机口令设置:
switch>enable ;进入特权模式
switch#config terminal ;进入全局配置模式
switch(config)#hostname ;设置交换机的主机名
switch(config)#enable secret xxx ;设置特权加密口令
switch(config)#enable password xxa ;设置特权非密口令
switch(config)#line console 0 ;进入控制台口
switch(config-line)#line vty 0 4 ;进入虚拟终端
switch(config-line)#login ;允许登录
switch(config-line)#password xx ;设置登录口令xx
switch#exit ;返回命令
交换机VLAN设置:
switch#vlan database ;进入VLAN设置
switch(vlan)#vlan 2 ;建VLAN 2
switch(vlan)#no vlan 2 ;删vlan 2
switch(config)#int f0/1 ;进入端口1
switch(config-if)#switchport access vlan 2 ;当前端口加入vlan 2
switch(config-if)#switchport mode trunk ;设置为干线
switch(config-if)#switchport trunk allowed vlan 1,2 ;设置允许的vlan
switch(config-if)#switchport trunk encap dot1q ;设置vlan 中继
switch(config)#vtp domain ;设置发vtp域名
switch(config)#vtp password ;设置发vtp密码
switch(config)#vtp mode server ;设置发vtp模式
switch(config)#vtp mode client ;设置发vtp模式
交换机设置IP地址:
switch(config)#interface vlan 1 ;进入vlan 1
switch(config-if)#ip address ;设置IP地址
switch(config)#ip default-gateway ;设置默认网关
switch#dir flash: ;查看闪存
交换机显示命令:
switch#write ;保存配置信息
switch#show vtp ;查看vtp配置信息
switch#show run ;查看当前配置信息
switch#show vlan ;查看vlan配置信息
switch#show interface ;查看端口信息
switch#show int f0/0 ;查看指定端口信息
交换机基本状态:
switch: ;交换机的ROM状态
rommon> ;路由器的ROM状态
hostname> ;用户模式
hostname# ;特权模式
hostname(config)# ;全局配置模式
hostname(config-if)# ;接口状态
交换机口令设置:
switch>enable ;进入特权模式
switch#config terminal ;进入全局配置模式
switch(config)#hostname
switch(config)#enable secret xxx ;设置特权加密口令
switch(config)#enable password xxa ;设置特权非密口令
switch(config)#line console 0 ;进入控制台口
switch(config-line)#line vty 0 4 ;进入虚拟终端
switch(config-line)#login ;允许登录
switch(config-line)#password xx ;设置登录口令xx
switch#exit ;返回命令
交换机VLAN设置:
switch#vlan database ;进入VLAN设置
switch(vlan)#vlan 2 ;建VLAN 2
switch(vlan)#no vlan 2 ;删vlan 2
switch(config)#int f0/1 ;进入端口1
switch(config-if)#switchport access vlan 2 ;当前端口加入vlan 2
switch(config-if)#switchport mode trunk ;设置为干线
switch(config-if)#switchport trunk allowed vlan 1,2 ;设置允许的vlan
switch(config-if)#switchport trunk encap dot1q ;设置vlan 中继
switch(config)#vtp domain
switch(config)#vtp password
switch(config)#vtp mode server ;设置发vtp模式
switch(config)#vtp mode client ;设置发vtp模式
交换机设置IP地址:
switch(config)#interface vlan 1 ;进入vlan 1
switch(config-if)#ip address
switch(config)#ip default-gateway
switch#dir flash: ;查看闪存
交换机显示命令:
switch#write ;保存配置信息
switch#show vtp ;查看vtp配置信息
switch#show run ;查看当前配置信息
switch#show vlan ;查看vlan配置信息
switch#show interface ;查看端口信息
switch#show int f0/0 ;查看指定端口信息
路由器vpn的简单介绍 和配置
[
|
2009/11/13 17:29]
|
2009/11/13 17:29]
http://bbs.pcpop.com/080322/1665969.html 配置介绍
http://3jj.jxxhdn.com/jswz/aq/2009-04-17/60.html 配置教程http://www.pconline.com.cn/pcjob/nettech/cisco/others/0409/447535_3.html
下载文件
下面附带一个比较典型的 是固定(总部)-------------动态(分部) 的VPN 注意与上面的 固定-固定ip 中 map 的创建
一个典型的SITE TO SITE CISCO VPN
总部:
crypto isakmp policy 1 //定义isakmp策略
hash md5 //采用MD5,对数据进行完整性验证
authentication pre-share //采用pre-share认证方式
crypto isakmp key xxxxxx address 0.0.0.0 0.0.0.0 //指定密钥,同时指定对端可为任意IP
crypto ipsec transform-set xxxset esp-des esp-md5-hmac //VPN第二步,指定IPSec传输集,采用esp-des加密,MD5完整性验证
crypto dynamic-map xxxmap 10 //定义动态map,分支办公室IP不做限制
set transform-set xxxset
match address 185
crypto map xxxtrans 10 ipsec-isakmp dynamic xxxmap //正规map
int f0/0 //内网接口
ip ad 10.1.1.1 255.255.255.0
ip nat inside
int f0/1 //外网接口
ip ad 202.202.202.1 255.255.255.240
ip nat outside
crypto map xxxtrans //应用map
ip route 0.0.0.0 0.0.0.0 int f0/1 //默认路由指向外网出口
ip nat pool tele 202.202.202.2 202.202.202.6 netmask 255.255.255.240
ip nat inside source route-map nonat pool tele overload //路由策略指定进行具体NAT转换的数据
access-list 185 permit ip 10.1.1.0 0.0.0.255 192.168.1.0 0.0.0.255 //指定与分支办公室连接的IP数据流,符合条件的进行VPN传输
access-list 190 deny ip 10.1.1.0 0.0.0.255 192.168.1.0 0.0.0.255
access-list 190 permit ip 10.1.1.0 0.0.0.255 any
//指定与分支办公室连接的IP数据流,符合条件的进行NAT转换,第一句将到远程站点的访问否定了,不让其进行地址转换
route-map nonat permit 10 //定义route-map,为NAT转换服务
match ip address 190
分支办公室:
crypto isakmp policy 1 //定义策略为1
hash md5 //定义md5算法,完整性验证方法
authentication pre-share //定义为pre-share密钥认证方式
crypto isakmp key xxxxxx address 202.202.202.1 //定义pre-share密钥为xxxxxx,总部IP为202.202.202.1
crypto ipsec transform-set xxxset esp-des esp-md5-hmac //创建变换集esp-des esp-md5-hmac,定义加密方式为des,完整性验证为md5
crypto map xxxmap 1 ipsec-isakmp //创建正规map
set peer 202.202.202.1 //定义总部IP
set transform-set xxxset //使用上面定义的变换集xxxset
match address 185 //援引访问列表定义的敏感流量,即进行VPN转换的流量
int f0/0
ip ad 192.168.1.0 255.255.255.0
ip nat inside
int f0/1
ip ad 99.99.99.1 255.255.255.0 //这里很有可能是动态IP
ip nat outside
crypto map xxxmap
ip route 0.0.0.0 0.0.0.0 f0/1 //默认路由指向出口
access-list 185 permit ip 192.168.1.0 0.0.0.255 10.1.1.0 0.0.0.255
// 指定需进行VPN转换的数据流
access-list 190 deny ip 192.168.1.0 0.0.0.255 10.1.1.0 0.0.0.255
access-list 190 permit ip 192.168.1.0 0.0.0.255 any
// 指定需进行正常NAT转换的数据流,符合条件的直接从出口访问公网,不符合的不做NAT转换,直接进行VPN加密并输送至公司总部端
route-map nonat permit 10
match ip address 190
vpdn enable //以下是ADSL拨号配置
int f0/1
pppoe enable
pppoe-client dialer-pool-number 1 //定义dialer-pool
int dialer1
mtu 1492 //VPN连接中许多问题是MTU造成的
ip address negotiated //IP地址与对端协商,ISP随机提供动态IP
encapsulation ppp
dialer pool 1 //引用dialer pool
dialer-group 1 //引用敏感流量,符合条件的触发ADSL拨号
ppp authentication pap callin //定义pap明文密码传输
ppp pap sent-username xxxx2223030 password 7 ******
dialer-list 1 protocol ip permit //定义敏感流量,这里为所有流量
http://3jj.jxxhdn.com/jswz/aq/2009-04-17/60.html 配置教程http://www.pconline.com.cn/pcjob/nettech/cisco/others/0409/447535_3.html
下载文件 下面附带一个比较典型的 是固定(总部)-------------动态(分部) 的VPN 注意与上面的 固定-固定ip 中 map 的创建
一个典型的SITE TO SITE CISCO VPN
总部:
crypto isakmp policy 1 //定义isakmp策略
hash md5 //采用MD5,对数据进行完整性验证
authentication pre-share //采用pre-share认证方式
crypto isakmp key xxxxxx address 0.0.0.0 0.0.0.0 //指定密钥,同时指定对端可为任意IP
crypto ipsec transform-set xxxset esp-des esp-md5-hmac //VPN第二步,指定IPSec传输集,采用esp-des加密,MD5完整性验证
crypto dynamic-map xxxmap 10 //定义动态map,分支办公室IP不做限制
set transform-set xxxset
match address 185
crypto map xxxtrans 10 ipsec-isakmp dynamic xxxmap //正规map
int f0/0 //内网接口
ip ad 10.1.1.1 255.255.255.0
ip nat inside
int f0/1 //外网接口
ip ad 202.202.202.1 255.255.255.240
ip nat outside
crypto map xxxtrans //应用map
ip route 0.0.0.0 0.0.0.0 int f0/1 //默认路由指向外网出口
ip nat pool tele 202.202.202.2 202.202.202.6 netmask 255.255.255.240
ip nat inside source route-map nonat pool tele overload //路由策略指定进行具体NAT转换的数据
access-list 185 permit ip 10.1.1.0 0.0.0.255 192.168.1.0 0.0.0.255 //指定与分支办公室连接的IP数据流,符合条件的进行VPN传输
access-list 190 deny ip 10.1.1.0 0.0.0.255 192.168.1.0 0.0.0.255
access-list 190 permit ip 10.1.1.0 0.0.0.255 any
//指定与分支办公室连接的IP数据流,符合条件的进行NAT转换,第一句将到远程站点的访问否定了,不让其进行地址转换
route-map nonat permit 10 //定义route-map,为NAT转换服务
match ip address 190
分支办公室:
crypto isakmp policy 1 //定义策略为1
hash md5 //定义md5算法,完整性验证方法
authentication pre-share //定义为pre-share密钥认证方式
crypto isakmp key xxxxxx address 202.202.202.1 //定义pre-share密钥为xxxxxx,总部IP为202.202.202.1
crypto ipsec transform-set xxxset esp-des esp-md5-hmac //创建变换集esp-des esp-md5-hmac,定义加密方式为des,完整性验证为md5
crypto map xxxmap 1 ipsec-isakmp //创建正规map
set peer 202.202.202.1 //定义总部IP
set transform-set xxxset //使用上面定义的变换集xxxset
match address 185 //援引访问列表定义的敏感流量,即进行VPN转换的流量
int f0/0
ip ad 192.168.1.0 255.255.255.0
ip nat inside
int f0/1
ip ad 99.99.99.1 255.255.255.0 //这里很有可能是动态IP
ip nat outside
crypto map xxxmap
ip route 0.0.0.0 0.0.0.0 f0/1 //默认路由指向出口
access-list 185 permit ip 192.168.1.0 0.0.0.255 10.1.1.0 0.0.0.255
// 指定需进行VPN转换的数据流
access-list 190 deny ip 192.168.1.0 0.0.0.255 10.1.1.0 0.0.0.255
access-list 190 permit ip 192.168.1.0 0.0.0.255 any
// 指定需进行正常NAT转换的数据流,符合条件的直接从出口访问公网,不符合的不做NAT转换,直接进行VPN加密并输送至公司总部端
route-map nonat permit 10
match ip address 190
vpdn enable //以下是ADSL拨号配置
int f0/1
pppoe enable
pppoe-client dialer-pool-number 1 //定义dialer-pool
int dialer1
mtu 1492 //VPN连接中许多问题是MTU造成的
ip address negotiated //IP地址与对端协商,ISP随机提供动态IP
encapsulation ppp
dialer pool 1 //引用dialer pool
dialer-group 1 //引用敏感流量,符合条件的触发ADSL拨号
ppp authentication pap callin //定义pap明文密码传输
ppp pap sent-username xxxx2223030 password 7 ******
dialer-list 1 protocol ip permit //定义敏感流量,这里为所有流量





姓名:传奇
