paras.sim 2.1 KB
Newer Older
S
slguan 已提交
1
system sh/stop_dnodes.sh
S
slguan 已提交
2
system sh/deploy.sh -n dnode1 -i 1
S
Shengliang Guan 已提交
3
system sh/exec.sh -n dnode1 -s start
H
Haojun Liao 已提交
4
sleep 2000
S
slguan 已提交
5 6 7 8 9 10 11 12 13 14 15 16
sql connect

print =============== show accounts
sql show accounts
if $rows != 1 then 
  return -1
endi

print $data00 $data01 $data02 $data03 $data04 $data05 $data06
if $data00 != root then 
  return -1
endi
S
TD-1397  
Shengliang Guan 已提交
17
if $data02 != 3/128 then 
S
slguan 已提交
18 19
  return -1
endi
S
TD-1397  
Shengliang Guan 已提交
20
if $data03 != 0/128 then 
S
slguan 已提交
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
  return -1
endi
if $data04 != 0/2147483647 then 
  return -1
endi
if $data05 != 0/1000 then 
  return -1
endi
if $data06 != 0.000/unlimited then 
  return -1
endi

print =============== create account
sql create account hou pass "hou" tseries 80000 storage 10737418240 streams 10 qtime 3600 dbs 3 users 3 conns 10 
sql show accounts
if $rows != 2 then 
  return -1
endi

print $data10 $data11 $data12 $data13 $data14 $data15 $data16
if $data10 != hou then 
  return -1
endi
if $data12 != 2/3 then 
  return -1
endi
if $data13 != 0/3 then 
  return -1
endi
if $data14 != 0/80000 then 
  return -1
endi
if $data15 != 0/10 then 
  return -1
endi
if $data16 != 0.000/10.000 then 
  return -1
endi
  
print =============== alter account
sql alter account hou pass "hou" tseries 8000 streams 10 dbs 5 users 5  
sql show accounts
if $rows != 2 then 
  return -1
endi

print $data10 $data11 $data12 $data13 $data14 $data15 $data16
if $data10 != hou then 
  return -1
endi
if $data12 != 2/5 then 
  return -1
endi
if $data13 != 0/5 then 
  return -1
endi
if $data14 != 0/8000 then 
  return -1
endi
if $data15 != 0/10 then 
  return -1
endi
if $data16 != 0.000/10.000 then 
  return -1
endi  

print =============== alter account
sql create account hou pass "hou" tseries 8000 streams 10 dbs 5 users 6
sql show accounts
if $rows != 2 then 
  return -1
endi

print $data10 $data11 $data12 $data13 $data14 $data15 $data16
if $data10 != hou then 
  return -1
endi
if $data12 != 2/6 then 
  return -1
endi
if $data13 != 0/5 then 
  return -1
endi
if $data14 != 0/8000 then 
  return -1
endi
if $data15 != 0/10 then 
  return -1
endi
if $data16 != 0.000/10.000 then 
  return -1
endi  
S
scripts  
slguan 已提交
113

S
Shengliang Guan 已提交
114
system sh/exec.sh -n dnode1 -s stop  -x SIGINT