Earlier quoted context omitted.
Yes, there is a flag to change the default behavior. I am not sure how many folks actually use this flag.
If you want flags, gcc has -Wall -Wextra -Werror which seems like it would have caught this bug. (Of course, if you weren't using -Wall -Wextra from the beginning you'll have a lot of catching up to do before you can build with -Werror.)
A Google Cloud support engineer solves a tough DNS case
121–130 of 283 posts
Re: A Google Cloud support engineer solves a tough DNS case
#122Earlier quoted context omitted.
I think what he's trying to suggest is that the customer may have been able to isolate the issue faster by walking through the provisioning settings for the machine to identify core changes. The bug report resulted in a core fix, which is a better result than if the customer had fixed it themselves of course.
Also, it was very nice of Google to follow up and submit the patch to LKML. IMHO this goes beyond the scope of their role. They could have taken a more selfish approach and accepted the bug as "normal" behavior, and advised their customer to not configure the buffer to such an enormous size.
Re: A Google Cloud support engineer solves a tough DNS case
#123Note: You shouldn't use int , unsigned int , char , short , long . Use int16_t , uint16_t , uint8_t , etc (or their _fast equivalents) from stdint.h . The former's sizes change based on platform, cpu, and compiler; the latter are fixed-width (or flexible, where _fast may use a larger size if it's faster). I started brushing up on my C recently and have been collecting these little nuggets: https://gist.github.com/pet…
Or even when you are writing low-level code on a known platform (e.g. an LP64 platform).
Re: A Google Cloud support engineer solves a tough DNS case
#124Re: A Google Cloud support engineer solves a tough DNS case
#125The big news here is Google support engineer solves ANY problem. I can never get through to them. That’s the downside to a fully automated support system, no humans.
Re: A Google Cloud support engineer solves a tough DNS case
#126Earlier quoted context omitted.
If you use an automated configuration management system such as Puppet, you don't ever run sysctl manually in a shell. Instead, everything is controlled by the configuration management system. sysctl is a bit problematic in terms of exhaustiveness. That is, how do you ensure that the kernel only has its original values plus whatever you put in sysctl.conf, and nobody actually ran sysctl manually at some point? But it…
OK, so a reason why this file might reflect reality is that some automatic system wrote the file and subsequently successfully ran sysctl -p, but there are dozens of reasons why the file and reality would differ. The only source of truth is sysctl(8) or reading files in /proc/sys, and these are the values that need to propagate to observability systems and decision-making.
Unfortunately, this is the only way until kernel folks start agreeing that random mutability is a good thing. Right now, the kernel has way too many mutation points, and it's not (as far as I know) possible to ask it for a "diff" against the defaults.
Re: A Google Cloud support engineer solves a tough DNS case
#127Re: A Google Cloud support engineer solves a tough DNS case
#128As our systems grow in size and complexity we will inevitably encounter limits (and resulting problems) that previously were not approached. For the future (interstellar space travel etc.) all this will need to be recreated for greater scale
Re: A Google Cloud support engineer solves a tough DNS case
#129And this is why you don't generally use signed numbers in systems code, unless you specifically need negative numbers. And why you gradually develop a paranoia about the sizes of numbers.
Re: A Google Cloud support engineer solves a tough DNS case
#130" When sk_rcvbuf gets close to 2^31, adding the size of the packet can cause an integer overflow. And since it’s an int it becomes a negative number, therefore the condition is true when it should be false (for more, also check out this discussion of signed magnitude representation). " And this is why you don't generally use signed numbers in systems code, unless you specifically need negative numbers. And why you gr…