In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-04-03 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >
Share
Shulou(Shulou.com)06/02 Report--
This article mainly shows you "how to scan client services in VB.NET programs". The content is simple and clear. I hope it can help you solve your doubts. Let me lead you to study and learn this article "how to scan client services in VB.NET programs".
In the information system of large and medium-sized enterprises, the management of client-side PC is often a link prone to problems. Therefore, many large companies have introduced a variety of distributed management systems, such as anti-virus Norton AntiVirus,BlackICE firewall, Microsoft SMS (System Management Server), and so on. These systems will install corresponding client software on the client side, usually in the form of services, but for various reasons, these services will stop running or the client does not install these client services at all. In this way, there will be omissions in the management system, which may cause problems, such as being unable to defend against the virus and becoming the source of the virus, unable to publish software for the client, unable to manage the customer PC, and so on. Here, we provide a solution that periodically scans the network according to the IP address to report the status of a specific service.
This scheme uses Microsoft.NET technology, as well as ADO.NET and WMI management,XML in .NET Framework. Its core is a VB.NET program and its two configuration files, which are in XML format. The program scans the network according to IP to get the service status of each system. If the IP address does not have a corresponding system, the IP is ignored. For the system where the service is not installed or the service is stopped, we run the NBTSTAT command in another thread to get the machine name, user name, MAC address domain and other information. So that we can find a machine to solve the problem. Secondly, in order to save the scan results, we need a very small database, either MS-Access or MS-SQL server, and we use SQL2000 in this article. * * in order to present the results of the scan so that we can take action, here we use the form of a web page to display the results in the database.
VB.NET program
The program uses two configuration files in XML format, which are read when the program starts. One of the files defines the network segments that need to be scanned, including the excluded address segments. Another file defines the information to connect to the database, as well as the definition of the data table. The contents of these two files are as follows:
< IPLIST > < IP LANID= "192.168.100." > < EXP L = "1" H = "30" / > < IP LANID= "192.168.101." / > < IP LANID= "192.168.102." / > < IP LANID= "192.168.103." / > < IP LANID= "192.168.104." > < EXP L = "1" H = "40" / > < / IP > < / IPLIST >
This file defines that five network segments will be scanned, two of which have addresses that need to be excluded (assigned to devices such as printers). For 192.168.100 segments, we exclude from 1 to 30, and for 192.168.104 segments, we exclude 1 to 40.
< DBINFO > < SERVER > DBServer < / SERVER > < DATABASE > DB < / DATABASE > < UID > REPORT < / UID > < PWD > REPORT < / PWD > < SERVICE TABLE= "SERVICE" > SERVICE < / SERVICE > < / DBINFO >
This file defines the information needed to connect to the database
Server name of TAG Meaning < SERVER > SCANSERVICE database < DATABASE > SCANSERVICE database name < UID > database user name for updating SCANSERVICE database < PWD > password of database user for updating SCANSERVICE database < SERVICE > the inner of the TAG defines the name of the Service we want to scan
Here we assume that we want the scanning service to be named SERVICE. The properties of the TAG define the name of the table in the database, which is used to save the scan results.
The above is all the contents of the article "how to scan client Services in VB.NET programs". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.