简体   繁体   English

ASP MVC或/和网络问题

[英]ASP MVC or/and Networking issues

I am terribly sorry about the vague title, but I am having one of them "What the **** moments". 我为这个模糊的标题感到非常抱歉,但我遇到了其中一个“ ****时刻”。

The premise is the following: We have an ASP MVC website, which is a kind of a CMS system, it is connected to an MSSQL Server 2008 R2 and published on a Windows Server 2003. 前提是:我们有一个ASP MVC网站,它是一种CMS系统,它连接到MSSQL Server 2008 R2并在Windows Server 2003上发布。

*I apologise beforehand for all the stupid things I am going to say about Networks, VPN's and so on, as I am really, really bad on those subjects. *对于我要说的关于网络,VPN等的所有愚蠢的事情,我事先表示歉意,因为我真的很不擅长这些主题。

We have offices in two countries and a intranet through VPN. 我们在两个国家设有办事处,并通过VPN建立了内部网。 So, our stations are locally connected and the ASP Website is not open to the public. 因此,我们的站点是本地连接的,ASP网站不向公众开放。 It is published on a virtual machine, hosted on a machine that is in the foreign office. 它在虚拟机上发布,该虚拟机托管在外国办事处的计算机上。 /as I said, two offices one in Bulgaria, one in the Netherlands/ /正如我所说,有两个办事处,一个在保加利亚,一个在荷兰/

The authentication used in the project is Windows Authentication. 项目中使用的身份验证是Windows身份验证。

So, once upon a time all was great in the kingdom (offices). 因此,曾几何时,王国(办公室)的一切都很棒。 The project worked fine, and anyone could open the site and do his bidding. 该项目运行良好,任何人都可以打开该站点并进行投标。 View, Add, Edit, Delete, all was working. 查看,添加,编辑,删除全部正常。 However, two weeks ago, something happened. 但是,两个星期前,发生了一些事情。 Suddenly, out of nowhere, using the project from our office in Bulgaria (remember the machine hosting the project is in the Netherlands) stopped working PROPERLY. 突然,突然,我们保加利亚办事处使用了该项目(请记住,托管该项目的机器在荷兰)停止了正常工作。 Properly here being the operative word. 适当地,这里是操作词。 Currently, opening the website from Bulgaria works fine. 目前,从保加利亚打开该网站可以正常进行。 Browsing through its content works fine (though many times slower than before). 浏览其内容效果很好(尽管比以前慢了许多倍)。 BUT, some functions now seem not to work. 但是,某些功能现在似乎不起作用。 Now the interesting word is "some"! 现在有趣的词是“一些”! What I mean by that is literally that 'some' of the functions stopped working. 我的意思是从字面上看,有些功能停止工作。 All through the project there are forms for entering and editing data. 在整个项目中,都有用于输入和编辑数据的表格。 It now seems that at most part those actions stopped working. 现在看来,这些动作大部分都停止了工作。 However, there are some that still work. 但是,有些仍然可以使用。

Its time to define a few things. 是时候定义一些东西了。 First what 'not working' means. 首先,“不工作”是什么意思。 Sadly, I cant really provide a more suitable description as what happens is the following: You enter a page, (for our example is a page full with hourlog records). 遗憾的是,由于以下情况,我无法提供更合适的描述:输入页面(对于我们的示例来说,是一个包含小时日志记录的页面)。 You select some things to add, enter how many hours and click 'Add'. 您选择一些要添加的内容,输入多少小时,然后单击“添加”。 What happens next is ... nothing. 接下来会发生什么……什么都没有。 The browser loads for a looot of time before saying - the web page is not available. 浏览器先说了很长时间才加载-网页不可用。 I am guessing the session is then destroyed, because opening another tab of the project, or refreshing the current page also stops working. 我猜会话将被破坏,因为打开项目的另一个选项卡或刷新当前页面也将停止工作。

When you restart the browser, however, the website is working again. 但是,当您重新启动浏览器时,该网站再次正常工作。 AND WHAT IS amazing is that the action you executed was completed - meaning that the hour you logged was saved, and its there in the table now! 而且令人惊奇的是,您执行的操作已完成-这意味着您记录的小时已保存,并且现在已保存在表中!

More than a few actions like that behave the exact same way. 诸如此类的多个动作的行为完全相同。 The browser loads for a long time and then it says 'the web page is not available' and you have to restart it if you want to continue your work. 浏览器加载了很长时间,然后显示“网页不可用”,如果要继续工作,必须重新启动它。 Interestingly enough, there are actions that complete! 有趣的是,有些动作已经完成! There are some separate forms that actually submit and return correctly. 实际上有一些单独的表单可以正确提交并返回。 So it is just in some parts of the application. 因此,它只是在应用程序的某些部分中。

Furthermore, please bear with me its about to get interesting, there is NOTHING, and I mean nothing different from the calls that actually work. 此外,请耐心等待它变得有趣,这里没有,我的意思是与实际工作的电话没什么不同。 I examined the code symbol by symbol and there is nothing to separate the working and not working actions. 我逐个符号地检查了代码,没有任何东西可以区分工作和不工作。 I am not a complete idiot (or so I'd like to believe) and tested extensively for call size (the amount of the transferred data) and timeouts (the time the calls take to complete) and again there were no noticeable differences. 我不是一个完整的白痴(或者我想相信),并且对呼叫大小(传输的数据量)和超时(呼叫完成所需的时间)进行了广泛的测试,再次没有明显的差异。 Some actions involving more data complete, when some actions with little to no call size fail. 当一些调用大小很小或没有调用大小的操作失败时,涉及更多数据的某些操作将完成。 The same with slow and fast actions. 快速动作和慢动作也一样。

Oh, I haven't yet mentioned the kicker - in our offices in the Netherlands the project is working perfectly! 哦,我还没有提到这个问题-在我们位于荷兰的办公室中,该项目运行良好! There is no lag, there are no errors, no waiting and certainly no breaking and having to restart the browser. 没有滞后,没有错误,没有等待,当然也没有中断,也不必重新启动浏览器。

So what have I done to try diagnosing the problem. 因此,我做了什么来尝试诊断问题。 To begin with, I tried tracking the http calls I make with fiddler. 首先,我尝试跟踪我用提琴手进行的http调用。 When we get to the part where the 'mysterious culprit' destroys the peace in our kingdom, the http request gets a "504 receive failure" 当我们到达“神秘元凶”破坏了我们王国的和平的那一部分时,http请求将收到“ 504接收失败”的信息

The call in the Network tab of Chrome is giving me a: (failed) net::ERR_CONNECTION_ABORTED and a Size (content) of 0 B. Chrome的“网络”标签中的呼叫给了我一个:(失败)net :: ERR_CONNECTION_ABORTED,大小(内容)为0B。

I have error handling. 我有错误处理。 I am using Elmah, but am receiving no errors. 我正在使用Elmah,但没有收到任何错误。 No errors get prompted on the browser. 在浏览器上没有错误提示。 Nothing, just the 504 Error from fiddler. 没什么,只是提琴手的504错误。

Things that should also be mentioned are: 还应该提到的事情是:

I have backups of the project going back, months, even years, when everything was well. 我的项目备份可以追溯到几个月甚至几年,那时一切都很好。 I restored more than a bunch of them but to no avail. 我恢复了很多,但无济于事。 They are also behaving the same way. 它们的行为也相同。

There haven't been any updates to the project or anything new installed on the server NEAR the date everything went bad. 在一切出现问题的日期附近,服务器上没有任何项目更新或任何新安装。

I researched the 504 error and saw that it is network related. 我研究了504错误,发现它与网络有关。 I am advancing under the expression that the problem is not in my project for the reasons listed above and more including: 由于以下原因,我以问题不在我的项目中的方式进行推进,其中包括:

  • awful connection to the server 与服务器的可怕连接
  • inability to open files and folders from my local machine (when logged on the server) 无法从本地计算机打开文件和文件夹(登录服务器时)

Unfortunately, the administrators have restarted every piece of equipment connected to the networking, brought down every firewall, reconfigured every DNS and VPN and still the problem persists. 不幸的是,管理员已经重新启动了连接到网络的所有设备,关闭了每个防火墙,重新配置了每个DNS和VPN,问题仍然存在。 So I no longer believe in anything. 所以我不再相信任何东西。

So, that's it. 就是这样了。 I am sorry for the long post, believe it or not I tried keeping it short and simple. 对于冗长的帖子,我感到很抱歉,无论您是否相信,我都试图将其简短而简单。 If anyone has any ideas to what the ... could be causing this issue I would be in his/her debt! 如果有人对...可能导致此问题的原因有任何想法,我将承担自己的债务!

Thank you for the patience and for reading this through. 感谢您的耐心配合和阅读。

Happy End 好结局

Thanks to everyone who tried to help. 感谢所有尝试提供帮助的人。 So, if by some strange chance someone gets in the same position and happens to read this, here is what happened. 因此,如果某人偶然地处于同一位置并碰巧阅读了这篇文章,那么这就是发生的情况。

It is easy to see that our setup is a little archaic (and that is me trying to put it mildly). 很容易看出我们的设置有点陈旧(这是我试图说的很温和)。 So, one of our sheriffs(administrators) read or remembered that the Windows Server 2003 starts having trouble with SSL at some point. 因此,我们的一名警长(管理员)读或记得Windows Server 2003有时在SSL方面出现问题。 Even though the project is not using SSL it turns out that somewhere along the chain event it is used(most likely, or the problem was connected with something else that got way out of date). 即使该项目未使用SSL,事实证明它仍在链式事件的某个地方被使用(很可能是,问题与其他过时的东西有关)。

We ran all updates on the server (yeah, we haven't even updated it for a while) and miraculously it all started working again! 我们在服务器上运行了所有更新(是的,我们有一段时间没有更新了),奇迹般地,它们又重新开始工作了! The project and all the network problems mentioned above. 该项目以及上面提到的所有网络问题。

So, all is well when it ends well, right? 所以,如果一切顺利,一切都会好起来的,对吗?

Thanks again. 再次感谢。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM