Recently in Random Category

I loved my Dell 1750 server. It has plenty of power and a great 3Ware RAID card, two 500 GB RAID-1 drives, 4 GB RAM, and ran Red Hat Linux. I bought it from the Dell Outlet site several years ago when my condo fee included electric. Since then I have moved. I pay my own electric bill, and my 1750 consumes 150 watts at idle. When I publish with Movable Type or Gallery, power consumption exceeds 200 watts. I pay $0.150845894 per kilowatt-hour. (That's summing the separate generation, transmission, distribution, demand-side surcharge, and adding the gross-receipts tax. Pepco doens't make it easy to figure out what you're paying.) With a thirty-day month, that's 108 kwh, which comes to $16.29135658. That's $16/month, just for idling. And that doesn't use the noise of the server in my office or the additional AC required in summer.

That may seem expensive, but it's far cheaper than getting that much server capacity at Rackspace. However, I don't need that much capacity. I can trade processor power for power savings, keep the disk space and RAID card, and switch to an Atom-based server. My current FreePBX Atom server runs at 40 watts with an analog card powering two FXS modules. I bet I can match that on a new server. I'd get the new Supermicro Atom Server, but it has space for only one 3.5 inch hard drive. I need two. Thus I'll be using another miniITX case. In the meantime, everything's running on another old Dell tower box.

How did I move it? First I though reinstalling all the software from scratch would be a good idea. I'd get a nice clean, efficient build. But that took way too long, and I'd have to re-customize my templates and tweaks. I had MySQL backups running for a while, why not start testing the restores? I used rsync:

rsync -avz /var/www/ -e ssh:user@mynewserver /var/www/

(Note: Please study rsync syntax. Those / at the ends make a big difference.) It worked. Next I had to tweak the new httpd.conf file. I couldn't just copy the old one, because I was using the latest Apache version. But I could use almost all of the old file. I just needed to adjust the modules it loaded, because several have changed names.

Then I restored the databases:

mysql -u root -p

enter your password. (You ARE using a PW for MySQL root, aren't you?)
mysql> create database mynewdb

then
mysql> quit;

then
$ mysql -u root -p [mynewdb] < [backupfile.sql]

But that generally does not restore your user privs on the db. Back to mysql:
mysql -u root -p

then
mysql> use mynewdb;
mysql> GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'localhost'
IDENTIFIED BY 'pAssW0rd' WITH GRANT OPTION;
mysql> flush privileges;

Don't forget the above step or you'll need to restart MySQL to get it to work.
mysql> quit;

Then double check that the user and pass from above match your config files.

Finally, test your applications. Gallery2 and MovableType worked fine. Your milage may vary. My office is almost silent now.

Case 1: You Google me and click on my page

Yes, I'm using google as a verb. If you Google me and click on one of my pages, my web server logs the information:
1.2.3.4 - - [01/Oct/2009:10:23:41 -0400] "GET / HTTP/1.1" 200 7186 "http://www.google.com/search?hl=en&source=hp&q=larry+s&aq=f&aqi=g10&oq=&fp=7d15299a959dbb33" "Mozilla/5.0 (Windows; U; Windows NT 5.2; en-US; rv:1.9.1.3) Gecko/20090824 Firefox/3.5.3 (.NET CLR 3.5.30729)"

As you can see, I get your IP address, a date, an offset to Universal Time (-0400), a verb (GET, in this case / means my default site page), a status code (200=OK), and a referrer. From the referrer, I can tell you Googled me with the phrase "larry s". Finally, I also get some information about the browser you used, Firefox, and the operating system, Windows XP with service pack 2. There's a chance you may have used a anonymizing proxy, but I'd still get an entry. (Generally, Anonymizer says "TuringOS," so I know it's them.)

Case 2: You Google me and don't click on my page.

That's more difficult but not impossible, because I have a Google AdWords account. I bought my own name as a keyword. Google AdWords works by selling keywords for search insertion. It's an open market, with the second-highest bidder winning in a dutch auction that is Google's revenue machine. When you buy a keyword, you get two measures back from Google:


  1. how many impressions it got (viewing)

  2. how many clickthroughs it got. (someone clicks on the ad)


A keyword ad's success is measured by the ratio of impressions to clickthroughs. The more clickthroughs per impression, the better. So if you don't click on my ad link, which I have made irresistable by promising dirt on me, I still know that someone Googled me, because the impression counter increments with each search. If you click on a regular page on my server rather than the keyword ad (Google calls this "organic"), we're also back to case one above. If you don't click on any of my links, I don't get any of the details from case one.


And that's how I know that you Googled me. If you're wondering if you've been Googled, but don't have a web site with logs you can comb through, or don't want to set up a Google AdWords account, try Google's external keyword tool. Just don't forget to un-check the synonyms box.

Just because disk space is getting cheap, don't think that storage is cheap. A referral from Slashdot to Backblaze's blog charted the situation out accurately. The cost of a petabyte of storage on raw SATA hard drives is $81,000. On Amazon and EMC, it's $2.8 million. If Backblaze really could create their own enterprise storage devices, then it would be possible to offer backups at $5/month for unlimited storage. Backblaze even offers a 15-day free trial, so I tried it, although I was skeptical.

Catches:
1) You need to use their client.
2) Their client doesn't run on Windows Server or Linux -- just WinXP, Vista, and Macintosh. (Even if you run the installer in XP compatible mode on Windows server, it still doesn't install.)
3) The $5/month is for one computer, not all the computers in my house.
4) rsync doens't work with Windows/samba shares. (You may, however, be able to get rsync to work to a Macintosh. I haven't tested yet.) (Update below: you can install an NFS server onto WindowsXP/Vista to get rsync to work, or you could do it from Windows via an SSH rsync script.)

Solution: I installed it on a Vista workstation, created a share, and copied the few things I really need backed up to it. I also wrote scripts to transfer my PBX backups to my backup and log host and then copy the files from the backup server to the windows share via smbclient. I'll skip the part about configuring password-less logins for SSH via ssh-keygen keys, as well as the kinit for logging into windows via smbclient. (I also never was able to mount.cifs via kinit, just smbclient.)

So what happened when I tried to back up 15 GB on my Vista box to Backblaze? Not much -- the files just transferred. iPod library -- check. Photos -- check. My mrtg indicated that bandwidth increased to about 310 kbps for four days. I was still able to make phone calls via my SIP trunk to vitelity with no problems. (g729 to my SIP provider and alaw to my friends' PBX servers via IPSec VPN.)

Bandwidth used:
`Weekly' Graph (30 Minute Average)
mrtgBackblaze.png

Max Average Current
In 501.9 kb/s (0.5%) 56.4 kb/s (0.1%) 47.9 kb/s (0.0%)
Out 1360.2 kb/s (1.4%) 168.6 kb/s (0.2%) 29.3 kb/s (0.0%)

Security comments: Backblaze says it encrypts files, but doesn't offer details on the algorithm or implementation. (e.g AES-CBC, etc.) Backblaze does offer you the option of using a private key, so that only you (assuming you don't forget the key) can access your files.

My advice: If it needs to stay secure, encrypt the files yourself before they hit the local hard disk. You can even do a loopback mount (Super-awesome tutorial there) to an AES-encrypted file on a samba share, and rsync will work, but the whole file will change, requiring it all to be sent to Backblaze.

Update: You can use rsync to get your Linux/BSD/Unix files over to your windows box, but you'll need to install an NFS Server on your windows box. You could also use Microsoft's Services for Unix, but it's easier just using the Allegro server.

Recently I needed to check traffic on specific interfaces of a Cisco 3845 Router. I didn't have a MIB file uploaded to our SNMP workstation, and descriptions of measures were not in synch with the router. Thus I needed to figure out which interface was which. There were 8 valid instances of interface metrics on the router. I was interested in BitsIn/Sec, BitsOut/Sec, and IntSpeed. From IntSpeed, I got the following numbers:
1. 1,000,000,000
2. 1,000,000,000
3. 4,294,967,295
4. 44,736,000
5. 45,000,000
6. 44,736,000
7. 45,000,000
8. 4,294,967,295

Thus I figured out that Serial 0 is 5 and serial 1 is 7. Gig 0 and Gig 1 are 1 and 2. We have two DS-3 circuits (ATT calls them DNECs) in. SNMP may be wonderful but MIBs are a pain. I thought I would write this down before I erase my whiteboard with tomorrow's problem and solution. You can find Cisco's guide to it's MIB and SNMP here.

The Dump Cheney Rumor

| | Comments (0) | TrackBacks (0)

Anyone reading Drudge today will notice that there is a report that Bush will dump Cheney
following the 2006 elections. Those people taking this report at face
value would do well to remember what Bush's father, George H.W. Bush,
did in 1992 with his own Vice President, Dan Quayle.


Like Cheney, Quayle had a few liabilities with the press corps (Murphy Brown, e.g.), and his
Chief of Staff, William Kristol, was determined to prop his boss up,
like any good CoS. Thus, Kristol leaked a story that Bush would replace
Quayle. The press corps forced Bush to issue a denial, solidifying
Quayle's number two spot on the GOP ticket.



Dumping Cheney after the elections won't make any difference for this
year's results, which is what Republicans worry most about.  Next
year is Bush's last term in office, and installing a new Vice President
isn't that easy when you consider the vetting process and the Harriet
Myers withdrawal.



Historical moments in Dick Cheney's life: His opinion of Adam Clymer.

HDTV Page Updated

| | Comments (0) | TrackBacks (0)

I just checked the logs for my site, and while more people
continue to look at this blog, more are looking for HDTV information in
Washington, DC. I think a lot of people are trying to figure out why
they're not seeing the Olympics in HD on their new HD sets. Thus I have updated the page.

Update, 09-25-2009: A postdoc has proven that dead salmon could apparently detect, and respond to, the the emotional state of human beings, according to his fMRI research. That's better than the fish sticks joke.

After reading Slashdot's latest on
lie-detection
using an MRI (Magnetic
Resonance Imagery
), I read a submission to Nature on "Empathic
neural responses are modulated by the perceived fairness of others
," which
also used MRI to detect emotional states of its subjects. (The title is from
the cover of Nature's 26/01/06 issue.)  Basically,
a team from CalTech,
the Wellcome Department of Imaging,
Neuroscience
, and the Institute
of Cognitive Neuroscience
at University College of London, used the
Prisoner's Dilemma game to induce liking and disliking of opponent players. Emotional
reactions could be located in specific regions of the brain. 

Being able to "see" emotions in the brain sounds pretty cool, but these emotions have been known to be "real" since Homer told the story of Apollo helping Paris kill Achilles. The new technology for lie detection sounds like it could be used for great profit, but how would you feel being asked for a "lifestyle MRI?" The lifestyle polygraph is rather feared because the more conscientious you are, the more likely it is to trip you up. (Remember that pen you "stole" by failing to return it?) However, the polygraph is inaccurate and hasn't caught any spies yet. (They'll say it helped, but it didn't stop Aldrich Ames or Robert Hansen.)

Who will administer the lie-detection MRI? It's not like you can go get a six-week degree in radiology and neurology, as you can for the polygraph. It takes a board-certified radiologist just to find something actually wrong with you in an MRI, not just a subtle change in a specific area during the subject's response. I doubt highly that if any companies start setting this up that they'll even use scientific staff to run it. I doubt that many doctors would even testify to its reliability, but that won't stop it from being used for profit. Fortunately, the courts have refused to admit polygraphs as evidence and will do the same for MRI lie detection.

About this Archive

This page is a archive of recent entries in the Random category.

Programming is the previous category.

Security is the next category.

Find recent content on the main index or look in the archives to find all content.