Avatar of Crossroads305
Crossroads305 asked on

Proxy.pac causing slowness

Hi, I don't know much about proxy.pac files but we seem to have an issue with ours. I'm told that the proxy.pac makes the internet unbearably slow, from what I have been told it can sometimes take 1 second to 10 for a page to load on the proxy.pac file.

I don't browse the internet much when I'm at work so I don't notice it, but I've been tasked to fix it.

From what I understand the proxy.pac is a javascript file with a series of rules, I've read up and created a few of my own which all were also too slow and certain things didn't load right.

I switch back to the old pack and it works fine, even though all the guides I look at tell me my proxy.pac file is fine, I even found a format checker which said all was good.

so I finally just took the original proxy.pac and edited it to two rules, that was still too slow, but everything worked fine. I'm not sure what else to do.

if I go directly out the proxy everything works and we don't have any page lag.
now what I'm surmising is that each individual picture load, iframe, and link gets run through the proxy.pac to see if the rule applies and that's what causes the momentary lag.

I've copied my proxy.pac below, any suggestions on how to possibly be made faster?

'function FindProxyForURL(url, host)
 {
 if (isPlainHostName(host)|| dnsDomainIs(host, ".domain.com"))
 return "DIRECT";
 else if (dnsDomainIs(host, "www.domain.net"))
 return "PROXY 10.0.4.2:8080";
 else
 return "PROXY 10.0.4.2:8080";
 }'
Web BrowsersNetworkingSoftware Firewalls

Avatar of undefined
Last Comment
Crossroads305

8/22/2022 - Mon
SOLUTION
Keith Alabaster

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Steven Vona

Chances are your DNS is slow.

If you check your DNS logs you will probably find that the machine serving the proxy.pac file is making a ton of DNS queries.
Bud Durland

Check that the proxy server's DNS settings are correct.  When using a proxy, it is the proxy server that does DNS lookups, not your local machines.  Trouble there can cause performance trouble.
ASKER
Crossroads305

@keith_alabaster: The proxy.pac is set with in group policy, everything else is greyed out.
Also, what you said is what I originally thought, but then there were several articles I read including one on Microsoft Technet that said otherwise, so I was a little confused.

@Savone, @BudDurland: that was one of the first things we checked, We tried many different DNS' on the Proxy, we tried the ISPs, Internet Backbone DNS, Google's OSPF DNS' and a few other ones. They all expirience the same problem, we don't see many DNS requests in the log of our proxy (we use Astaro), and we're a smaller company, only a handful of people.
the funny thing is that when we put them directly to the proxy and not the .pac it's fast, however the local intranet pages then don't work correctly through the proxy, which is why we have to use the .pac file.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck
Steven Vona

You can bypass the proxy for intranet sites in IE settings.
ASKER CERTIFIED SOLUTION
Keith Alabaster

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
See how we're fighting big data
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
ASKER
Crossroads305

originally they had it on one of our AD servers, I recently set up a 2008r2 box that is hosting iis7 and just the proxy.pac file because I thought maybe it was the box. It's never under load and has 8gb of ram and a 2.5ghz dual core socket 775 Xeon, it has been on this for about a month but still the issue occurs. I'm even contemplating setting up a linux box just for this as well to see if that changes it but I have my doubts.

I'm beginning to think I'm on a snipe hunt, not everyone seems to have the problem and it has never happened to me.

I'm beginning to wonder if perhaps it's our switch, we recently had some ports that were POE just stop working.

thanks for all the help.
Bes4dmin

Hi
We have the same problem, you never mention what browser you are using. We have the slowness problem on IE11 only. And it is only slow when loading the startpage on initial IE11 launching.

What did you come up to?
Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
ASKER
Crossroads305

Sorry, on our end we have the problem with IE 10 and 11. Though recent troubleshooting I added *.internal.domain not to use the proxy through GPO under "User Configuration>Preferences>Control Panel Settings>Internet Settings>Internet Explorer 10/11>Connections>LAN Settings"

clicked use Proxy server for your LAN + Bypass proxy server for local addresses
in Advanced I put in the *.domain.com in "Do not use proxy servers for addresses beginning with:"

this fixed most issues what we were having with internal sites.