单个SCAN_IP是否负载均衡?
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了单个SCAN_IP是否负载均衡?相关的知识,希望对你有一定的参考价值。
最近遇到一个测试项目,对SCAN_IP是否负载均衡有一个疑问?理论上说是可以负载均衡,自己做了一个测试验证一下。
事实证明,并不是轮训机制的负载均衡。
一个小小的脚本如下:
<rac01:orcl1:/u01/app/oracle/product/12.1.0/dbhome_1/network/admin>$less load_balance_scan.sh
#!/bin/bash
for i in {1..100}
do
echo $i
sqlplus -S system/[email protected] <<EOF
select instance_name from v\$instance;
select count(*) from t1;
EOF
sleep 1
done
exit 0
<rac01:orcl1:/u01/app/oracle/product/12.1.0/dbhome_1/network/admin>$sh load_balance_scan.sh
1
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
2
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
3
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
4
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
5
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
6
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
7
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
8
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
9
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
10
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
11
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
12
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
13
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
14
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
15
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
16
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
17
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
18
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
19
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
20
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
21
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
22
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
23
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
24
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
25
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
26
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
27
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
28
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
29
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
30
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
31
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
32
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
33
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
34
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
35
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
36
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
37
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
38
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
39
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
40
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
41
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
42
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
43
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
44
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
45
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
46
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
47
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
48
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
49
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
50
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
51
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
52
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
53
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
54
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
55
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
56
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
57
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
58
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
59
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
60
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
61
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
62
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
63
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
64
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
65
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
66
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
67
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
68
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
69
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
70
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
71
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
72
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
73
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
74
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
75
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
76
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
77
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
78
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
79
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
80
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
81
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
82
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
83
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
84
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
85
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
86
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
87
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
88
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
89
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
90
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
91
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
92
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
93
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
94
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
95
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
96
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
97
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
98
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
99
INSTANCE_NAME
----------------
orcl2
COUNT(*)
----------
2910624
100
INSTANCE_NAME
----------------
orcl1
COUNT(*)
----------
2910624
<rac01:orcl1:/u01/app/oracle/product/12.1.0/dbhome_1/network/admin>$
以上是关于单个SCAN_IP是否负载均衡?的主要内容,如果未能解决你的问题,请参考以下文章