4,439 reputation
1723
bio website BlackMesh.com
location
age
visits member for 4 years, 4 months
seen 2 days ago

Director of Emerging Technology at BlackMesh Managed Hosting, longtime Linux aficionado, sometime Drupal developer (and d.o sysadmin), and occasional filesystem tinkerer.


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.
May
30
comment www.example.com and example.com records in microsoft dns
What do you get when you query DNS about the base domain name, currently? Is there, for example, a hidden CNAME record bedeviling your attempts to add this one?
May
27
comment Why does ethernet have a minimum frame size specified?
@AndrewWagner, As I already said in my response, mfinni's answer above, which is about collision detection, is correct. My point was that this "quirk" of the specification also allows hardware designers to take a few shortcuts of their own.
Mar
25
comment Nginx using mysql result as variable to be used in headers more module
mywiki.wooledge.org/XyProblem ?
Mar
19
comment nginx can't find cgi two levels deep
wiki.nginx.org/HttpCoreModule#try_files covers this quite nicely.
Mar
19
comment What is the best way to resize the “/” mount point that is not LVM?
You don't say what filesystem you're running, but modern best practices typically don't include splitting the OS across so many partitions. That was much more relevant back before journaling filesystems.
Mar
4
comment Varnish 503 error after exactly 60 seconds… how to change this timeout value?
bereq.first_byte_timeout exists, but I'm not sure it's writable. If it is, you could also modify that inside of vcl_pass as opposed to defining a second backend just to change first_byte_timeout.