Upload
pustinjak-saharic
View
222
Download
0
Embed Size (px)
Citation preview
8/18/2019 52306346 Alarm Management
1/82
TABLE OF CONTENTS
CHAPTER NO TITLE PAGE NO
ABSTRACT iii
LIST OF TABLES viii
LIST OF FIGURES x
LIST OF ABBREVIATIONS xii
1. INTRODUCTION 1
1.1 PROJECT DESCRIPTION
2. SYSTEM STUDY 11
2.1 FEASABILITY STUDY
2.2 EXISTING SYSTEM
2.3 PROPOSED SYSTEM
3 SYSTEM SPECIFICATION 14
3.1 SOFTWARE RE UIREMENTS
3.2 !ARDWARE RE UIREMENTS
4 LANGUAGE SPECIFICATION 1"
4.1 FEATURES OF VB .NET
4.2 FEATURES OF S L SERVER 2###
" SYSTEM DESIGN 32
".1 INPUT DESIGN
".2 OUTPUT DESIGN
".3 DATABASE DESIGN
8/18/2019 52306346 Alarm Management
2/82
".4 DATA FLOW DIAGRAM
"." SYSTEM FLOW DIAGRAM
$ SYSTEM TESTING AND MAINTENANCE "%
$.1 UNIT TESTING
$.2 INTEGRATION TESTING
$.3 VALIDATION
& SYSTEM IMPLEMENTATION "'
&.1 SCOPE FOR FUTURE DEVELOPMENT
% CONCLUSION $#
' BIBLIOGRAP!Y $2
APPENDIX
• SCREEN S!OT
• DATA TABLE STRUCTURE
• SAMPLE CODING
I.
8/18/2019 52306346 Alarm Management
3/82
LIST OF FIGURES
FIGURE NO NAME PAGE
NO
1 .NET FRAMEWOR( 1#
2 INTEROPERABILITY 12
8/18/2019 52306346 Alarm Management
4/82
ACTIVE MONITORING AND ALARM MANAGEMENT
FOR FAULT LOCALIZATION IN TRANSPARENT ALL-OPTICAL NETWORKS
ABSTRACT:
T)i* +,,-i +/i0 i* + ** * /) -0 +-i5+/i0 + 6 + 7 i -+ 8 /90 : /0,0-08i *
9)i- ;+i /+i i 8 -09 0;,- xi/7< 9 +-*0 x,+ /)i* , 0=- ; i /0 + )i + )i +--7>
i*/ i=6/ ;0 i/0 i 8 ;0 -. I/ 9i-- ?0 ;6-+/ + /iv+/i0 , 0=- ; ?0 0,/i;+- ;0 i/0
6*i 8 I / 8 Li + P 08 +; @ILP . G +- *i;6-+/i0 *6-/* , 0vi *6,,0 /i 8+ +-7*i* + 0;,+ i*0 * 0? + )i v+=- +-+ ;>v /0 6 /i0 < -0 +-i5+/i0 0v +8 <
+ /i; 0;,- xi/7< ?0 ?-+/ + )i + )i +--7 i*/ i=6/ ;0 i/0 i 8 +,, 0+ ) *. I/ 9i--
i;, 0v /) ?? /iv ** 0? /) +,,-i +/i0 6*i 8 , 0,0* / ) i 6 i ??i i / +
* +-+=- ;0 i/0 i 8 0? / + *,+ / 0,/i +- /90 :*. I/ , 0vi * x/ *iv 6; i +-
*6-/* + , ?0 ;+ 0;,+ i*0 * ?0 /) / +-i5 + )i + )i +--7 i*/ i=6/
;0 i/0 i 8 i 0;;0 + + 0; /90 : /0,0-08i *. A / +-i5 ;0 i/0 i 8 ;0 -
0 *i*/* 0? + *i 8- / +- ?+6-/>;+ +8 9)i ) iv * +-+ ;* ? 0; +-- ;0 i/0 * i /)
/90 : + , 0 ** * /) ; +* + ?+6-/>v /0 /0 -0 +-i5 + ?+6-/.
8/18/2019 52306346 Alarm Management
5/82
INTRODUCTION
EMERGING / + *,+ / 0,/i +- /90 :* @TON* i / 0 6 ;+ 7 + v+ /+8 *<
i -6 i 8 /) +=i-i/7 /0 ??i i /-7 - v +8 -+ 8 =+ 9i /) ,0/ /i+- + , 0vi
/ + *,+ / *6,,0 / ?0 iv * / + *;i**i0 , 0/0 0-*. !09 v < 0,/i +- / + *,+ 7
+-*0 i / 0 6 * + 6i ; / ?0 + 9 ;0 i/0 i 8+ ?+6-/>-0 +-i5+/i0 +,, 0+ ) +/ /)0,/i +- -+7 . D6 /0 /) -+ : 0? 0,/i +- - / 0 0,/i +- @O E O 8 +/i0 i TON*< +
*i 8- ?+6-/ ;+7 , 0,+8+/ /) 068)06/ /) /90 :< /)6* 8 +/i 8 + ?-00 0? 6 + /
+-+ ;*< i +*i 8 /) , 0 **i 8 0v ) + + -0 +-i5+/i0 /i; < + 6-/i;+/ -7 -+7i 8
* vi */0 +/i0 . Wi/) i ) /-7 )i8) +/+ +/ *< F 6 / i* 6,/i0 * i TON*
i -6 = i 8 0 6//i 8 0? ?i= < 6i,; / ?+i-6 < )6;+ 0 < + *0,)i*/i +/
+//+ :* I +--7< ,)7*i +- ?+i-6 * *)06- = / / < -0 +-i5 < + *0-v +/ /) 0,/i +-
-+7 = ?0 /) 7 + 0/i + )+ - =7 /) )i8) -+7 , 0/0 0-*. L 8+ 7
;0 i/0 i 8 / ) i 6 * i SONET SD! , 0vi "#;* 0,/i +- -+7 */0 +/i0 < =6/ + 0/
= i /-7 +,,-i i TON* 6 /0 6i O E O 0 v *i0 +/ + ) 0 . M0*/ 0? /)
/-7 , 0,0* TON ;0 i/0 i 8 / ) i 6 * + =+* 0 i?? / * ) ; * ?0
*/+=-i*); / 0? i +/ *6, vi*0 7 7 - * 0 ,+/)* 9)i ) + , 0vi*i0 0
i +/ 9+v - 8/)* /) 068) /) ;0 i/0 /90 : - ; /* . !09 v < /) *
* ) ; * i / 0 6 + i/i0 +- 0v ) + i / ;* 0? /) 6i =+ 9i /)< i +/
/ + *,0 * + ;0 i/0 *< *6, vi*0 7>,+/) 0;,6/+/i0 + , 0vi*i0 i 8 /i; < +
)+ - i / ? < + **+ 7 ;+i / + . F6 /) ;0 < 0 -7 ;0 i/0 i 8 0? /)8 ?+i-6 * i* 0;;0 -7 0 *i < + /) , 0,0* / ) i 6 * ;+7 = 0;
i ??i i / ?0 /+i- -0 +-i5+/i0 0? i ivi 6+- ?i= >*,+ * + i* / 0,/i +-
0;,0 /* i -+ 8 /0,0-08i *.
8/18/2019 52306346 Alarm Management
6/82
1.1 PROJECT DESCRIPTION
Modu !":
I /)i* *7*/ ;< 9 + -0 +-i5i 8 /) ?+6-/ 9)i- /) 0 * + 6 i 8 i /) /90 : .T0
+ )i v /)i*< 9 + +/i 8 ?0--09i 8 ;0 6- *
A6/) /i +/i0
N0 V i?i +/i0 + E 0 L0 +-i5+/i0
N0 Di*/ i=6/i0
Di*/ i=6/ S7*/ ;
Au#$!%#&'(#&o%:
T)i* ;0 6- , 0vi * , i0 i/7 )09 /) 6* 80 * /0 6* 06 +,,-i +/i0 . W) + 6* 9i--
-08i i /0 /) +,,-i +/i0 < i/ )+* /0 v i?7 /) 6* * , ivi- 8 *. W) /) 6* )+* +
, ivi- 8 0? -i /< ) + 0/ ) : /) ?+6-/ 0 * ? 0; /) /90 : =6/ ! + ;+: /)
0;;6 i +/i0 /0 + 70 i 06 i*/ i=6/ *7*/ ;.
Nod! V!)&*&'(#&o% (%d E))o) Lo'( &+(#&o%:
T) F+6-/ -0 +-i5+/i0 i* + 0 9) 9 + 6*i 8 /) i*/ i=6/ *7*/ ;. T0
+ )i v i/< 9 + v i?7 /) v+-i 0 * ? 0; /) /90 : + -0 +-i5 /) ?+6-/ +
, 0vi /) i */ 6 /i0 /0 *0-v /) , 0=- ;* .T) v+-i 0 0 -7 i*/ i=6/ /0 06
-i /* 9) /) 7 + */i-- 90 :i 8.V( &d Nod! D&"#)&,u#&o%:
I /)i* ;0 6- < +?/ ) :i 8 /) v+-i 0 * ? 0; /) /90 :< 9 + i*/ i=6/i 8 /)0*
0 * /0 ;+: /) 0;;6 i +/i0 +;0 8 /) -i /*. T)i* +,, 0+ ) *)06- = + 800 0
/0 +v0i /) +/+ -0*i 8 + , 0vi * /) 0S.
8/18/2019 52306346 Alarm Management
7/82
D&"#)&,u#!d S "#! :
T)i* ;0 6- 8iv * /) i / + /i0 *7*/ ; +;0 8 /) -i /* + 9) 9 9+ / /0 -0 +-i5
/) ?+6-/ 9)i- * /) i / + /i0 . I/ *)06- = + = // *7*/ ; /0 i i +/ /) ?+6-/ 0? /)
*7*/ ; + , ? / +*0 * /0 /) * v .
/. S0STEM STUD0
/.1 FEASIBILIT0 STUD0
T) ? +*i=i-i/7 0? /) , 0 / i* + +-75 i /)i* ,)+* + =6*i ** , 0,0*+- i* ,6/
?0 /) 9i/) + v 7 8 +- ,-+ ?0 /) , 0 / + *0; 0*/ */i;+/ *. D6 i 8 *7*/ ;
+ +-7*i* /) ? +*i=i-i/7 */6 7 0? /) , 0,0* *7*/ ; i* /0 = + i 06/. T)i* i* /0 *6
/)+/ /) , 0,0* *7*/ ; i* 0/ + =6 /0 /) 0;,+ 7. F0 ? +*i=i-i/7 + +-7*i*< *0;
6 */+ i 8 0? /) ;+ 0 6i ; /* ?0 /) *7*/ ; i* ** /i+-.
T) : 7 0 *i +/i0 * i v0-v i /) ? +*i=i-i/7 + +-7*i* +
♦ ECONOMICAL FEASIBILITY
♦ TEC!NICAL FEASIBILITY
♦ SOCIAL FEASIBILITY
ECONOMICAL FEASIBILIT0
T)i* */6 7 i* + i 06/ /0 ) : /) 0 0;i i;,+ / /)+/ /) *7*/ ; 9i--
)+v 0 /) 0 8+ i5+/i0 . T) +;06 / 0? ?6 /)+/ /) 0;,+ 7 + ,06 i /0 /)
* + ) + v -0,; / 0? /) *7*/ ; i* -i;i/ . T) x, i/6 * ;6*/ = 6*/i?i .T)6* /) v -0, *7*/ ; +* 9 -- 9i/)i /) =6 8 / + /)i* 9+* + )i v = +6* ;0*/
0? /) / ) 0-08i * 6* + ? -7 +v+i-+=- . O -7 /) 6*/0;i5 , 0 6 /* )+ /0 =
,6 )+* .
8/18/2019 52306346 Alarm Management
8/82
TECHNICAL FEASIBILIT0
T)i* */6 7 i* + i 06/ /0 ) : /) / ) i +- ? +*i=i-i/7< /)+/ i*< /)
/ ) i +- 6i ; /* 0? /) *7*/ ;. A 7 *7*/ ; v -0, ;6*/ 0/ )+v + )i8)
;+ 0 /) +v+i-+=- / ) i +- *06 *. T)i* 9i-- - + /0 )i8) ;+ * 0 /)
+v+i-+=- / ) i +- *06 *. T)i* 9i-- - + /0 )i8) ;+ * = i 8 ,-+ 0 /) -i /.
T) v -0, *7*/ ; ;6*/ )+v + ;0 */ 6i ; /< +* 0 -7 ;i i;+- 0 6-- )+ 8 *
+ 6i ?0 i;,- ; /i 8 /)i* *7*/ ;.
SOCIAL FEASIBILIT0
T) +*, / 0? */6 7 i* /0 ) : /) - v - 0? + ,/+ 0? /) *7*/ ; =7 /) 6* .
T)i* i -6 * /) , 0 ** 0? / +i i 8 /) 6* /0 6* /) *7*/ ; ??i i /-7. T) 6* ;6*/
0/ ? - /) +/ =7 /) *7*/ ;< i */ + ;6*/ + ,/ i/ +* + **i/7. T) - v - 0?
+ ,/+ =7 /) 6* * *0- -7 , * 0 /) ; /)0 * /)+/ + ;,-07 /0 6 +/ /)
6* +=06/ /) *7*/ ; + /0 ;+: )i; ?+;i-i+ 9i/) i/. !i* - v - 0? 0 ?i ;6*/ =
+i* *0 /)+/ ) i* +-*0 +=- /0 ;+: *0; 0 */ 6 /iv i/i i*;< 9)i ) i* 9 - 0; < +*
) i* /) ?i +- 6* 0? /) *7*/ ;.
/./ E ISTING S0STEM Exi*/i 8 *7*/ ; 90 :* 0 0= /* *)+ =7 B75+ /i , 0 ** *
0 *i /)+/ /) + ** /0 0, +/i0 * i /) * 0= /* i* , 0/ / =7 ACL*. I /)i*
;0 -< + ) 0, +/i0 , 0vi =7 + 0= / i* +**0 i+/ /0 + -i*/ 0? , 0 ** * /)+/ )+v
+ ** /0 /)+/ 0, +/i0 . O -7 , 0 ** * /)+/ )+v + ** /0 + 0, +/i0 + x 6/ i/.
T)i* ;0 - 6i * + :i 0? ? ;0 i/0 /0 , 0/ / /) 0= /* ? 0; 6 +6/)0 i5
+ **. T) i;,- ; /+/i0 0? /)i* ;0 i/0 i* 0/ , 0=- ;+/i
/.2 PROPOSED S0STEM
T) , 0,0*+- ?0 i*/ i=6/ 0;,6/i 8 9i/) *)+ ; ;0 7 + ** =7
B75+ /i , 0 ** * , * / i /)i* ,+, i?? * ? 0; /) , vi06* ;0 - 9)
8/18/2019 52306346 Alarm Management
9/82
0= /* + , 0/ / =7 ACL*. O6 +,, 0+ ) i* =+* 0 /) 6* 0? ?i >8 +i + **
,0-i i * /)+/ *, i?7 6- * /)+/ +--09 0 7 + 0, +/i0 i v0 +/i0 /0 = x 6/ i +
0= / =+* 0 /) + 86; /* 0? /) 0, +/i0 < i/* i v0: < + /) */+/ 0? /) 0= /.
T) 0 */ 6 /i0 * , * / i /)i* ,+, @ 0 * *6* + 6 iv *+- 0= /* ;0 */ +/
/)+/ /)i* +,, 0+ ) +--09* /) v -0,; / 0? *i;,- + - 8+ / +-80 i/);*< +/ /) 0*/ 0?
?i i 8 + ** ,0-i i * ?0 /) *)+ ; ;0 7 0= /* /) 7 6* .
2. S0STEM SPECIFICATION
SOFTWARE RE3UIREMENTS:O, +/i 8 *7*/ ; > Wi 09* #&H XP
F 0 / E > Vi*6+- S/6 i0 2##%< C .N /<
B+ : > S L S v 2##"
HARDWARE RE3UIREMENTS:
SYSTEM P /i6; D6 - C0
!ARD DIS( 1$# GB
RAM 2 GB
4. LANGAUGE SPECIFICATION
4.1 FEATURES OF. NET
Mi 0*0?/ .NET i* + * / 0? Mi 0*0?/ *0?/9+ / ) 0-08i * ?0 +,i -7
=6i- i 8 + i / 8 +/i 8 XML W = * vi *< Mi 0*0?/ Wi 09*>=+* +,,-i +/i0 *< +
8/18/2019 52306346 Alarm Management
10/82
W = *0-6/i0 *. T) .NET F +; 90 : i* + -+ 86+8 > 6/ +- ,-+/?0 ; ?0 9 i/i 8 , 08 +;*
/)+/ + +*i-7 + * 6 -7 i / 0, +/ . T) * 0 -+ 86+8 =+ i 9i/) .NET /)
+ 6; 06* -+ 86+8 * +v+i-+=- /0 /) v -0, i -6 i 8 M+ +8 C < C < Vi*6+-
B+*i + J+v+ S i,/. T) .NET ? +; 90 : , 0vi * /) ?06 +/i0 ?0 0;,0 /* /0
i / + / * +;- **-7< 9) /) -0 +--7 0 ;0/ -7 0 i?? / ,-+/?0 ;*. I/ */+ + i5 *
0;;0 +/+ /7, * + 0;;6 i +/i0 * , 0/0 0-* *0 /)+/ 0;,0 /* +/ i
i?? / -+ 86+8 * + +*i-7 i / 0, +/ .
K.NET i* +-*0 /) 0-- /iv +; 8iv /0 v+ i06* *0?/9+ 0;,0 /*
=6i-/ 6,0 /) .NET ,-+/?0 ;. T) * 9i-- = =0/) , 0 6 /* @Vi*6+- S/6 i0.NET +
Wi 09*.NET S v < ?0 i */+ + * vi * @-i: P+**,0 /< .NET M7 S vi *< +
*0 0 .
THE .NET FRAMEWORK
T) .NET F +; 90 : )+* /90 ;+i ,+ /*
1. T) C0;;0 L+ 86+8 R6 /i; @CLR .
2. A )i + )i +- * / 0? -+** -i= + i *.
T) CLR i* * i= +* /) K x 6/i0 8i 0? .NET. I/ , 0vi * /) vi 0 ; /
9i/)i 9)i ) , 08 +;* 6 . T) ;0*/ i;,0 /+ / ? +/6 * +
♦ C0 v *i0 ? 0; + -09>- v - +** ;=- >*/7- -+ 86+8 < +--
I / ; i+/ L+ 86+8 @IL < i /0 0 +/iv /0 /) ,-+/?0 ; = i 8
x 6/ 0 .
♦ M ;0 7 ;+ +8 ; /< 0/+=-7 i -6 i 8 8+ =+8 0-- /i0 .
♦ C) :i 8 + ?0 i 8 * 6 i/7 */ i /i0 * 0 /) 6 i 8 0 .
♦ L0+ i 8 + x 6/i 8 , 08 +;*< 9i/) v *i0 0 / 0- + 0/) *6 )
? +/6 *.
♦ T) ?0--09i 8 ? +/6 * 0? /) .NET ? +; 90 : + +-*0 90 /) * i,/i0
MANAGED CODE
T) 0 /)+/ /+ 8 /* .NET< + 9)i ) 0 /+i * /+i x/ +
8/18/2019 52306346 Alarm Management
11/82
I ?0 ;+/i0 > K; /+ +/+ > /0 * i= i/* -?. W)i-*/ =0/) ;+ +8 + 6 ;+ +8 0
+ 6 i /) 6 /i; < 0 -7 ;+ +8 0 0 /+i * /) i ?0 ;+/i0 /)+/ +--09* /) CLR
/0 86+ + / < ?0 i */+ < *+? x 6/i0 + i / 0, +=i-i/7.
MANAGED DATA
Wi/) M+ +8 C0 0; * M+ +8 D+/+. CLR , 0vi * ; ;0 7
+--0 +/i0 + D +- -0 +/i0 ?+ i-i/i *< + 8+ =+8 0-- /i0 . S0; .NET -+ 86+8 * 6*
M+ +8 D+/+ =7 ?+6-/< *6 ) +* C < Vi*6+- B+*i .NET + JS i,/.NET< 9) +*
0/) *< +; -7 C < 0 0/. T+ 8 /i 8 CLR + < , i 8 0 /) -+ 86+8 706 6*i 8<
i;,0* /+i 0 */ +i /* 0 /) ? +/6 * +v+i-+=- . A* 9i/) ;+ +8 + 6 ;+ +8
0 < 0 + )+v =0/) ;+ +8 + 6 ;+ +8 +/+ i .NET +,,-i +/i0 * > +/+ /)+/
0 * / 8 / 8+ =+8 0-- / =6/ i */ + i* -00: +?/ =7 6 ;+ +8 0 .
COMMON T0PE S0STEM
T) CLR 6* * *0; /)i 8 +-- /) C0;;0 T7, S7*/ ; @CTS /0 */ i /-7
?0 /7, >*+? /7. T)i* *6 * /)+/ +-- -+** * + 0;,+/i=- 9i/) + ) 0/) < =7
* i=i 8 /7, * i + 0;;0 9+7. CTS ?i )09 /7, * 90 : 9i/)i /) 6 /i; <
9)i ) +=- * /7, * i 0 -+ 86+8 /0 i / 0, +/ 9i/) /7, * i + 0/) -+ 86+8 <
i -6 i 8 0**>-+ 86+8 x ,/i0 )+ -i 8. A* 9 -- +* *6 i 8 /)+/ /7, * + 0 -7 6*
i +,, 0, i+/ 9+7*< /) 6 /i; +-*0 *6 * /)+/ 0 0 * / +// ;,/ /0 + ** ; ;0 7
/)+/ )+* / = +--0 +/ /0 i/.
COMMON LANGUAGE SPECIFICATION
T) CLR , 0vi * =6i-/>i *6,,0 / ?0 -+ 86+8 i / 0, +=i-i/7. T0 *6 /)+/
706 + v -0, ;+ +8 0 /)+/ + = ?6--7 6* =7 v -0, * 6*i 8 + 7
, 08 +;;i 8 -+ 86+8 < + * / 0? -+ 86+8 ? +/6 * + 6- * ?0 6*i 8 /) ; +-- /)
C0;;0 L+ 86+8 S, i?i +/i0 @CLS )+* = ?i . C0;,0 /* /)+/ ?0--09 /) *
6- * + x,0* 0 -7 CLS ? +/6 * + 0 *i CLS> 0;,-i+ /.
THE CLASS LIBRAR0
.NET , 0vi * + *i 8- > 00/ )i + )7 0? -+** *< 0 /+i i 8 0v ##
/7, *. T) 00/ 0? /) +; *,+ i* +-- S7*/ ; /)i* 0 /+i * =+*i /7, * -i: B7/
8/18/2019 52306346 Alarm Management
12/82
D06=- < B00- + < + S/ i 8< +* 9 -- +* O= /. A-- 0= /* iv ? 0; S7*/ ;. O= /.
A* 9 -- +* 0= /*< /) + v+-6 /7, *. V+-6 /7, * + = +--0 +/ 0 /) */+ :< 9)i )
+ , 0vi 6* ?6- ?- xi=i-i/7. T) + +-*0 ??i i / ; + * 0? 0 v /i 8 v+-6 /7, * /0
0= / /7, * i? + 9) **+ 7.
T) * / 0? -+** * i* , //7 0;, ) *iv < , 0vi i 8 0-- /i0 *< ?i- <
* < + /90 : I O< /) + i 8< + *0 0 < +* 9 -- +* XML + +/+=+* 0 /ivi/7.
T) -+** -i= + 7 i* *6= ivi i /0 + 6;= 0? * /* @0 +; *,+ * < + )
, 0vi i 8 i*/i / + +* 0? ?6 /i0 +-i/7< 9i/) , i * = /9 /) +; *,+ * : ,/
/0 + ;i i;6;.
LANGUAGES SUPPORTED B0 .NET
T) ;6-/i>-+ 86+8 +,+=i-i/7 0? /) .NET F +; 90 : + Vi*6+-
S/6 i0 .NET +=- * v -0, * /0 6* /) i xi*/i 8 , 08 +;;i 8 *:i--* /0 =6i- +-- /7, *
0? +,,-i +/i0 * + XML W = * vi *. T) .NET ? +; 90 : *6,,0 /* 9 v *i0 * 0?
Mi 0*0?/ * 0- ?+v0 i/ * Vi*6+- B+*i + C @+* VB.NET + M+ +8 C < =6/
/) + +-*0 + 6;= 0? 9 + i/i0 * /0 /) ?+;i-7.
Vi*6+- B+*i .NET )+* = 6, +/ /0 i -6 ;+ 7 9 + i;, 0v
-+ 86+8 ? +/6 * /)+/ ;+: i/ + ,09 ?6- 0= />0 i / , 08 +;;i 8 -+ 86+8 . T) *
? +/6 * i -6 i ) i/+ < i / ?+ *< + 0v -0+ i 8< +;0 8 0/) *. Vi*6+- B+*i +-*0
09 *6,,0 /* */ 6 /6 x ,/i0 )+ -i 8< 6*/0; +// i=6/ * + +-*0 *6,,0 /* ;6-/i>
/) + i 8.
Vi*6+- B+*i .NET i* +-*0 CLS 0;,-i+ /< 9)i ) ; + * /)+/ + 7 CLS>
0;,-i+ / -+ 86+8 + 6* /) -+** *< 0= /*< + 0;,0 /* 706 +/ i Vi*6+-
B+*i .NET.
M+ +8 Ex/ *i0 * ?0 C + +// i=6/ , 08 +;;i 8 + 6*/ *0; 0?
/) )+ ; /* ;+ /0 /) C -+ 86+8 . M+ +8 Ex/ *i0 * *i;,-i?7 /) /+*: 0?
;i8 +/i 8 xi*/i 8 C +,,-i +/i0 * /0 /) 9 .NET F +; 90 :.
8/18/2019 52306346 Alarm Management
13/82
C i* Mi 0*0?/ * 9 -+ 86+8 . I/ * + C>*/7- -+ 86+8 /)+/ i* ** /i+--7
KC ?0 R+,i A,,-i +/i0 D v -0,; / . U -i: 0/) -+ 86+8 *< i/* *, i?i +/i0 i*
6*/ /) 8 +;;+ 0? /) -+ 86+8 . I/ )+* 0 */+ + -i= + 7 0? i/* 09 < + i */ + )+*
= *i8 9i/) /) i / /i0 0? 6*i 8 /) .NET -i= + i * +* i/* 09 .
Mi 0*0?/ Vi*6+- J .NET , 0vi * /) +*i */ / + *i/i0 ?0 J+v+>-+ 86+8
v -0, * i /0 /) 90 - 0? XML W = S vi * + +;+/i +--7 i;, 0v * /)
i / 0, +=i-i/7 0? J+v+>-+ 86+8 , 08 +;* 9i/) xi*/i 8 *0?/9+ 9 i// i + v+ i /7 0?
0/) , 08 +;;i 8 -+ 86+8 *.
A /iv S/+/ )+* +/ Vi*6+- P - + Vi*6+- P7/)0 < 9)i ) +=-
.NET>+9+ +,,-i +/i0 * /0 = =6i-/ i i/) P - 0 P7/)0 . B0/) , 0 6 /* + =
i / 8 +/ i /0 /) Vi*6+- S/6 i0 .NET vi 0 ; /. Vi*6+- P - i -6 * *6,,0 / ?0
A /iv S/+/ * P - D v (i/.
O/) -+ 86+8 * ?0 9)i ) .NET 0;,i- * + +v+i-+=- i -6
• FORTRAN
• COBOL
• Ei?? -
Fi81 . N / F +; 90 :
ASP.NET XML WEB SERVICES
Wi 09* F0 ;*
B+* C-+** Li= + i *
C0;;0 L+ 86+8 R6 /i; O, +/i 8 S7*/ ;
4./ FEATURES OF C5. NET
C .NET i* +-*0 0;,-i+ / 9i/) CLS @C0;;0 L+ 86+8 S, i?i +/i0 +
*6,,0 /* */ 6 /6 x ,/i0 )+ -i 8. CLS i* * / 0? 6- * + 0 */ 6 /* /)+/ +
*6,,0 / =7 /) CLR @C0;;0 L+ 86+8 R6 /i; . CLR i* /) 6 /i; vi 0 ; /
, 0vi =7 /) .NET F +; 90 : i/ ;+ +8 * /) x 6/i0 0? /) 0 + +-*0 ;+: *
/) v -0,; / , 0 ** +*i =7 , 0vi i 8 * vi *.
8/18/2019 52306346 Alarm Management
14/82
C .NET i* + CLS> 0;,-i+ / -+ 86+8 . A 7 0= /*< -+** *< 0 0;,0 /* /)+/
+/ i C .NET + = 6* i + 7 0/) CLS> 0;,-i+ / -+ 86+8 . I + i/i0 < 9 +
6* 0= /*< -+** *< + 0;,0 /* +/ i 0/) CLS> 0;,-i+ / -+ 86+8 * i
C .NET. T) 6* 0? CLS *6 * 0;,- / i / 0, +=i-i/7 +;0 8 +,,-i +/i0 *<
8+ - ** 0? /) -+ 86+8 * 6* /0 +/ /) +,,-i +/i0 .
CONSTRUCTORS AND DESTRUCTORS:
C0 */ 6 /0 * + 6* /0 i i/i+-i5 0= /*< 9) +* */ 6 /0 * + 6* /0
*/ 07 /) ;. I 0/) 90 *< */ 6 /0 * + 6* /0 - +* /) *06 * +--0 +/ /0 /)
0= /. I C .NET /) *6= ?i +-i5 , 0 6 i* +v+i-+=- . T) *6= ?i +-i5 , 0 6 i*
6* /0 0;,- / /) /+*:* /)+/ ;6*/ = , ?0 ; 9) + 0= / i* */ 07 . T) *6=
?i +-i5 , 0 6 i* +-- +6/0;+/i +--7 9) + 0= / i* */ 07 . I + i/i0 < /)
*6= ?i +-i5 , 0 6 + = +-- 0 -7 ? 0; /) -+** i/ = -0 8* /0 0 ? 0; iv
-+** *.
GARBAGE COLLECTION
G+ =+8 C0-- /i0 i* + 0/) 9 ? +/6 i C .NET. T) .NET F +; 90 :
;0 i/0 * +--0 +/ *06 *< *6 ) +* 0= /* + v+ i+=- *. I + i/i0 < /) .NET
F +; 90 : +6/0;+/i +--7 - +* * ; ;0 7 ?0 6* =7 */ 07i 8 0= /* /)+/ + 0
-0 8 i 6* .
I C .NET< /) 8+ =+8 0-- /0 ) :* ?0 /) 0= /* /)+/ + 0/ 6 /-7 i
6* =7 +,,-i +/i0 *. W) /) 8+ =+8 0-- /0 0; * + 0** + 0= / /)+/ i* ;+ : ?0
8+ =+8 0-- /i0 < i/ - +* * /) ; ;0 7 0 6,i =7 /) 0= /.
OVERLOADING
Ov -0+ i 8 i* + 0/) ? +/6 i C . Ov -0+ i 8 +=- * 6* /0 ?i ;6-/i,-
, 0 6 * 9i/) /) *+; +; < 9) + ) , 0 6 )+* + i?? / * / 0? + 86; /*.
B *i * 6*i 8 0v -0+ i 8 ?0 , 0 6 *< 9 + 6* i/ ?0 0 */ 6 /0 * + , 0, /i * i
+ -+**.
MULTITHREADING:
8/18/2019 52306346 Alarm Management
15/82
C .NET +-*0 *6,,0 /* ;6-/i/) + i 8. A +,,-i +/i0 /)+/ *6,,0 /* ;6-/i/) + i 8
+ )+ - ;6-/i,- /+*:* *i;6-/+ 06*-7< 9 + 6* ;6-/i/) + i 8 /0 +* /) /i;
/+: =7 + +,,-i +/i0 /0 *,0 /0 6* i / + /i0 .
STRUCTURED E CEPTION HANDLINGC .NET *6,,0 /* */ 6 /6 )+ -i 8< 9)i ) +=- * 6* /0 / / + ;0v
0 * +/ 6 /i; . I C .NET< 9 /0 6* T 7 C+/ ) Fi +--7 */+/ ; /* /0 +/
x ,/i0 )+ - *. U*i 8 T 7 C+/ ) Fi +--7 */+/ ; /*< 9 + +/ 0=6*/ +
?? /iv x ,/i0 )+ - * /0 i;, 0v /) , ?0 ;+ 0? 06 +,,-i +/i0 .
THE .NET FRAMEWORK
T) .NET F +; 90 : i* + 9 0;,6/i 8 ,-+/?0 ; /)+/ *i;,-i?i * +,,-i +/i0
v -0,; / i /) )i8)-7 i*/ i=6/ vi 0 ; / 0? /) I / /.
OBJECTIVES OF .NET FRAMEWORK
1. T0 , 0vi + 0 *i*/ / 0= />0 i / , 08 +;;i 8 vi 0 ; / 9) /) 0= /
0 * i* */0 + x 6/ -0 +--7 0 I / /> i*/ i=6/ < 0 x 6/ ;0/ -7.
2. T0 , 0vi + 0 > x 6/i0 vi 0 ; / /0 ;i i;i5 * *0?/9+ ,-07; / +
86+ + / * *+? x 6/i0 0? 0 .
3. E-i;i +/ * /) , ?0 ;+ , 0=- ;*.
T) + i?? / /7, * 0? +,,-i +/i0 < *6 ) +* Wi 09*>=+* +,,-i +/i0 * +
W =>=+* +,,-i +/i0 *.
FEATURES OF S3L-SERVER
T) OLAP S vi * ? +/6 +v+i-+=- i S L S v v *i0 &.# i* 09 +--
S L S v 2### A +-7*i* S vi *. T) / ; OLAP S vi * )+* = ,-+ 9i/) /)
/ ; A +-7*i* S vi *. A +-7*i* S vi * +-*0 i -6 * + 9 +/+ ;i i 8 0;,0 /.
T) R ,0*i/0 7 0;,0 / +v+i-+=- i S L S v v *i0 &.# i* 09 +-- Mi 0*0?/
S L S v 2### M /+ D+/+ S vi *. R ? * /0 /) 0;,0 / 09 6* /) / ;
8/18/2019 52306346 Alarm Management
16/82
M /+ D+/+ S vi *. T) / ; ,0*i/0 7 i* 6* 0 -7 i ? /0 /) ,0*i/0 7
8i 9i/)i M /+ D+/+ S vi *
S L>SERVER +/+=+* 0 *i*/ 0? *ix /7, 0? 0= /*<
T) 7 + <
1. TABLE
2. UERY
3. FORM
4. REPORT
". MACRO
TABLE:
A +/+=+* i* + 0-- /i0 0? +/+ +=06/ + *, i?i /0,i .
VIEWS OF TABLE:
W + 90 : 9i/) + /+=- i /90 /7, *<
1. D *i8 Vi 9
2. D+/+*) / Vi 9
DESIGN VIEW
T0 =6i- 0 ;0 i?7 /) */ 6 /6 0? + /+=- 9 90 : i /) /+=- *i8 vi 9. W
+ *, i?7 9)+/ :i 0? +/+ 9i-- = )0- .
DATASHEET VIEW
T0 + < i/ 0 + +-7* * /) +/+ i/* -? 9 90 : i /+=- * +/+*) / vi 9 ;0 .
3UER0:
8/18/2019 52306346 Alarm Management
17/82
A 6 7 i* + 6 */i0 /)+/ )+* /0 = +*: /) +/+. A ** 8+/) * +/+ /)+/
+ *9 * /) 6 */i0 ? 0; 0 0 ;0 /+=- . T) +/+ /)+/ ;+: 6, /) + *9 i* i/)
7 +* / @i? 706 i/ i/ 0 + * +,*)0/ @i/ + 0/ = i/ .E+ ) /i; 9 6 6 7< 9 8 /
-+/ */ i ?0 ;+/i0 i /) 7 +* /. A ** i/) i*,-+7* /) 7 +* / 0 * +,*)0/ ?0 6* /0
vi 9 0 , ?0 ; + + /i0 0 i/< *6 ) +* - /i 8 0 6, +/i 8.
6. S0STEM DESIGN
D *i8 i* 0 9i/) i /i?7i 8 *0?/9+ 0;,0 /* *, i?7i 8
-+/i0 *)i,* +;0 8 0;,0 /*. S, i?7i 8 *0?/9+ */ 6 /6 + , 0vi i 8 =-6 , i /
?0 /) 0 6; / ,)+* . M0 6-+ i/7 i* 0 0? /) *i +=- , 0, /i * 0? -+ 8 *7*/ ;*. I/
i;,-i * /)+/ /) *7*/ ; i* ivi i /0 * v +- ,+ /*. I *6 ) + ;+ < /) i / + /i0
= /9 ,+ /* i* ;i i;+- - + -7 *, i?i . D *i8 9i-- x,-+i *0?/9+ 0;,0 /* i
/+i-. T)i* 9i-- ) -, /) i;,- ; /+/i0 0? /) *7*/ ;. M0 0v < /)i* 9i-- 86i /)
?6 /) )+ 8 * i /) *7*/ ; /0 *+/i*?7 /) ?6/6 6i ; /*.
D(#(,("! D&(7)( :
R 8i*/ +/i0 ?0A6/) /i +/i0 L0 +-i5+/i0D+/+=+*
V+-i N0 *C) :i 8
C0-- /i 8 F+6-/D /+i-*
V i?7 /) 6* +/LOGIN P+8
Di*/ i=6/i 8 V+-i N0 *
C0-- /i 8 +-- ?+6-//+i-* /0 = ,0 /
8/18/2019 52306346 Alarm Management
18/82
T(, ! S#)u'#u)!:
Au#$!%#&'(#&o% T(, !:
V( &d Nod!" T(, !:
8/18/2019 52306346 Alarm Management
19/82
F(u # D!#(& " T(, !:
S "#! D!"&7%:
8/18/2019 52306346 Alarm Management
20/82
U"! '("! D&(7)( :
C ("" D&(7)( :
8/18/2019 52306346 Alarm Management
21/82
A u t h e n t i c a t i o nU s e r N a m eP a s s w o r dS e c u r i t y Q u e s t io n
V e r i fi c a t i o n ( )F o rg o t p a s s w o r d ( )
N o d e V e r if i c a t io nN o d e n a m e
C o l l e c t in g A l l N o d e s ( )V e r i fi c a t i o n ( )! i s t r i " u t i o n ( )
V a l id N o d e d i s t ri " u t io nN o d e N a m eS e r #e r N a m eF a u lt ! e t a i ls
C o l l e c t in g V a l i d N o d e ( )F a u l t ! e t a i l s ( )$ e t S e r #e r N a m e ( )
! i s t r i " u t e d S y s t e mN o d e N a m e%P A d d r e s sm e s s a g e
$ e t % P A d d r e s s ( )& s g ' r a n s fe r ()F i l e e n g t h C a l c ( )
r ro r ' r a n s f e r ()
O,8!'# D&(7)( :
S#(#! D&(7)( :
A6/) /i +/i0
C-i /*S v
Di*/ i=6/S7*/ ;
E 0 * i 8
N0V i?i +/i0
Di*/ i=6/ +-0 +-i5 /)?+6-/
8/18/2019 52306346 Alarm Management
22/82
Authentication
Verify the user
Collecting allNodes
Chec* and Storethe faults
!istri"uteNodes
For Ser#er
For Clients
8/18/2019 52306346 Alarm Management
23/82
Authentication
Collect ValidNodes
!istri"ute file +data
)rror predictand send
For Clients
8/18/2019 52306346 Alarm Management
24/82
A'#&9 D&(7)( :
A uth en tic at io n
Verify the user
Collecting All
Nodes to #erify
Chec* and S tore thefault !etails
!istri"ute the#alid nodes
For ser#er
For Clients
8/18/2019 52306346 Alarm Management
25/82
A uthen tic atio n
Collect #alid nodesfrom ser#er
!istri"ute Files
)rror Predictionand dis tri"ution
For Clients
S! u!%'! D&(7)( :@i S v
8/18/2019 52306346 Alarm Management
26/82
Authentication Collect Nodesfrom the networ*
Chec*ing thenode
Fault(ocali,ation
Store the fault
Verify the user who is ser#er or client
Collected nodes are sending to #erification
Pro#ide the fault details
Storing- - -
@ii C-i /*
Authentication Verify the user Collect the #alidnodes
!istri"uted SystemFor File Sharing
)rror Prediction and !istri"uteto locali,e the fault
Verification- - -
transfer a file to the #alid node people
Verify the transaction while the application is running
Co ;o%!%# D&(7)( :
8/18/2019 52306346 Alarm Management
27/82
Authentication
Node Verfication andFault ocali,ation
Fault detailsstoring
Ser#er&achine
!istri"uted System(Client System)
CollectValid Nodes
rror Prediction
D(#( F o< D&(7)( :
E-R D&(7)( :
A6/) /i +/i0
S v S7*/ ; C-i / S7*/ ;
C0-- / +-- /)0 * ? 0;
/) /90 :
V i?7 /)0 * /0 =
v+-i
Di*/ i=6/ +-0 +-i5 /)?+6-/
C0-- / 0 -7 /)v+-i 0 *
P i / /) E 0 +L0 +-i5 i * v*i
A6/) /i +/i0
U*+;
S 6 i/7C0
S 6 i/7D /+i-*
V i?i +/i0
A-+ ;M+ +8 ; /
C0-- / +--0 *
V i?i N0
Di*/ i=6/i0
Di*/ i=6/S7*/ ;
C0-- /v+-i
0 * E 0P i +/i0
8/18/2019 52306346 Alarm Management
28/82
S "#! A)'$!'#u)!:
=. S0STEM TESTING AND MAINTENANCE
T */i 8 i* vi/+- /0 /) *6 ** 0? /) *7*/ ;. S7*/ ; / */i 8 ;+: * + -08i +-+**6;,/i0 /)+/ i? +-- ,+ /* 0? /) *7*/ ; + 0 /< /) 80+- 9i-- = *6 **?6--7
+ )i v . I /) / */i 8 , 0 ** 9 / */ /) + /6+- *7*/ ; i + 0 8+ i5+/i0 + 8+/)
0 * ? 0; /) 9 *7*/ ; 0, +/ * i ?6-- ??i i 7 +* */+/ . S7*/ ; / */i 8 i* /)
*/+8 0? i;,- ; /+/i0 < 9)i ) i* +i; /0 *6 i 8 /)+/ /) *7*/ ; 90 :* + 6 +/ -7 +
??i i /-7.
A6/) /i +/i0
V i?i +/i0 +L0 +-i5+/i0
N /90 :
D(#(,("!
Di*/ i=6/ /) v+-i0 *
Di*/ i=6/S7*/ ;
8/18/2019 52306346 Alarm Management
29/82
I /) / */i 8 , 0 ** 9 / */ /) + /6+- *7*/ ; i + 0 8+ i5+/i0 + 8+/)
0 * ? 0; /) 9 *7*/ ; + /+: i i/i+/iv * /0 0 / /) *+; . A-- /) ? 0 /> +
=+ :> 0 /ivi/7 + / */ /0 = *6 /)+/ /) 9 *7*/ ; 0, +/ * i ?6-- ??i i 7
+* */+/ . S7*/ ; / */i 8 i* /) */+8 0? i;,- ; /+/i0 < 9)i ) i* +i; +/ *6 i 8 /)+/
/) *7*/ ; 90 :* + 6 +/ -7 + ??i i /-7.
T) ;+i 0= /iv 0? / */i 8 i* /0 6 0v 0 * ? 0; /) *7*/ ;. F0 /)
6 0v i 8 , 0 ** 9 )+v /0 8iv , 0, i ,6/ +/+ /0 /) *7*/ ;. S0 9 *)06- )+v
;0 0 * i06* /0 8iv i ,6/ +/+. I/ i* i;,0 /+ / /0 8iv 0 / i ,6/* /0 ??i i /
/ */i 8.
T */i 8 i* 0 ?0 + ) ;0 6- . A?/ / */i 8 +-- /) ;0 6- *< /) ;0 6- * +
i / 8 +/ + / */i 8 0? /) ?i +- *7*/ ; i* 0 9i/) /) / */ +/+< *, i+--7 *i8 /0
*)09 /)+/ /) *7*/ ; 9i-- 0, +/ *6 **?6--7 i +-- i/* +*, /* 0 i/i0 *. T)6* /)
*7*/ ; / */i 8 i* + 0 ?i ;+/i0 /)+/ +-- i* 0 / + + 0,,0 /6 i/7 /0 *)09 /) 6* /)+/
/) *7*/ ; 90 :*. I + 6+/ / */i 8 0 0 >/ */i 8 - + * /0 0 * /)+/ ;+7 +,, + ? 9
;0 /)* -+/ .
T)i* 9i-- +/ /90 , 0=- ;*
Ti; -+7 = /9 /) +6* + +,, + + 0? /) , 0=- ;. T) ?? / 0? /)
*7*/ ; 0 * 0 ?i- * + 0 * 9i/)i /) *7*/ ;.
T) ,6 ,0* 0? /) *7*/ ; / */i 8 i* /0 0 *i +-- /) -i: -7 v+ i+/i0 * /0 9)i )
i/ 9i-- = *688 */ + ,6*) /) *7*/ ; /0 i/* -i;i/*.
T) / */i 8 , 0 ** ?0 6* * 0 -08i +- i / v+-* 0? /) *0?/9+ *6 i 8 /)+/ +--
/) */+/ ; /* )+v = / */ + 0 /) ?6 /i0 i / v+-* @i. .< 0 6 /i 8 / */* /0
6 0v 0 * + *6 /)+/ ?i i ,6/* 9i-- , 0 6 + /6+- *6-/* /)+/ +8 9i/)
/) 6i *6-/*. T */i 8 )+* /0 = 0 6*i 8 /) /90 0;;0 */ ,* U i/ / */i 8 +
I / 8 +/i0 / */i 8. I /) , 0 / *7*/ ; / */i 8 i* ;+ +* ?0--09*
T) , 0 6 - v - / */i 8 i* ;+ ?i */. B7 8ivi 8 i;, 0, i ,6/*< /) 0 *
0 6 + 0/ + -i;i +/ . T)i* i* /) ?i +- */ , i *7*/ ; -i? 7 - . ! 9
i;,- ; / /) / */ 0 >? *7*/ ; i /0 +->-i? vi 0 ; / + ;+: **+ 7
)+ 8 *< 9)i ) 6 * i + 0 -i ?+*)i0 . ! *7*/ ; ;+i / + i* 0 v 7 ;0 /)*
8/18/2019 52306346 Alarm Management
30/82
0 7 + =+* 0 0;,+ 7 ,0-i i *< + i* ) : ?0 0 * -i: 6 /i; 0 *< -0 8 6
0 * + 0/) ;+i / + * -i: /+=- v i?i +/i0 + ,0 /*.
=.1. UNIT TESTING
U i/ / */i 8 v i?i +/i0 ??0 /* 0 /) *;+-- */ 6 i/ 0? *0?/9+ *i8 < ;0 6- .T)i* i* : 09 +* KM0 6- T */i 8 . T) ;0 6- * + / */ * ,+ +/ -7. T)i* / */i 8 i*
+ i 06/ 6 i 8 , 08 +;;i 8 */+8 i/* -?. I /) * / */i 8 */ ,*< + ) ;0 6- i* ?06
/0 = 90 :i 8 *+/i*?+ /0 i-7 +* 8+ /0 /) x, / 06/,6/ ? 0; /) ;0 6- .
=./. INTEGRATION TESTING
I / 8 +/i0 / */i 8 i* + *7*/ ;+/i / ) i 6 ?0 0 */ 6 /i 8 / */* /0 6 0v 0
+**0 i+/ 9i/)i /) i / ?+ . I /) , 0 /< +-- /) ;0 6- * + 0;=i + /) /)
/i , 08 +;; i* / */ +* + 9)0- . I /) i / 8 +/i0 >/ */i 8 */ ,< +-- /) 0
6 0v i* 0 / ?0 /) x/ / */i 8 */ ,*.
>. S0STEM IMPLEMENTATION
I;,- ; /+/i0 i* /) */+8 0? /) , 0 / 9) /) /) 0 /i +- *i8 i* /6
06/ i /0 + 90 :i 8 *7*/ ;. T)6* i/ + = 0 *i /0 = /) ;0*/ i/i +- */+8 i
+ )i vi 8 + *6 **?6- 9 *7*/ ; + i 8ivi 8 /) 6* < 0 ?i /)+/ /) 9 *7*/ ;
9i-- 90 : + = ?? /iv .
T) i;,- ; /+/i0 */+8 i v0-v * + ?6- ,-+ i 8< i v */i8+/i0 0? /) xi*/i 8
*7*/ ; + i/ * 0 */ +i /* 0 i;,- ; /+/i0 < *i8 i 8 0? ; /)0 * /0 + )i v
)+ 8 0v + v+-6+/i0 0? )+ 8 0v ; /)0 *.
8/18/2019 52306346 Alarm Management
31/82
I;,- ; /+/i0 i* /) , 0 ** 0? 0 v /i 8 + 9 *7*/ ; *i8 i /0 0, +/i0 .
I/ i* /) ,)+* /)+/ ?0 6* * 0 6* / +i i 8< *i/ , ,+ +/i0 + ?i- 0 v *i0 ?0
i */+--i 8 + + i +/ *7*/ ;. T) i;,0 /+ / ?+ /0 /)+/ *)06- = 0 *i ) i* /)+/
/) 0 v *i0 *)06- 0/ i* 6,/ /) ?6 /i0 i 8 0? /) 0 8+ i5+/i0 .
Fu#u)! E%$(%'! !%#:T)i* 90 : + = x/ i * v +- i / */i 8 9+7*. F0 x+;,- < i -6 i 8
0/) /7, * 0? ;0 i/0 * 906- +--09 /+i- + +-7*i* 0? /) 0,/i +- -+7 . Fi +--7< /)
, 0,0* +,, 0+ ) + = +*i-7 x/ /0 0/) + +* 0? ;0 i/0 i 8 + * *0 +/+
6 /i0 @+**6;i 8 /)+/ +,, 0, i+/ , 0,+8+/i0 ;0 -* + 0 *i i -6 i 8
*i8 +- 0**/+-: ;0 i/0 i 8< , 0 ** ;0 i/0 i 8 + 0/) -+/ +,,-i +/i0 *.
A;; &'(#&o%":
T) F+6-/ L0 +-i5+/i0 *)06- = 6* ?6- 9) 9 + / + *? i 8 + * 6 +/+ /0706 , 0,- 0 /) i*/ i=6/ /90 : +,,-i +/i0 . T)i* *)06- = v 7 6* ?6- /0 ?i 06/
/) ?+6-/ 0? 0 * 9)i ) + 6*i 8 9i/)i /) 0 8+ i5+/i0 .
Co%' u"&o%:T)i* , 0 / i* -0 +-i5i 8 /) ?+6-/ , i /i0 i /) /90 :. 9 + ** /)
i;,0 /+ / , 0=- ; 0? 0,/i;i5i 8 /) ?+6-/>-0 +-i5+/i0 i / + *,+ / +-->0,/i +- /90 :*
/) 068) ;i i;i5+/i0 0? + /iv+/ 0,/i +- ;0 i/0 i 8 6i,; / 9)i- ;+i /+i i 8 ?6--
-0 +-i5+/i0 0v +8 . W ?i /) 0 */ 6 /i0 0? ;0 i/0 i 8 0;+i * + , 0v
/)+/ *6 ) )i + )i +--7 i*/ i=6/ ?+6-/ -0 +-i5+/i0 + )i v * i /i +- ?+6-/>-0 +-i5+/i0
+* /) / +-i5 ;0 i/0 i 8. W + , 00? /)+/ A )i vi 8 + 6 +/ + ??i i / ?+6-/
-0 +-i5+/i0 i -+ 8 / + *,+ / +-->0,/i +- /90 :* @TON* i* + i;,0 /+ / +
)+-- 8i 8 , 0=- ; 6 /0 6 i 6 ?+6-/>, 0,+8+/i0 < /i; 0 */ +i /*< + * +-+=i-i/7
6i ; /*.
R!*!)!%'!" o) B&, &o7)(;$ :1 M. MQ + < D. M+ 6i*< R. A. B+ 7< + S. G. Fi < KS!'u) &""u!" &% ( -o;#&'(
%!#
8/18/2019 52306346 Alarm Management
32/82
" T. Y. C)09< F. C)6 +:< + A. M. F )< KF("# o;#&'( ( !) !"$ ;)o#!'#&o%u"&%7 ;)!-')o""-'o%%!'#!d #)(& " < IEEE ACM T + *. N /90 :i 8< v0-. 12< 0. 3<
,,. "3' "4%< 2##4.
1@. APPENDI :
SCREEN SHOT:
8/18/2019 52306346 Alarm Management
33/82
8/18/2019 52306346 Alarm Management
34/82
8/18/2019 52306346 Alarm Management
35/82
8/18/2019 52306346 Alarm Management
36/82
8/18/2019 52306346 Alarm Management
37/82
8/18/2019 52306346 Alarm Management
38/82
8/18/2019 52306346 Alarm Management
39/82
8/18/2019 52306346 Alarm Management
40/82
8/18/2019 52306346 Alarm Management
41/82
8/18/2019 52306346 Alarm Management
42/82
8/18/2019 52306346 Alarm Management
43/82
8/18/2019 52306346 Alarm Management
44/82
8/18/2019 52306346 Alarm Management
45/82
8/18/2019 52306346 Alarm Management
46/82
8/18/2019 52306346 Alarm Management
47/82
DATA TABLE STUCTURE:
SENDER:
8/18/2019 52306346 Alarm Management
48/82
RECEIVER:
FILE TRANSFER TABLE:
8/18/2019 52306346 Alarm Management
49/82
8/18/2019 52306346 Alarm Management
50/82
i1 % Message:ox .S5ow% 3 re you want to close t5is application3 / 3Message lert3 / Message:ox:uttons .>i1 %Message:ox.S5ow%3 re you c5ec- your ?S07 4 M0 is
ccepted or not 3/3Message lert3/Message:ox:uttons.>" >> txt#oxpwd.Text 2 string.0mpty; >> #tnc5ec-.Focus%&;
>>) )
8/18/2019 52306346 Alarm Management
51/82
8/18/2019 52306346 Alarm Management
52/82
8/18/2019 52306346 Alarm Management
53/82
txt#oxpwd.Text 2 string .0mpty; txt#oxretypepwd.Text 2 string .0mpty; txt#oxnum#er.Text 2 string .0mpty; com#o:ox+.Text 2 3HHHHHSelect
8/18/2019 52306346 Alarm Management
54/82
Message:ox .S5ow% 3n Trygain......3 &;
txt#oxanswer.Text 2 string .0mpty; txt#oxanswer.Focus%&;
)
)
pri*ate *oid #tnc5ec-,Clic-% o# ect sender/ 0*ent rgs e& " try " i1 %d#conn.Connect,Data#ase%& 22 true & " cmd 2 new SqlCommand %3selectuser,name/password/security,question/answer 1rom aut5entication w5ereuser,name2@3 A txt#oxuser,name.Text A 3@3/ d#conn.con&;
reader2cmd.0xecute7eader%&; i1 %reader.6as7ows22 true & " i1 %reader.7ead%&& " username 2 readerI 3user,name3 J.ToString%&; pwd 2 readerI 3password3 J.ToString%&; question 2readerI 3security,question3 J.ToString%&; answer 2 readerI 3answer3 J.ToString%&; txt#oxquestion.Text 2 question.ToString%&; txt#oxanswer.Focus%&; )
) else " Message:ox .S5ow% 38lease gi*e your originalusername3 &;
)
) else " Message:ox .S5ow% 3Data#ase 5as not open properly3 &;
)
) catc5 % 0xception ex& "
Message:ox .S5ow%ex.Message&; )
8/18/2019 52306346 Alarm Management
55/82
) ))
C) :using System;
>>using System.Collections.Generic;>>using System.ComponentModel;using System.Data;>>using System.Drawing;>>using System.Linq;using System.Text;using System.Windows.Forms;using System.Management; >>using o# ect queryusing System.4et.4etwor-'n1ormation; >>To ping opertaionsusing System.4et;using System.4et.Soc-ets;using System.7untime.'nteropSer*ices;using System.'E;using System.Diagnostics; >>To use 8rocess classusing System.Data.SqlClient;
namespace WindowsForms pplication!" pu#lic partial class C5ec- $ Form
" Connection con 2 new Connection %&; ser*er se 2 new ser*er %&; int admin,status 2 ; >>'nt9= i 2 ; I Dll'mport %3winmm.dll3 / SetLast0rror 2 true / CallingCon*ention2 CallingCon*ention .Winapi&J
static extern #ool 8laySound% string ps(Sound/ 'nt8tr 5Mod/ SoundFlags s1&; pu#lic enum SoundFlags $ int " S4D,SK play sync5ronously %de1ault& K> S4D, SK play async5ronously K> S4D,4ED0F ?LT 2 x =/ >K silence % de1ault& i1 sound not1ound K> S4D,M0ME7< 2 x !/ >K ps(Sound points to a memory 1ile K> S4D,LEE8 2 x / >K loop t5e sound until nextsnd8laySound K> S4D,4ESTE8 2 x + / >K don@t stop any currently playingsound K> S4D,4EW 'T 2 x = / >K don@t wait i1 t5e dri*er is#usy K> S4D, L' S 2 x + / >K name is a registry alias K> S4D, L' S,'D 2 x ++ / >K alias is a prede1ined 'D K> S4D,F'L04 M0 2 x = / >K name is 1ile name K> S4D,70SE?7C0 2 x ! ! >K name is resource name or atomK> ) pu#lic static string str+/ remoteMac5ine4ameEr'8; pu#lic C5ec-%&
8/18/2019 52306346 Alarm Management
56/82
" 'nitiali(eComponent%&; ) pu#lic class ser*er " '80nd8oint ipend; Soc-et soc-; pu#lic ser*er%& " ipend 2 new '80nd8oint %'8 ddress . ny/ ! ! &; soc- 2 new Soc-et % ddressFamily .'nter4etwor-/Soc-etType .Stream/ 8rotocolType .Tcp&; >>soc-.Disconnect%true&; >>soc-.Close%&; i1 %soc-.Connected 22 1alse & "
soc-.:ind%ipend&; soc-.Listen%+ &;
) else "
soc-.S5utdown% Soc-etS5utdown .:ot5&; soc-.Close%&;
)
)
pu#lic static string curmsg; pu#lic static string Client,5ostname; pu#lic static string userdata; pu#lic static string ipas; pu#lic *oid Startser*er%& " try " >>#yteIJ res 2 new #yteI+ J;
Soc-et clientsoc- 2 soc-. ccept%&; #yte IJ clientdata 2 new #yte I+ =!J; clientsoc-.7ecei*e%clientdata&; >> 8lay Sound. . .
8laySound% 3D$NN:EE8 T6'NN0rrorLocali(ationNNWindowsForms pplication!NN larmToneNNalarm.wa*3 /'nt8tr .Oero/ SoundFlags .S4D,F'L04 M0 P SoundFlags .S4D, S>clientsoc-.Close%&;
8/18/2019 52306346 Alarm Management
57/82
) catc5 % 0xception ex& "
Message:ox .S5ow%ex.Message.ToString%&&; ) Startser*er%&; ) ) pri*ate *oid Form+,Load% o# ect sender/ 0*ent rgs e& " #ac-groundWor-er+.7unWor-er sync%&; lin-La#el+.Location 2 new System.Drawing. 8oint %!+Q/ R&;
t5is .6eig5t 2 ! ; t5is .Widt5 2 !R9; g#oxnetwor-error. isi#le 2 1alse ;
E# ectBuery o# ectBuery 2 new E# ectBuery %3select K 1rom
Win9=,4etwor- dapter w5ere 4etConnectionStatus2=3 &; >> = means connected ManagementE# ectSearc5er searc5er 2 newManagementE# ectSearc5er %o# ectBuery&;
int connected4etwor-s 2 searc5er.Get%&.Count;
i1 %connected4etwor-s 22 & " i1 % Message:ox .S5ow% 3C :L0 'S ?48L?G0DNn Can you wantto discard t5is application NnNn 4ote$ '1 you sol*ed t5is pro#lemplease clic- 4E 3 / 30rror lert3 / Message:ox:uttons .
8/18/2019 52306346 Alarm Management
58/82
8/18/2019 52306346 Alarm Management
59/82
net?tility.Start'n1o.7edirectStandard0rror 2 true ; >>Toindication o1 errors w5ile t5e application is process
net?tility.Start%&;
Stream7eader stream7eader 2 newStream7eader %net?tility.StandardEutput.:aseStream/net?tility.StandardEutput.Current0ncoding&;
string line 2 33 ;
w5ile %%line 2 stream7eader.7eadLine%&& 2 null & "
i1 %line.StartsWit5% 3NN3&&
"
list:ox+.'tems. dd%line.Su#string%=&.Su#string% /line.Su#string%=&.'ndexE1% 3 3 &&.To?pper%&&;
)
)
stream7eader.Close%&; net?tility.WaitFor0xit% &; >>wait some milliseconds 1orexisting t5e execution
) pri*ate *oid #utton+,Clic-% o# ect sender/ 0*ent rgs e& " admin,status 2 +; list:ox+.'tems.Clear%&; list:ox=.'tems.Clear%&;
Get,6ost,4ames%&;
>>timer+.0na#led 2 true; >>l#lmsg.Text 2 3Starting. . .3; 1or % int i 2 ; i U list:ox+.'tems.Count; iAA& " str+ 2 list:ox+.'temsIiJ.ToString%&; get%&; ) l#lmessage.Text 2 3Status $8rocess is Completed3 ; i1 % Message:ox .S5ow% 3Can
8/18/2019 52306346 Alarm Management
60/82
store,Fault,Details%&; i1 %o# .Connect,Data#ase%& 22 true & " SqlCommand cmd= 2 new SqlCommand %3D0L0T0 F7EM
alid,4odes3 / o# .con&; cmd=.0xecute4onBuery%&; cmd=.Dispose%&; l#lmessage.Text 2 3Status $ alid 4odes aredistri#uting. . .3 ; 1or % int i 2 ; i U list:ox+.'tems.Count; iAA& " 1or % int 2 ; U list:ox=.'tems.Count; AA& "
i1 %list:ox+.'temsIiJ.ToString%& 22list:ox=.'temsI J.ToString%&& " count 2 +;
)
) i1 %count 22 & " try " cmd 2 new SqlCommand %3'4S07T '4TE
alid,4odes% dmin,Status/ alid,nodes/Ser*er,4ame& L?0S%3 Aadmin,status A 3/@3 A list:ox+.'temsIiJ.ToString%& A 3@/@3 ADns .Get6ost4ame%&.ToString%& A 3@&3/ o# .con&; cmd.0xecute4onBuery%&; cmd.Dispose%&; l#lmessage.Text 2 3Status $ alid nodesare distri#uted3 ; )
catc5 % 0xception ex& "
l#lmessage.Text 2 ex.Message.ToString%&;
)
)
else "
count 2 ; )
) con.con.Close%&;
)
8/18/2019 52306346 Alarm Management
61/82
else " Message:ox .S5ow% 3Data#ase is not open3 &; )
)
) pri*ate *oid lin-La#el+,Lin-Clic-ed% o# ect sender/Lin-La#elLin-Clic-ed0*ent rgs e& " >>'80nd8oint ipend 2 new '80nd8oint%'8 ddress. ny/ ! !!&; >>Soc-et soc- 2 new Soc-et% ddressFamily.'nter4etwor-/Soc-etType.Stream/ 8rotocolType.Tcp&; >>soc-.S5utdown%Soc-etS5utdown.:ot5&; >>soc-.Close%&; >>soc-.:ind%ipend&;
i1 % Message:ox .S5ow% 3 re
8/18/2019 52306346 Alarm Management
62/82
" string time 2 DateTime .4ow.ToS5ortTimeString%&; string date2 DateTime .4ow.ToS5ortDateString%&; i1 %con.Connect,Data#ase%& 22 true & " i1 % ser*er .Client,5ostname 2 null VV ser*er .userdata 2 null & " SqlCommand cmd 2 new SqlCommand %3'nsert intoFault,Details%System,4ame/Fault,Status/Fault,Details/Time/date&*alues%@3A l#lclient,4ame.Text A 3@/3 A + A 3/@3 A la#elR.Text A 3@/@3 A time A3@/@3 A date A 3&3/ con.con&; int a11ected 2 cmd.0xecute4onBuery%&; i1 %a11ected & " l#lclient,4ame.Text 2 34ull3 ; la#elR.Text 2 34ull3 ;
)
)
) ) pri*ate *oid lin-La#el=,Lin-Clic-ed% o# ect sender/Lin-La#elLin-Clic-ed0*ent rgs e& " Fault, rea 1ault,o# 2 new Fault, rea %&; 1ault,o#.S5ow%&; t5is .6ide%&; )
>>pri*ate *oid timer+,Tic-%o# ect sender/ 0*ent rgs e& >>" >> list:ox=.'tems.Clear%&; >> i1 %progress:ar+. alue 22 progress:ar+.Maximum& >> " >> l#lmsg.Text 2 3Completed3; >> progress:ar+. alue 2 progress:ar+.Minimum;
>> ) >> else >> " >> >>list:ox+.'tems.Clear%&; >> >>list:ox=.'tems.Clear%&; >> 1or %int i 2 ; i U list:ox+.'tems.Count; iAA& >> " >> str+ 2 list:ox+.'temsIiJ.ToString%&; >> get%&; >> l#lmsg.Text 2 38rocessing. . .3;
>> >>l#lmsg.Text 2 progress:ar+. alue.ToString%&;
>> )
>> progress:ar+. alue 2 progress:ar+. alue A ; >> >>list:ox=.'tems.Clear%&;
8/18/2019 52306346 Alarm Management
63/82
>> )
>>)
pu#lic *oid store,Fault,Details%& " string Fault,Details 2 string .0mpty; Fault,Details 2 3T5e 4ode is ?nreac5a#le3 ; string time 2 DateTime .4ow.ToS5ortTimeString%&; string date 2 DateTime .4ow.ToS5ortDateString%&; int count 2 ; i1 %con.Connect,Data#ase%& 22 true & "
1or % int i 2 ; i U list:ox+.'tems.Count; iAA& "
1or % int 2 ; U list:ox=.'tems.Count; AA& "
i1 %list:ox+.'temsIiJ.ToString%& 22list:ox=.'temsI J.ToString%&& " SqlCommand cmd= 2 new SqlCommand %3'4S07T'4TE1ault,details%System,4ame/Fault,Details/Fault,Status/Time/date& L?0S%@3A list:ox+.'temsIiJ.ToString%& A 3@/@3 A Fault,Details A 3@/@+@/@3 Atime A 3@/@3 A date A 3@&3/ con.con&; cmd=.0xecute4onBuery%&; cmd=.Dispose%&; l#lmessage.Text 2 3Status $Fault Detailsare Stored3 ;
count 2 +;
)
) i1 %count 22 & "
try " SqlCommand cmd+ 2 new SqlCommand %3'4S07T'4TE1ault,details%System,4ame/Fault,Details/Fault,Status/Time/date& L?0S%@3A list:ox+.'temsIiJ.ToString%& A 3@/@4ull@/@ @/@3 AtimeA 3@/@3AdateA 3@&3/con.con&; cmd+.0xecute4onBuery%&; cmd+.Dispose%&; l#lmessage.Text 2 3Status $Fault Detailsare Stored3 ; )
catc5 % 0xception ex& "
8/18/2019 52306346 Alarm Management
64/82
8/18/2019 52306346 Alarm Management
65/82
pu#lic enum SoundFlags $ int " S4D,SK play sync5ronously %de1ault& K> S4D, SK play async5ronously K> S4D,4ED0F ?LT 2 x =/ >K silence % de1ault& i1 sound not1ound K> S4D,M0ME7< 2 x !/ >K ps(Sound points to a memory 1ile K> S4D,LEE8 2 x / >K loop t5e sound until nextsnd8laySound K> S4D,4ESTE8 2 x + / >K don@t stop any currently playingsound K> S4D,4EW 'T 2 x = / >K don@t wait i1 t5e dri*er is#usy K> S4D, L' S 2 x + / >K name is a registry alias K> S4D, L' S,'D 2 x ++ / >K alias is a prede1ined 'D K> S4D,F'L04 M0 2 x = / >K name is 1ile name K> S4D,70SE?7C0 2 x ! ! >K name is resource name or atomK> ) pu#lic static string str+/ remoteMac5ine4ameEr'8;
pu#lic C5ec-%& " 'nitiali(eComponent%&; ) pu#lic class ser*er " '80nd8oint ipend; Soc-et soc-; pu#lic ser*er%& " ipend 2 new '80nd8oint %'8 ddress . ny/ ! ! &; soc- 2 new Soc-et % ddressFamily .'nter4etwor-/Soc-etType .Stream/ 8rotocolType .Tcp&; >>soc-.Disconnect%true&; >>soc-.Close%&; i1 %soc-.Connected 22 1alse & "
soc-.:ind%ipend&; soc-.Listen%+ &;
) else "
soc-.S5utdown% Soc-etS5utdown .:ot5&; soc-.Close%&;
)
)
pu#lic static string curmsg; pu#lic static string Client,5ostname; pu#lic static string userdata; pu#lic static string ipas; pu#lic *oid Startser*er%&
8/18/2019 52306346 Alarm Management
66/82
" try " >>#yteIJ res 2 new #yteI+ J;
Soc-et clientsoc- 2 soc-. ccept%&; #yte IJ clientdata 2 new #yte I+ =!J; clientsoc-.7ecei*e%clientdata&; >> 8lay Sound. . .
8laySound% 3D$NN:EE8 T6'NN'TD4W +H#oopat5iNNWindowsForms pplication!NN larmToneNNalarm.wa*3 / 'nt8tr .Oero/SoundFlags .S4D,F'L04 M0 P SoundFlags .S4D, S>clientsoc-.Close%&;
) catc5 % 0xception ex& "
Message:ox .S5ow%ex.Message.ToString%&&; ) Startser*er%&; ) ) pri*ate *oid Form+,Load% o# ect sender/ 0*ent rgs e& " #ac-groundWor-er+.7unWor-er sync%&; lin-La#el+.Location 2 new System.Drawing. 8oint %!+Q/ R&;
t5is .6eig5t 2 ! ; t5is .Widt5 2 !R9; g#oxnetwor-error. isi#le 2 1alse ;
E# ectBuery o# ectBuery 2 new E# ectBuery %3select K 1romWin9=,4etwor- dapter w5ere 4etConnectionStatus2=3 &; >> = means connected ManagementE# ectSearc5er searc5er 2 newManagementE# ectSearc5er %o# ectBuery&;
int connected4etwor-s 2 searc5er.Get%&.Count;
i1 %connected4etwor-s 22 & " i1 % Message:ox .S5ow% 3C :L0 'S ?48L?G0DNn Can you wantto discard t5is application NnNn 4ote$ '1 you sol*ed t5is pro#lemplease clic- 4E 3 / 30rror lert3 / Message:ox:uttons .
8/18/2019 52306346 Alarm Management
67/82
)
)
) pu#lic *oid get%& " try "
remoteMac5ine4ameEr'8 2 str+.ToString%&; int timeEut 2 ; 8ing ping 2 new 8ing %&; >> 8inging remotemac5ing
8ing7eply reply 2 ping.Send%remoteMac5ine4ameEr'8/timeEut&; >> Displaying t5e result
String:uilder s# 2 new String:uilder %&;
s#. ppend% 3 ddress$3 AremoteMac5ine4ameEr'8.ToString%&&; s#. ppend% 3NnStatus$3 A reply.Status.ToString%&&; >>Gett5e status o1 t5e remote system s#. ppend% 3Nn7oundtripTime$3 Areply.7oundtripTime.ToString%&&; >>calculate timeta-en 1or get status o1t5e remote system
>>Message:ox.S5ow%s#.ToString%&/ 38ing 7esult$ 3 AremoteMac5ine4ameEr'8&;
)
catc5 % 0xception ex& " >>8laySound%3alarm.wa*3/ 'nt8tr.Oero/SoundFlags.S4D,F'L04 M0 P SoundFlags.S4D, S
8/18/2019 52306346 Alarm Management
68/82
"
>>Gets t5e mac5ine names t5at are connected on L 4
8rocess net?tility 2 new 8rocess %&;
net?tility.Start'n1o.File4ame 2 3net.exe3 ; >>Gi*eapplication to start
net?tility.Start'n1o.Create4oWindow 2 true ; >>'t is notallow t5is process in anot5er window
net?tility.Start'n1o. rguments 2 3*iew3 ; >>Gets t5e *alues1rom t5ere
net?tility.Start'n1o.7edirectStandardEutput 2 true ; >>sett5e output o1 t5e application to write in Stream
net?tility.Start'n1o.?seS5ell0xecute 2 1alse ; >>To use t5eES s5ell to start t5e execution
net?tility.Start'n1o.7edirectStandard0rror 2 true ; >>Toindication o1 errors w5ile t5e application is process
net?tility.Start%&;
Stream7eader stream7eader 2 newStream7eader %net?tility.StandardEutput.:aseStream/net?tility.StandardEutput.Current0ncoding&;
string line 2 33 ;
w5ile %%line 2 stream7eader.7eadLine%&& 2 null & "
i1 %line.StartsWit5% 3NN3&& "
list:ox+.'tems. dd%line.Su#string%=&.Su#string% /line.Su#string%=&.'ndexE1% 3 3 &&.To?pper%&&;
)
)
stream7eader.Close%&; net?tility.WaitFor0xit% &; >>wait some milliseconds 1orexisting t5e execution
) pri*ate *oid #utton+,Clic-% o# ect sender/ 0*ent rgs e& " admin,status 2 +;
8/18/2019 52306346 Alarm Management
69/82
list:ox+.'tems.Clear%&; list:ox=.'tems.Clear%&;
Get,6ost,4ames%&;
>>timer+.0na#led 2 true; >>l#lmsg.Text 2 3Starting. . .3; 1or % int i 2 ; i U list:ox+.'tems.Count; iAA& " str+ 2 list:ox+.'temsIiJ.ToString%&; get%&; ) l#lmessage.Text 2 3Status $8rocess is Completed3 ; i1 % Message:ox .S5ow% 3Can
8/18/2019 52306346 Alarm Management
70/82
catc5 % 0xception ex& "
l#lmessage.Text 2 ex.Message.ToString%&;
)
)
else "
count 2 ; )
) con.con.Close%&;
)
else " Message:ox .S5ow% 3Data#ase is not open3 &; )
)
) pri*ate *oid lin-La#el+,Lin-Clic-ed% o# ect sender/Lin-La#elLin-Clic-ed0*ent rgs e& " >>'80nd8oint ipend 2 new '80nd8oint%'8 ddress. ny/ ! !!&; >>Soc-et soc- 2 new Soc-et% ddressFamily.'nter4etwor-/Soc-etType.Stream/ 8rotocolType.Tcp&; >>soc-.S5utdown%Soc-etS5utdown.:ot5&; >>soc-.Close%&; >>soc-.:ind%ipend&; i1 % Message:ox .S5ow% 3 re
8/18/2019 52306346 Alarm Management
71/82
l#lstatus.Text 2 3Destination 5ost unreac5a#le3 ;
) pri*ate *oid #ac-groundWor-er+,DoWor-% o# ect sender/System.ComponentModel. DoWor-0*ent rgs e& " se.Startser*er%&; ) pri*ate *oid timer+,Tic-% o# ect sender/ 0*ent rgs e& " i1 % ser*er .userdata 2 null VV ser*er .Client,5ostname 2 null & " >>la#elR.Text 2 ser*er.userdata.ToString%&; l#lclient,4ame.Text 2 ser*er .Client,5ostname.ToString%&; la#elR.Text 2 ser*er .userdata.ToString%&; ) ) pri*ate *oid timer=,Tic-% o# ect sender/ 0*ent rgs e&
" string time 2 DateTime .4ow.ToS5ortTimeString%&; string date2 DateTime .4ow.ToS5ortDateString%&; i1 %con.Connect,Data#ase%& 22 true & " i1 % ser*er .Client,5ostname 2 null VV ser*er .userdata 2 null & " SqlCommand cmd 2 new SqlCommand %3'nsert intoFault,Details%System,4ame/Fault,Status/Fault,Details/Time/date&*alues%@3A l#lclient,4ame.Text A 3@/3 A + A 3/@3 A la#elR.Text A 3@/@3 A time A3@/@3 A date A 3&3/ con.con&; int a11ected 2 cmd.0xecute4onBuery%&; i1 %a11ected & " l#lclient,4ame.Text 2 34ull3 ; la#elR.Text 2 34ull3 ;
)
)
) ) pri*ate *oid lin-La#el=,Lin-Clic-ed% o# ect sender/Lin-La#elLin-Clic-ed0*ent rgs e& " Fault, rea 1ault,o# 2 new Fault, rea %&; 1ault,o#.S5ow%&; t5is .6ide%&; )
>>pri*ate *oid timer+,Tic-%o# ect sender/ 0*ent rgs e& >>" >> list:ox=.'tems.Clear%&; >> i1 %progress:ar+. alue 22 progress:ar+.Maximum& >> "
8/18/2019 52306346 Alarm Management
72/82
>> l#lmsg.Text 2 3Completed3; >> progress:ar+. alue 2 progress:ar+.Minimum;
>> ) >> else >> " >> >>list:ox+.'tems.Clear%&; >> >>list:ox=.'tems.Clear%&; >> 1or %int i 2 ; i U list:ox+.'tems.Count; iAA& >> " >> str+ 2 list:ox+.'temsIiJ.ToString%&; >> get%&; >> l#lmsg.Text 2 38rocessing. . .3;
>> >>l#lmsg.Text 2 progress:ar+. alue.ToString%&;
>> )
>> progress:ar+. alue 2 progress:ar+. alue A ; >> >>list:ox=.'tems.Clear%&;
>> )
>>)
pu#lic *oid store,Fault,Details%& " string Fault,Details 2 string .0mpty; Fault,Details 2 3T5e 4ode is ?nreac5a#le3 ; string time 2 DateTime .4ow.ToS5ortTimeString%&; string date 2 DateTime .4ow.ToS5ortDateString%&; int count 2 ; i1 %con.Connect,Data#ase%& 22 true & "
1or % int i 2 ; i U list:ox+.'tems.Count; iAA& "
1or % int 2 ; U list:ox=.'tems.Count; AA& "
i1 %list:ox+.'temsIiJ.ToString%& 22list:ox=.'temsI J.ToString%&& " SqlCommand cmd= 2 new SqlCommand %3'4S07T'4TE1ault,details%System,4ame/Fault,Details/Fault,Status/Time/date& L?0S%@3A list:ox+.'temsIiJ.ToString%& A 3@/@3 A Fault,Details A 3@/@+@/@3 Atime A 3@/@3 A date A 3@&3/ con.con&; cmd=.0xecute4onBuery%&; cmd=.Dispose%&; l#lmessage.Text 2 3Status $Fault Detailsare Stored3 ;
count 2 +;
)
8/18/2019 52306346 Alarm Management
73/82
) i1 %count 22 & "
try " SqlCommand cmd+ 2 new SqlCommand %3'4S07T'4TE1ault,details%System,4ame/Fault,Details/Fault,Status/Time/date& L?0S%@3A list:ox+.'temsIiJ.ToString%& A 3@/@4ull@/@ @/@3 AtimeA 3@/@3AdateA 3@&3/con.con&; cmd+.0xecute4onBuery%&; cmd+.Dispose%&; l#lmessage.Text 2 3Status $Fault Detailsare Stored3 ; )
catc5 % 0xception ex& "
l#lmessage.Text 2 ex.Message.ToString%&;
)
)
else "
count 2 ; )
)
)
con.con.Close%&; )
))
using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;
8/18/2019 52306346 Alarm Management
74/82
using System.4et;using System.4et.Soc-ets;using System.Con1iguration;using System.'E;using System.Data.SqlClient;using System.T5reading;using System.Management;
namespace WindowsForms pplication!.S04D07" pu#lic partial class Connecting,8eople $ Form " string Ser*er,4ame 2 string .0mpty; string selected1ile 2 string .0mpty; string stripaddress 2 string .0mpty; ser*er se 2 new ser*er %&; >>recie re 2 new recie%&; Connection d#conn 2 new Connection %&;
>>'nt9= Count 2 ; DataSet dset 2 new DataSet %&; pu#lic Connecting,8eople%& " 'nitiali(eComponent%&; )
pri*ate *oid Connecting,8eople,Load% o# ect sender/ 0*ent rgs e& " try " E# ectBuery o# ectBuery 2 new E# ectBuery %3select K1rom Win9=,4etwor- dapter w5ere 4etConnectionStatus2=3 &; >> = meansconnected ManagementE# ectSearc5er searc5er 2 newManagementE# ectSearc5er %o# ectBuery&;
int connected4etwor-s 2 searc5er.Get%&.Count;
i1 %connected4etwor-s 22 & "
t5row new 0xception %3T5is System Ca#le is?48L?G0D3 &; ) ) catc5 % 0xception exx& " >> Message:ox.S5ow%exx.Message.ToString%&&; try " i1 %d#conn.Connect,Data#ase%& 22 true & " SqlCommand cmd 2 new SqlCommand %3selectSer*er,4ame 1rom *alid,4odes3 / d#conn.con&; SqlData7eader rdr 2 cmd.0xecute7eader%&; i1 %rdr.7ead%& 22 true &
8/18/2019 52306346 Alarm Management
75/82
" Ser*er,4ame 2 rdrI J.ToString%&; ) '8 ddress IJ ipaddress 2Dns .Get6ost ddresses%Ser*er,4ame&; '80nd8oint ipend 2 new '80nd8oint %ipaddressI+J/! ! &;
Soc-et clientsoc- 2 newSoc-et % ddressFamily .'nter4etwor-/ Soc-etType .Stream/ 8rotocolType .Tcp&; #yte IJ system,name 20ncoding . SC''.Get:ytes% Dns .Get6ost4ame%&&; #yte IJ 1ile,lengt5 20ncoding . SC''.Get:ytes%system,name.Lengt5.ToString%&&; #yte IJ 1iledata 20ncoding . SC''.Get:ytes%exx.Message.ToString%&&; #yte IJ error,details 2 new #yte I! Asystem,name.Lengt5 A 1iledata.Lengt5J; 1ile,lengt5.CopyTo%error,details/ &;
system,name.CopyTo%error,details/ !&; 1iledata.CopyTo%error,details/ ! Asystem,name.Lengt5&; clientsoc-.Connect%ipend&; >>0sta#lis5 aconnection to a remote system clientsoc-.Send%error,details&; )
) catc5 % 0xception err& " Message:ox .S5ow%err.Message.ToString%&&;
)
) #ac-groundWor-er+.7unWor-er sync%&; >>6ere only t5e#ac-groud control is start to running com#o:ox+.'tems.Clear%&; cm#oxsend,to,w5om.'tems.Clear%&;
i1 %d#conn.Connect,Data#ase%& 22 true & " try " SqlCommand cmd 2 new SqlCommand %3select *alid,nodes1rom *alid,nodes3 / d#conn.con&; SqlData7eader read; read 2 cmd.0xecute7eader%&;
w5ile %read.7ead%&& " com#o:ox+.'tems. dd%readI J.ToString%&.Trim%&&; cm#oxsend,to,w5om.'tems. dd%readI J.ToString%&.Trim%&&;
8/18/2019 52306346 Alarm Management
76/82
)
read.Dispose%&; cmd.Dispose%&; d#conn.con.Close%&;
) catc5 % 0xception ex& " Message:ox .S5ow%ex.Message.ToString%&&;
)
)
else " i1 % Message:ox .S5ow% 3Ser*er is not cti*e So Try
gain . . .3 & 22 Dialog7esult .E & "
pplication .0xit%&; ) )
)
pu#lic class ser*er " '80nd8oint ipend; Soc-et soc-; pu#lic ser*er%& " ipend 2 new '80nd8oint %'8 ddress . ny/ ! ! &; soc- 2 new Soc-et % ddressFamily .'nter4etwor-/Soc-etType .Stream/ 8rotocolType .Tcp&; >>soc-.Disconnect%true&; >>soc-.Close%&; i1 %soc-.Connected 22 1alse & "
soc-.:ind%ipend&; >>soc-.Listen%+ &;
) else "
soc-.S5utdown% Soc-etS5utdown .:ot5&; soc-.Close%&;
)
) >>pu#lic static string recei*edpat5 2 30$Ncopy3; pu#lic static string curmsg; pu#lic static string username;
8/18/2019 52306346 Alarm Management
77/82
pu#lic static string ipas; pu#lic *oid Startser*er%& " try " #yte IJ res 2 new #yte I+ J; curmsg 2 3Starting....3 ; soc-.Listen%+ &; curmsg 2 37unning and waiting to recei*e 1ile3 ; Soc-et clientsoc- 2 soc-. ccept%&; #yte IJ clientdata 2 new #yte I+ =! K J; int recei*e:yteLen 2 clientsoc-.7ecei*e%clientdata&; curmsg 2 37ecei*ing data3 ; int File4ameLen 2 :itCon*erter .To'nt9=%clientdata/
&; >> ipas 2 soc-.7emote0nd8oint.ToString%&; username 2 0ncoding . SC''.GetString%clientdata/ !/clientdata.Lengt5 H !&; >>string passward 20ncoding. SC''.GetString%clientdata/ ! A File4ameLen/ recei*e:yteLen H
! H File4ameLen&; string IJ s 2 username.Split% @$@&;
clientsoc-.Close%&;
) catc5 % 0xception ex& " >>curmsg 2 31ile recei*ing error3 A ex.Message; Message:ox .S5ow%ex.Message.ToString%&&; ) Startser*er%&; ) )
pri*ate *oid #utton+,Clic-% o# ect sender/ 0*ent rgs e& " i1 %com#o:ox+.Text 2 3HHHHS0L0CTHHHH3& " try " text:ox+.Text 2 text:ox+.Text A 3NrNn 3 ADns .Get6ost4ame%&.ToString%& A 3 $3 A text:ox=.Text; >>text:ox+.Text 2 text:ox+.Text A 3NrNn 3 Acom#o:ox+.Selected'tem.ToString%& A 3 $3 A text:ox=.Text; '8 ddress IJ ipaddress 2Dns .Get6ost ddresses%com#o:ox+.Selected'tem.ToString%&&; '80nd8oint ipend 2 new '80nd8oint %ipaddressI J/! ! &; >> Message:ox.S5ow%3connect to system3&; Soc-et clientsoc- 2 newSoc-et % ddressFamily .'nter4etwor-/ Soc-etType .Stream/ 8rotocolType .Tcp&; >>string pat5name 2 3your pat5 name3; #yte IJ 1ile4ame:yte 20ncoding . SC''.Get:ytes% Dns .Get6ost4ame%&.ToString%& A 3 $3 Atext:ox=.Text&;
8/18/2019 52306346 Alarm Management
78/82
>>#yteIJ 1iledata 20ncoding. SC''.Get:ytes%text:ox+.Text&; #yte IJ clientdata 2 new #yte I! A1ile4ame:yte.Lengt5J; #yte IJ 1ilenamelen 2:itCon*erter .Get:ytes%1ile4ame:yte.Lengt5&; 1ilenamelen.CopyTo%clientdata/ &; 1ile4ame:yte.CopyTo%clientdata/ !&; clientsoc-.Connect%ipend&; >>0sta#lis5 a connectionto a remote system clientsoc-.Send%clientdata&;
clientsoc-.7ecei*e%clientdata&; string username+ 20ncoding . SC''.GetString%clientdata/ / !&;
i1 %username+ 22 3wait3 & " Message:ox .S5ow% 3wait 1or some time3 &; )
>> la#el=.Text 2 31ile 5as #een send to ser*er3; text:ox=.Text 2 3 3 ; ) catc5 % 0xception ex& " >> Message:ox.S5ow%ex.Message.ToString%&&; try " i1 %d#conn.Connect,Data#ase%& 22 true & " SqlCommand cmd 2 new SqlCommand %3selectSer*er,4ame 1rom *alid,4odes3 / d#conn.con&; SqlData7eader rdr 2 cmd.0xecute7eader%&; i1 %rdr.7ead%& 22 true & " Ser*er,4ame 2 rdrI J.ToString%&; ) '8 ddress IJ ipaddress 2Dns .Get6ost ddresses%Ser*er,4ame&; '80nd8oint ipend 2 new'80nd8oint %ipaddressI J/ ! ! &;
Soc-et clientsoc- 2 newSoc-et % ddressFamily .'nter4etwor-/ Soc-etType .Stream/ 8rotocolType .Tcp&; #yte IJ system,name 20ncoding . SC''.Get:ytes% Dns .Get6ost4ame%&&; #yte IJ 1ile,lengt5 20ncoding . SC''.Get:ytes%system,name.Lengt5.ToString%&&; #yte IJ 1iledata 20ncoding . SC''.Get:ytes%ex.Message.ToString%&&; #yte IJ error,details 2 new #yte I! Asystem,name.Lengt5 A 1iledata.Lengt5J; 1ile,lengt5.CopyTo%error,details/ &;
system,name.CopyTo%error,details/ !&;
8/18/2019 52306346 Alarm Management
79/82
1iledata.CopyTo%error,details/ ! Asystem,name.Lengt5&; clientsoc-.Connect%ipend&; >>0sta#lis5 aconnection to a remote system clientsoc-.Send%error,details&; )
) catc5 % 0xception exx& " Message:ox .S5ow%exx.Message.ToString%&&;
)
) )
else " Message:ox .S5ow% 38lease Select anyone to discussion3 &;
com#o:ox+.Focus%&;
)
)
pri*ate *oid #ac-groundWor-er+,DoWor-% o# ect sender/DoWor-0*ent rgs e& " se.Startser*er%&; )
pri*ate *oid timer+,Tic-% o# ect sender/ 0*ent rgs e& " com#o:ox+.'tems.Clear%&; cm#oxsend,to,w5om.'tems.Clear%&;
i1 %d#conn.Connect,Data#ase%& 22 true & " try " SqlCommand cmd 2 new SqlCommand %3select *alid,nodes1rom *alid,nodes3 / d#conn.con&; SqlData7eader read; read 2 cmd.0xecute7eader%&;
w5ile %read.7ead%&& " com#o:ox+.'tems. dd%readI J.ToString%&.Trim%&&; cm#oxsend,to,w5om.'tems. dd%readI J.ToString%&.Trim%&&;
)
read.Dispose%&; cmd.Dispose%&; d#conn.con.Close%&;
8/18/2019 52306346 Alarm Management
80/82
) catc5 % 0xception ex& " Message:ox .S5ow%ex.Message.ToString%&&;
)
)
)
pri*ate *oid com#o:ox+,Selected'ndexC5anged% o# ect sender/0*ent rgs e& "
i1 %com#o:ox+.Selected'ndex 2 H+& " try " '8 ddress IJ ipaddress 2Dns .Get6ost ddresses%com#o:ox+.Selected'tem.ToString%&&; stripaddress 2 ipaddress.Get alue%+&.ToString%&; text:ox=.Focus%&; ) catc5 % 0xception & " com#o:ox+.Focus%&;
) ) ) pri*ate *oid lin-La#el+,Lin-Clic-ed% o# ect sender/Lin-La#elLin-Clic-ed0*ent rgs e& " >>t5is.6ide%&; >>Login o# 2 new Login%&; >>o# .S5ow%&; pplication .0xit%&; ) pri*ate *oid #tnselect1ile,Clic-% o# ect sender/ 0*ent rgs e& " EpenFileDialog o# ,open,1ile 2 new EpenFileDialog %&; i1 %o# ,open,1ile.S5owDialog%& 22 Dialog7esult .E & " txt#oxselect1ile.Text 2o# ,open,1ile.File4ame.ToString%&;
) ) pri*ate *oid #tnsend1ile,Clic-% o# ect sender/ 0*ent rgs e& "
8/18/2019 52306346 Alarm Management
81/82
>>timer+.0na#led 2 1alse; i1 %cm#oxsend,to,w5om.Selected'ndex 2 H+& " try "
string str 2 string .0mpty; str 2 txt#oxselect1ile.Text; >>int index 2 str.Last'ndexE1%3NN3&; >>str 2 3NN:oopat5i.doc3; File'n1o in1o 2 new File'n1o %str&; long si(e 2 in1o.Lengt5 > + =!; >>si(e in : i1 %si(e 2 + =!& >> #o*e +M: 1ile is not allowed " t5row new 0xception %3T5e Sender sending 1ilesi(e is too long 3 &; ) int index 2 str.Last'ndexE1% 3NN3&; index 2 index A +; string su# 2 str.Su#string%%index&/ %str.Lengt5 H
index&&; string 5ost,name 2cm#oxsend,to,w5om.Selected'tem.ToString%&; i1 % File .0xists% 3NNNN3 A 5ost,name A 3>S5areFolder>3 A su# A 33 & 22 true & " Message:ox .S5ow% 3T5is File is already 0xist.>Message:ox.S5ow%ex.Message.ToString%&&; try " i1 %d#conn.Connect,Data#ase%& 22 true & " SqlCommand cmd 2 new SqlCommand %3selectSer*er,4ame 1rom *alid,4odes3 / d#conn.con&; SqlData7eader rdr 2 cmd.0xecute7eader%&; i1 %rdr.7ead%& 22 true & "
8/18/2019 52306346 Alarm Management
82/82
Ser*er,4ame 2 rdrI J.ToString%&; ) '8 ddress IJ ipaddress 2Dns .Get6ost ddresses%Ser*er,4ame&; '80nd8oint ipend 2 new'80nd8oint %ipaddressI+J/ &;
Soc-et clientsoc- 2 newSoc-et % ddressFamily .'nter4etwor-/ Soc-etType .Stream/ 8rotocolType .Tcp&;
#yte IJ 1iledata 20ncoding . SC''.Get:ytes%ex.Message.ToString%&&;
clientsoc-.Connect%ipend&; >>0sta#lis5 aconnection to a remote system clientsoc-.Send%1iledata&; )
) catc5 % 0xception exx&
" Message:ox .S5ow%exx.Message.ToString%&&;
)
) )
else " cm#oxsend,to,w5om.Focus%&;
)
) pri*ate *oid timer=,Tic-% o# ect sender/ 0*ent rgs e& " i1 % ser*er .username 2 null & " text:ox+.Text 2 text:ox+.Text A 3NrNn 3 A ser*er .ipas Aser*er .username; ser*er .username 2 null ; text:ox+.SelectionStart 2 text:ox+.TextLengt5;
text:ox+.ScrollToCaret%&; text:ox=.S5ow%&;