Configuring a proxy for Windows Update in Windows 7

Internet Explorer and Windows Update get their proxy settings from two different places. Thus, this is the kind of setting required to teach Windows Update to use the proxy:

netsh winhttp set proxy the.proxy.server:3128

Also, if one wanted to install and configure squid for their own use in such a role, the default configuration for the Debian Squeeze package is very close. One need only update /etc/squid/squid.conf to add the relevant network address range for the internal network, similar to:

acl localnet src 10.0.0.0/8 # RFC1918 possible internal network

…and then allow requests from localnet by uncommenting the following line:

#http_access allow localnet

That was good enough for me.

MySQL: High CPU load, low memory, really, really slow

I observed this after upgrading PhpGedView and my server from Debian Lenny to Debian Squeeze at about the same time. I don’t know what was the root cause. “SHOW FULL PROCESSLIST;” was a very useful SQL command to see what the database was grinding on. Looked like an innocent enough query to me.

I made a few changes to my.cnf inspired by some random web searches (key_buffer=128M in 2 places, and query_cache_size=32M in one place), and then dumped and reloaded all data. This helped a lot. The response time became much more reasonable, and the database has not crashed or otherwise become unresponsive.

# Dump all data
mysqldump -u root -p --all-databases --opt > all_databases.sql

# Re-input all data
mysql -u user -p < all_databases.sql