【天学网:双语阅读】访问网页时发生502网关

图片[1]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

502网段错误解决

图片[2]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

A502BadGatewayErroroccurswhenyoutrytovisitawebpage,butonewebservergetsaninvalidresponsefromanotherwebserver.Mostofthetime,theproblemisonthewebsiteitself,andthere’snotmuchyoucando.Butsometimes,thiserrorcanoccurbecauseofaproblemonyourcomputerornetworkingequipment.Herearesomethingsyoucantry.

当您尝试访问网页时,发生502错误网段错误,并且一台Web服务器从另一台Web服务器收到无效响应。大多数情况下,问题出在网站本身上,您无能为力。并且有时,因为计算机或网路设备上的问题,可能会发生此错误。您可以尝试以下方式。

哪些是502错误网段错误?(Whatisa502BadGatewayError?)

A502BadGatewayErrormeansthatthewebserveryou’veconnectedtoisactingasaproxyforrelayinginformationfromanotherserver,butithasgottenabadresponsefromthatotherserver.It’scalleda502errorbecausethat’stheHTTPstatuscodethatthewebserverusestodescribethatkindoferror.Thesebadresponsescouldbeduetoanumberofdifferentcauses.It’spossibletheserverisoverloadedortherearenetworkissuesbetweenthetwoservers,andit’sjustatemporaryproblem.It’salsopossiblethere’sanimproperlyconfiguredfirewallorevenacodingerror,andthattheproblemwon’tgetfixeduntilthoseissuesareaddressed.

502错误的网段错误表示您联接到的Web服务器正在充当从另一台服务器中继信息的代理,但已从该另一台服务器获得错误的响应。之所以称为502错误,是由于Web服务器拿来描述这些错误的HTTP状态代码。这种不良React可能是因为多种诱因造成的。服务器可能过载初始化例程失败,或则两台服务器之间存在网路问题,这只是暂时的问题。也有可能是防火墙配置不正确,甚至是编码错误,但是只有解决了这种问题,问题能够得到解决。

Justlikewith404errors,websitedesignerscancustomizehowa502errorlooks.So,youmightseedifferentlooking502pagesondifferentwebsites.Websitesmightalsouseslightlydifferentnamesforthiserror.Forexample,youmightseethingslike:

如同出现404错误一样,网站设计者可以自定义502错误的外型。为此,您可能会在不同的网站上看见外型不同的502页。网站可能就会对此错误使用稍为不同的名称。诸如,您可能会见到以下内容:

Thevastmajorityofthetime,thisisjustanerrorontheserversideofthingsthatyouwon’tbeabletodoanythingabout.Sometimes,it’satemporaryerror;sometimesitisn’t.Still,therearesomethingsyoucantryonyourendofthings.

在绝大多数情况下,这只是服务器端的错误初始化例程失败,您将无能为力。有时,这是暂时的错误;有时侯不是。虽然这么,您还是可以尝试一些技巧。

刷新页面(RefreshthePage)

Refreshingthepageisalwaysworthashot.Manytimesthe502erroristemporary,andasimplerefreshmightdothetrick.MostbrowsersusetheF5keytorefresh,andalsoprovideaRefreshbuttonsomewhereontheaddressbar.Itdoesn’tfixtheproblemveryoften,butittakesjustasecondtotry.

刷新页面仍然值得一试。好多时侯502错误是暂时的,简单的刷新就可以解决问题。大多数浏览器使用F5键刷新,并在地址栏上的某个位置提供“刷新”按钮。它不会时常解决问题,而且只需一秒钟即可尝试。

图片[3]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

检测该站点是否为其他人关掉(CheckIftheSiteIsDownForOtherPeople)

Wheneveryoufailtoreachasite(forwhateverreason),youcanalsocheckifit’sjustyouthat’shavingaproblemconnecting,orifotherpeoplearehavingthesametrouble.Therearelotsoftoolsoutthereforthis,butourfavoritesareisitdownrightnow.comanddownforeveryoneorjustme.com.Bothworkprettymuchthesame.PlugintheURLyouwanttocheck,andyou’llgetaresultlikethis.

每每您难以访问某个站点时(无论出于何种诱因),您都可以检测是只有您自己遇见了问题,还是其他人遇见了同样的麻烦。有好多工具可用于此目的,但我们的最爱是isitdownrightnow.com和downforeveryoneorjustme.com。二者的工作原理几乎相同。插入您要检测的URL,您将得到如下结果。

图片[4]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

Ifyougetareportsayingthesiteisdownforeveryone,there’snotmuchyoucandobuttryagainlater.Ifthereportshowsthatthesiteisup,thentheproblemmightbeonyourend.It’sveryrarethisisthecasewitha502error,butitispossible,andyoucantrysomeofthethingswedescribeinthenextfewsections.

倘若您收到报告说该站点对每位人都关掉了,这么您无能为力,请稍后再试。假如报告显示该站点已启动,则问题可能出在您头上。出现502错误的情况极少见,而且有可能,您可以尝试在接出来的几节中介绍的一些内容。

尝试其他浏览器(TryAnotherBrowser)

It’spossiblethatanissuewithyourbrowsermightbecausingthe502BadGatewayerror.Oneeasywaytocheckthisoutistouseadifferentbrowserandseeifitworks.YoucanuseGoogleChrome,MozillaFirefox,AppleSafari,orMicrosoftEdge.Ifyoucanseetheerrorinthenewbrowseraswell,thenyouknowit’snotabrowserissue,andyoushouldtryanothersolution.

您的浏览器出现问题可能会造成502BadGateway错误。一种简单的检测方式是使用其他浏览器,瞧瞧它是否有效。您可以使用GoogleChrome,MozillaFirefox,AppleSafari或MicrosoftEdge。倘若您也可以在新浏览器中见到该错误,则说明这不是浏览器问题,应尝试其他解决方案。

去除浏览器的缓存和Cookie(ClearYourBrowser’sCacheandCookies)

Iftryingadifferentbrowserworks,it’spossiblethatyourmainbrowserhascachedoutdatedorcorruptfilesthatmightbecausingthe502error.Removingthesecachedfilesandtryingtoopenthewebsitecouldsolvetheproblem.

假如尝试使用其他浏览器,则可能是您的主浏览器已缓存过时或损毁的文件,这种文件可能会造成502错误。删掉那些缓存的文件并尝试打开网站可以解决此问题。

图片[5]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

It’scertainlyworthtrying,andwe’vegotahandyguideforyouonhowtoclearyourhistoryinanybrowser.

其实值得尝试,但是我们为您提供了有关怎样在任何浏览器中去除历史记录的方便手册。

检测您的插件和扩充(CheckYourPluginsandextensions)

Ifyouuseextensionsonyourbrowser,thenit’spossiblethatoneormoreoftheextensionsarecausingtheproblem.Trydisablingallyourextensionsandthenaccessingthewebsite.Iftheerrordisappearsafterthat,thenitslikelythatapluginiscausingtheissue.Enableyourpluginsonebyonetofindtheculprit.

倘若您在浏览器上使用扩充名,则可能是一个或多个扩充名造成了该问题。尝试禁用所有扩充,之后访问网站。假如随后错误消失,则很可能是由插件造成的。挨个启用您的插件以找到罪魁帮凶。

图片[6]-【天学网:双语阅读】访问网页时发生502网关-唐朝资源网

重新启动设备(RestartYourDevices)

So,you’veusedasitecheckingtoolanddeterminedthatthesiteisjustdownforyou.And,you’vetestedanotherbrowserandarehavingthesameproblem.Soyouknowtheproblemislikelysomethingonyourend,butit’snotyourbrowser.

因而,您早已使用了站点检测工具,并确定该站点对您而言不可用。并且,您早已测试了另一个浏览器,但是碰到了同样的问题。因而,您晓得问题可能出在您的身上,但不是您的浏览器。

Itispossiblethattherearesomestrange,temporaryissueswithyourcomputeroryournetworkingequipment(Wi-Fi,router,modem,etc.).Asimplerestartofyourcomputerandyournetworkingdevicesmighthelpfixtheproblem.

您的计算机或网路设备(Wi-Fi,路由器,调制混频器等)可能会出现一些奇怪的临时问题。重新启动计算机和网路设备可能会帮助解决此问题。

修改您的DNS服务器(ChangeyourDNSServers)

Sometimes,DNSproblemscancause502errors.ChangingyourDNSserversisnotalikelyfix,butitisapossibleone.Andit’snottoohardtodo.Unlessyou’vechangedthemyourself,yourDNSserversareprobablybesetbyyourISP.Youcanchangethemtoathird-partyDNSserverlikeOpenDNSorGoogleDNS,andthatmighttosolvetheproblem.AndthereareotherreasonsyoumightwanttochangeDNSservers,too—likebetterspeedandreliability.

有时,DNS问题可能会造成502错误。修改DNS服务器不是一个可能的解决方式,但它可能是一个解决方式。并且做上去也不难。除非您自己修改了它们,否则DNS服务器可能是由ISP设置的。您可以将它们修改为第三方DNS服务器,比如OpenDNS或GoogleDNS,这可能可以解决问题。另外,您可能还须要修改DNS服务器的其他缘由,比如更快的速率和可靠性。

Followourguideforstepbystepinstructions.

请依照我们的手册进行逐渐说明。

ImageCredit:Micha/Shutterstock

图片来源:Micha/Shutterstock

翻译自:

502网段错误解决

© 版权声明
THE END
喜欢就支持一下吧
点赞84赞赏 分享
评论 抢沙发
头像
欢迎您留下宝贵的见解!
提交
头像

昵称

取消
昵称表情代码图片

    暂无评论内容