UltraMonkey-L7 V3(multi-thread implementation)
Révision | 3938dd0b7a5602223d5c55420de027696d246f10 (tree) |
---|---|
l'heure | 2010-10-22 12:42:52 |
Auteur | 6638678 <6638678@1ed6...> |
Commiter | 6638678 |
bug fix
git-svn-id: http://10.144.169.20/repos/um/branches/l7vsd-3.x-ramiel-epoll-cond@10404 1ed66053-1c2d-0410-8867-f7571e6e31d3
@@ -165,9 +165,6 @@ ULTRAMONKEY-L7-MIB::l7vsRsInActiveConn.3 = INTEGER: 0 | ||
165 | 165 | ULTRAMONKEY-L7-MIB::l7vsRsInActiveConn.4 = INTEGER: 0 |
166 | 166 | ULTRAMONKEY-L7-MIB::l7vsReplicationMode.0 = INTEGER: single(1)" |
167 | 167 | |
168 | -echo "$RET" >1.log | |
169 | -echo "$EXPECT" >2.log | |
170 | - | |
171 | 168 | if [ "${RET}" != "${EXPECT}" ] |
172 | 169 | then |
173 | 170 | echo "Test failed: snmpwalk -v 2c -c public localhost ULTRAMONKEY-L7-MIB::ultramonkey" |
@@ -164,9 +164,6 @@ ULTRAMONKEY-L7-MIB::l7vsRsInActiveConn.2 = INTEGER: 0 | ||
164 | 164 | ULTRAMONKEY-L7-MIB::l7vsRsInActiveConn.3 = INTEGER: 0 |
165 | 165 | ULTRAMONKEY-L7-MIB::l7vsRsInActiveConn.4 = INTEGER: 0 |
166 | 166 | ULTRAMONKEY-L7-MIB::l7vsReplicationMode.0 = INTEGER: single(1)" |
167 | -echo "$RET" >1.log | |
168 | -echo "$EXPECT" >2.log | |
169 | - | |
170 | 167 | |
171 | 168 | if [ "${RET}" != "${EXPECT}" ] |
172 | 169 | then |
@@ -53,7 +53,7 @@ fi | ||
53 | 53 | dd if=/dev/zero of=${TMP_DIR}/10M.dat bs=1024 count=10240 |
54 | 54 | |
55 | 55 | #Get The File |
56 | -$WGET http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
56 | +$WGET -qO- http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
57 | 57 | if [ $? -ne 0 ] |
58 | 58 | then |
59 | 59 | echo "Test failed: $WGET http://127.0.0.1:40001 --post-file 10M.dat" |
@@ -53,7 +53,7 @@ fi | ||
53 | 53 | dd if=/dev/zero of=${TMP_DIR}/10M.dat bs=1024 count=10240 |
54 | 54 | |
55 | 55 | #Get The File |
56 | -$WGET http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
56 | +$WGET -qO- http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
57 | 57 | if [ $? -ne 0 ] |
58 | 58 | then |
59 | 59 | echo "Test failed: $WGET http://$VS1:40001 --post-file 10M.dat" |
@@ -53,7 +53,7 @@ fi | ||
53 | 53 | dd if=/dev/zero of=${TMP_DIR}/10M.dat bs=1024 count=10240 |
54 | 54 | |
55 | 55 | #Get The File |
56 | -$WGET http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
56 | +$WGET -qO- http://$VS1:40001 --post-file ${TMP_DIR}/10M.dat -t 1 | |
57 | 57 | if [ $? -ne 0 ] |
58 | 58 | then |
59 | 59 | echo "Test failed: $WGET http://$VS1:40001 --post-file 10M.dat" |
@@ -96,9 +96,6 @@ ULTRAMONKEY-L7-MIB::l7vsVsHttpPostCount.1 = Counter64: 0 | ||
96 | 96 | ULTRAMONKEY-L7-MIB::l7vsVsRsNumber.1 = INTEGER: 0 |
97 | 97 | ULTRAMONKEY-L7-MIB::l7vsReplicationMode.0 = INTEGER: single(1)" |
98 | 98 | |
99 | -echo "$RET" >1.log | |
100 | -echo "$EXPECT" >2.log | |
101 | - | |
102 | 99 | if [ "${RET}" != "${EXPECT}" ] |
103 | 100 | then |
104 | 101 | echo "Test failed: snmpwalk -v 2c -c public localhost ULTRAMONKEY-L7-MIB::ultramonkey-l7" |
@@ -105,7 +105,6 @@ sleep 2 | ||
105 | 105 | #warnning log trap |
106 | 106 | $L7VSADM -A -t 127.0.0.1:40001 -m sessionless |
107 | 107 | sleep 1 |
108 | - | |
109 | 108 | RET=`cat ${L7VS_LOG_DIR}/B-56-snmptrapd.log | grep -e "SNMPv2-SMI::enterprises.32132.1.0.3.3 = STRING: \"[0-9]\{4\}/[0-9]\{2\}/[0-9]\{2\} [0-9]\{2\}:[0-9]\{2\}:[0-9]\{2\},VSD3.*" | wc -l` |
110 | 109 | echo "TEST:: $RET" |
111 | 110 | if [ "${RET}" != "2" ] |
@@ -115,7 +114,6 @@ then | ||
115 | 114 | fi |
116 | 115 | |
117 | 116 | sleep 20 |
118 | - | |
119 | 117 | #Check MIB |
120 | 118 | RET=`snmpwalk -v 2c -c public localhost ULTRAMONKEY-L7-MIB::ultramonkey-l7` |
121 | 119 | EXPECT="ULTRAMONKEY-L7-MIB::l7vsVsNumber.0 = INTEGER: 1 |
@@ -147,16 +145,10 @@ ULTRAMONKEY-L7-MIB::l7vsVsHttpPostCount.1 = Counter64: 0 | ||
147 | 145 | ULTRAMONKEY-L7-MIB::l7vsVsRsNumber.1 = INTEGER: 0 |
148 | 146 | ULTRAMONKEY-L7-MIB::l7vsReplicationMode.0 = INTEGER: single(1)" |
149 | 147 | |
150 | -echo "$EXPECT" > /tmp/1.txt | |
151 | -echo "$RET" > /tmp/2.txt | |
152 | -diff /tmp/1.txt /tmp/2.txt | |
153 | - | |
154 | 148 | if [ "${RET}" != "${EXPECT}" ] |
155 | 149 | then |
156 | 150 | echo "Test failed: snmpwalk -v 2c -c public localhost ULTRAMONKEY-L7-MIB::ultramonkey-l7" |
157 | 151 | exit 1 |
158 | 152 | fi |
159 | 153 | |
160 | - | |
161 | - | |
162 | 154 | exit 0 |
@@ -10,13 +10,19 @@ then | ||
10 | 10 | LOG_FATAL "Can not stop l7vsd." |
11 | 11 | exit 1 |
12 | 12 | fi |
13 | + usleep 500000 | |
14 | + if [ -n "`pgrep l7vsd`" ] | |
15 | + then | |
16 | + LOG_FATAL "Can not stop l7vsd." | |
17 | + exit 1 | |
18 | + fi | |
13 | 19 | fi |
14 | 20 | |
15 | 21 | if [ -n "`pgrep l7directord`" ] |
16 | 22 | then |
17 | 23 | ${INIT_L7DIRECTORD} stop > /dev/null 2>&1 |
18 | 24 | pkill -KILL l7directord > /dev/null 2>&1 |
19 | - usleep 100000 | |
25 | + usleep 500000 | |
20 | 26 | if [ -n "`pgrep l7directord`" ] |
21 | 27 | then |
22 | 28 | LOG_FATAL "Can not stop l7directord." |