我如何编写一个程序来通过远程连接监视另一个系统的生命体征?

发布于 2024-12-07 00:38:35 字数 327 浏览 0 评论 0原文

我正在寻找用 VB.NET / C++ / C# 编写一个自定义程序,它允许我通过远程桌面连接监视系统的生命体征。

我只是在寻找有关如何在代码中实现此类连接的提示(例如,它只是一个简单的对象还是对 WScript 函数的调用?还是更复杂?)。至于连接后的具体操作,我是根据另一个具有类似功能的程序得出的。

我肯定会在谷歌上查看并自学这一点,但我什至不知道从哪里开始/要搜索什么。对此的一些建议会很棒,谢谢!

编辑:这不必通过 RDP 连接,我肯定正在寻找更好的方法。我提到 RDP 的原因是因为我目前通过 RDP 连接手动执行此操作,但我不想不断打开窗口。

I'm looking to write a custom program in VB.NET / C++ / C# that would allow me to monitor a system's vitals over a Remote Desktop Connection.

I'm only looking for tips on how to implement a connection like this in code (eg. is it just a simple object or call to a WScript function? or is it much more sophisticated?). As to the specifics of operation after making the connection, I have that figured out based on another program which shares some similar features.

I would definitely look on Google and self-teach this, but I don't even know where to begin / what to search for. Some advice into this would be amazing, thanks!

EDIT: This doesn't have to go through an RDP connection, I'm definitely looking for better ways. Reason I mention RDP is because I currently do this manually over an RDP connection, but I don't wanna have to constantly open the window.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

我的黑色迷你裙 2024-12-14 00:38:35

我认为 RDP 协议不是解决此问题的正确解决方案。为此发明了其他机制,例如

WMI 是一个可编写脚本的接口,允许您查询本地或远程计算机的信息。您可以使用您选择的工具 - C#、VBScript 或我个人的偏好 - Powershell。 此处是如何获取远程计算机上的所有进程的示例。

编辑

这不必通过 RDP 连接,我肯定正在寻找更好的方法。我提到 RDP 的原因是因为我目前通过 RDP 连接手动执行此操作,但我不想不断打开窗口。

然后忽略该线以下的所有内容。真的。


RDP 协议非常专门用于共享特定资源。即屏幕、磁盘、剪贴板、打印机、端口和声音。这就是开箱即用的内容。您可能做的最好事情就是偶尔使用 RDP 协议监视文件的内容 - 但它既麻烦又缓慢。

我鼓励您考虑替代解决方案,例如 WMI。

也就是说,它是 可以利用 RDP 对虚拟通道的支持来做到这一点。您可以创建可编写脚本的虚拟通道 来实现这一点(这不是一件容易的事)。您必须编写客户端和服务器。您的服务器端功能将报告您有兴趣监视的信息,并且客户端将接收它。我再次强调,这不是正确的解决方案。

I don't think the RDP protocol is the right solution for this. Other mechanisms were invented for this, such as WMI.

WMI is a scriptable interface that allows you to query the local or remote computer's information. You can use your tool of choice - C#, VBScript, or my personal preference - Powershell. Here is an example of how to get all of the processes on a remote machine.

EDIT:

This doesn't have to go through an RDP connection, I'm definitely looking for better ways. Reason I mention RDP is because I currently do this manually over an RDP connection, but I don't wanna have to constantly open the window.

Then ignore everything below the line. Really.


The RDP protocol is very specialized for sharing specific resources. Namely the screen, disks, clipboard, printer, ports, and sound. That's it for what's out-of-the-box. The best thing you could possibly do is occasionally monitor the contents of a file with the RDP protocol - and it is cumbersome and slow.

I'd encourage you to look at alternative solutions like WMI instead.

That said, it is possible to do this with RDP's support for Virtual Channels. You could create a scriptable virtual channel to accomplish this (which is no easy feat). You would have to write a client and server. Your server side functionality would report the information you are interested in monitoring, and the client side would receive it. Again, I would stress that this is not the correct solution.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文