Reputation
4,738
Top tag
Next privilege 5,000 Rep.
Approve tag wiki edits
Badges
1 9 26
Newest
 Necromancer
Impact
~257k people reached

Feb
26
comment Varnish as a cache proxy on openshift-online : openshift limits number of requests from same IP?
Sure, okay, that could happen if you have a cached copy eligible to be served to your loopback connection, whereas your browser was unable to hit the backend. That would require you to have configured backend health checking in your Varnish VCL, though; by default, Varnish doesn't monitor backend health. If you can get it to happen again, varnishlog output would tell you exact how and why Varnish is routing (or not) the request. You can also check the "Age" header you are receiving, or add a cachebreaker (e.g. ?abc123) to the URL, to make sure you aren't getting a cached response.
Jan
13
comment System not being able to handle soft interrupts but having idle time?
At the risk of being dismissive of your question, I want to clarify: ksoftirqd doesn't indicate that soft IRQs are being missed, it indicates that soft IRQs are happening often. In fact, ksoftirqd running is an indication that soft IRQs are not being missed!
Jan
13
comment Apex ANAME / ALIAS record in Windows Server 2012 R2 DNS Manager
Yes, SRV is lower in the list, but the selection logic is rather complicated; if Outlook doesn't like the answer it gets from an earlier stage, it'll try later ones, and then circle back to the original if it can't find a complete answer from those later stages. Certificate mismatches are an example of this, if I recall correctly; if it finds Autodiscover.xml but it has a cert mismatch, it'll keep going to see if it can find it without a cert mismatch, and if so, it'll present the latter.
Dec
3
comment How might I cancel scheduled downtime on Nagios
Fair point. Deleting a downtime, however, has a far larger effect on reports, no?
Nov
21
comment Mysqld.bin and php-fpm eating up all my CPU
For what it's worth, in APC's default (apc.ttl=0), it actually clears the whole cache.
Oct
28
comment rm on a directory with millions of files
It's causing all that I/O simply by being more efficient, though! The globbing is all front-loaded for your example (that is, the full list of files is generated before the first rm happens), so you have relatively efficient I/O at startup from that, followed by painful, out-of-order rms that probably don't cause much I/O, but involve scandir walking the directory repeatedly (not causing I/O because that's already been loaded into block cache; see also vfs_cache_pressure). If you'd like to slow things down, ionice is an option, but I'd probably use fractional-second sleeps.
Oct
10
comment CentOS server priority of root services and non root services
Can you please expand on "it hangs the entire server and needs a hard reboot"? Does the server stop responding to SSH? The console goes dark and cannot be woken back up? Pings get dropped? Power supply catches on fire?
Oct
10
comment rm on a directory with millions of files
You're being eaten alive by globbing. How about something more like: find /u* -maxdepth 3 -mindepth 3 -type d -path '*/app/*' -name diag -print0 | xargs -0I = find = -mindepth 4 -maxdepth 4 -type d -name 'trace' -print0 | xargs -0I = find = -mindepth 1 -maxdepth 1 -name '*.tr' ? Add -delete to the last one to actually delete things; as written, it just lists what it would delete. Note that this is optimized for circumstances where you have a lot of uninteresting things in nearby directories; if that's not the case, you can simplify the logic a great deal.
Oct
7
comment nginx + varnish, optimize caching urls for ssl and not
Thanks for spotting that. Fixed!
Oct
6
comment nginx + varnish, optimize caching urls for ssl and not
Boernie: Ah, you mean the scheme that is INSIDE of the req.url (.../http/example.com:80/... versus .../https/example.com:443/...). Code updated.
Oct
6
comment Implement HTTPS in with pfSense, Varnish and Tomcat
No; Varnish doesn't speak SSL. It must be plain HTTP when it reaches Varnish (notwithstanding the CONNECT verb, but even that is HTTP, albeit weird HTTP). The most common approach is to use something like Pound or nginx to unwrap the SSL off of the HTTP before it hits Varnish. I've added a relevant link to my answer, above.
Oct
6
comment How to disable AAAA lookups?
Lastly: for what it's worth, I'd solve this by running a DNS cache on localhost (as you reference, above). It'd be a heckuva lot easier to maintain your own, hacked DNS proxy/cache than it would be to maintain a hacked version of a core system library.
Oct
6
comment How to disable AAAA lookups?
Unfortunately, as you can see from the code, there doesn't appear to be a no_inet6 option in res_setoptions(). However, as you can see from (no-)ip6-dotint, it's an easy change to add. To test the theory that it's being set by default by your distro, I'd grab the package source files and compile it once "virgin" (to confirm that the package replicates the behavior) and then add: { STRnLEN ("no-inet6"), 1, ~RES_USE_INET6 }, to the options[] array and see if the problem goes away when you set that option in resolv.conf.
Oct
2
comment nginx + varnish, optimize caching urls for ssl and not
req.url doesn't contain scheme (http vs. https). Thus, you only need to run the code, above, unless I'm missing something in your question.
Sep
24
comment Arp attack on my network
Who has <IP> Tell 0.0.0.0 is a standard approach to avoiding IP address conflicts. The other option is to use 169.254/16 (i.e., RFC 3927), but most equipment I've seen uses the former. Thus, this particular part of the observed behavior is not, in itself, of concern.
Sep
24
comment Arp attack on my network
The information you've provided would suggest that the Barracuda is configured with the same IP address as your firewall. Are you able to conclusively determine that that is not the case? Remember to check all zones/interfaces.
Sep
24
comment Slow Upload Speed - CentOS 6
If you want to debug the hardware? Sure. But a chassis/mobo swap is almost instantaneous (less downtime than you'd get as a result of a reboot or two) and answers the same questions. If it's something outside of your hardware, then debugging using your software—since either the other end is flawed, or the software you're using to debug is flawed—can become devilishly hard very quickly.
Jun
23
comment Varnish as a web server
You probably want to delete the return(deliver); from the bottom of vcl_synth, lest you fail to run this code from builtin.vcl (née default.vcl): varnish-cache.org/trac/browser/bin/varnishd/… .
Jun
9
comment Varnish as a web server
Sorry to be a pain, but you very much don't want return(deliver) at the very bottom of your vcl_error! If it doesn't satisfy any of the conditionals, you want it to fall through to the default behavior of constructing a "Guru Meditation" page (by not returning at all).
May
30
comment Varnish as a web server
This is the correct answer, and also the official way (per Varnish docs) to handle this. However, both your answer and the Varnish docs have an omission: if you don't set obj.response to something sane, then you'll get HTTP/1.1 200 Unknown Error or even HTTP/1.1 200 http://www.example.com/correct-target in your response! Simple fix: obj.response = "OK" for 200, or other appropriate code for the others.