Browsed by
Month: June 2012

From Russia with Love – Ian Fleming

From Russia with Love – Ian Fleming

The latest of my Ian Flemming reading is “From Russia With Love”. It was his 5th Bond book and considered one of his best.  I don’t know if I totally agree, but it’s still a very good read.

The plot is full of great early cold-war era intrigue. Russia’s intelligence agency has recently suffered some embarrassing failures and setbacks.  They decide to enlist their lethal SMERSH to come up with a plan to embarrass the west and also eliminate an enemy agent at the same time.  They target Bond for the elimination; and cook up a plot to do so in the most publicly embarrassing way possible by framing him.  SMERSH enlists the irresistible Tatiana Romanova to lure 007 to Istanbul promising to give the west a top-secret Spektor cipher machine.  But when Bond walks willingly into the trap, a game of cross and double-cross ensues.

Overall, the story is not bad and right in line with Flemming’s other novels.  The plot in this book is probably the most complex.  There are many different story lines all working their way towards a resolution and the exact details of the plot are hidden from view until the very end.  Some of those lines are working so completely unseen to the reader that it gives a great bit of excitement as you wonder where and how those spinning wheels will come crashing into view again.

Oh sure, there is plenty of bigotry and nationalism as usual in the Bond series.  Flemming gives great little unfiltered opinions of various Western countries of his day via the comments of the Russian’s during the plotting phase.  He doesn’t seem to think much of the French for sure.  There’s the usual dose of sex and even some lesbianism which would certainly have been as racy as it came back in the day.  There are gypsies that he considers near sub-human, and so forth.  Certainly cringe-worthy for people sensitive to political incorrectness – but I still always find these books amazing insights into exactly what people of 70 years ago used to honestly think.

One notable point in this novel is that Bond walks pretty much right into the Russian trap when there are buckets of warning signs.  The concept of Bond being some invincibly omnipotent agent as we see in the movie versions is not present in most of the actual books.  Yet this book really shows the flaws.  Several times Bond even says to himself that this might be a trap and unsuccessfully tries to sort out the plots that appear to be SCREAMING that it’s a trap (you dolt!).  Yet he goes right along with it anyway and seems to think the power of his masculine intuition over this Russian agent he is making love with is all-powerful.  Oh how wrong he turns out to be.

There are some great villains.  The head of SMERSH is vile and cringe worthy.  The assassin himself is a great character; and painted as dark as one could imagine.  The depths of his murderous and homicidal tenancies are nearly unparalleled in other works I’ve read of this era.  He’s a genuinely nasty and downright psychopathic killer.  Still, I found myself laughing out loud though when it came to the point of the kill.  He actually wakes up his completely vulnerable victim to tell them the WHOLE plot ad-nausium before making what should have been an easy kill.  It introduces the classic faux-pax of having your enemy completely in your power, stopping to spill the whole plot, and then flub it because you gave the victim a window of opportunity.  Truly classic.

Overall, it is a good book.  I think I might still give the nod to Moonraker, but this one has much more intrigue and dynamism to it. I give it a A- for the adventure, with the minus points for Bond’s walking right into a trap WE all saw coming.

Can’t rip in Windows Media Player

Can’t rip in Windows Media Player

Oh – yet another way in which Microsoft has made my, and others’, lives much more easy.

Problem:
You open Windows Media Player, and try to rip a CD, but it won’t rip despite the fact you’ve done this dozens of times before.  You get the message ‘Windows Media Player cannot rip one or more tracks from this CD’.

You open Tools->Options->Rip Music.  You see that the ‘Rip music to this location’ is blank – so you click ‘Change’ to set it.  But nothing happens.  Click, click, click.  No dialog opens to allow you  to set the output directory.  Any time you try to rip the CD, you get the same error saying it can’t rip.  You try running the Troubleshooting app and reset all the user settings to default.  Still no luck.


Solution:

The problem is caused because the drive and/or directory media player had been pointing to no longer exists, and the change directory button doesn’t work IF THE ORIGINAL DIRECTORY OR DRIVE IS GONE.  Too bad you can’t change where it is pointing at.  Too bad you also can’t even see what it THINKS it should be pointing at to recreate it.  Guess you’ll just have to remember the path from memory.  Shucks – that’s great design.

You either have to re-create that directory (from memory) – or do THIS highly intuitive operation to fix it:

1. Start menu -> right click ‘Music’ and get the properties.

2. Either: see what directory has a checkmark by it and re-create that directory/re-attach the drive, or add/pick a listed directory that DOES exist – (i.e c:users”your user”)

3. Right click on a directory that does exist, and select  ‘Set as default save location’

Close and reopen media player.  This will solve the problem.  The fact that clicking on the ‘Change’ button doesn’t work is just fundamentally broke.  That needs fixing.  Also, fix the automated troubleshooter to actually reset the default location back to something sane too. The troubleshooter is broken as well.

Sigh.

Installing your new SSD

Installing your new SSD

Installing an SSD hard drive into my machine has to be the most transformative computing experience I’ve had since the introduction of Intel’s Core line of processors.

But there are important things to know about SSD and upgrading.  Sure, it’ll install just like any other hard drive, but they are not created the same way and need different tweaks on them.  Our operating systems are still geared and tuned for platter systems.  There has been many, many people tweaking and experimenting with a great number of setups.  Now, however, they are all starting to converge and say similar things.  Here’s a great link with most of the common details and techniques outlined:
http://www.sevenforums.com/tutorials/70822-ssd-tweaks-optimizations-windows-7-a.html
However, there are some important things I think are worth calling out:

  1. Your SSD has a finite lifespan based on how many times its *written* too – SSD’s only have the ability to write so many times to it’s memory cells before they degrade and fail.  Reading is free from this behavior.  This was much worse in the first generations of the drives – so buying used SSD’s means you’re buying a drive that has used more of it’s lifetime.  Buy used and older generation drives carefully (and at a big discount).   The most recent drives are not nearly as bad as first generation drives but your goal is still to *reduce* the amount of writing your drive.
    Don’t freak out though – Intel drives have 3 year warranties, use modern wear leveling algorithms, compression to avoid extra writes, have built-in block correction/replacement, and use modern processes so that you are now much more likely you’ll upgrade before a failure.  Still, using the drive as a constant write cache would be a bad idea. Most of the optimization strategies you read about are geared for the right balance of longevity and speed.
  2. Even ‘slower’ big SSD’s are faster than the fastest smaller ones.  While my Intel 180gb drive is in the top third of performance, it absolutely TROUNCES the perf of the fastest 64gb, and almost all the 120gb drives.  The bigger the drive, the faster it natively is.  Not sure why, but the specs show they are.
  3. Buy at minimum a 120gb drive – I recommend at least a 180gb.  You’ll find all kinds of folks that get Windows 7 installed in 30gb or under.  Yes, you can install Windows 7 on a 64gb drive.  But you won’t get much else on there and it requires lots of ‘fiddling’.  After years of doing this as a poor college student, I now hate fiddling.  I installed the OS with the swap file and most of the recommended settings along with all my core little helper apps (Winzip, Skype, PowerDVD, Office, Battlefield 3 (notoriously SLOW on level loading and big), and am just under 100gb before my final adjustments that should net me a bit more space.  I think that would completely fill a 120 as after formatting you only have a bit over 100gb.  I would have gone for a 256gb model, but they weren’t offering the nearly half-off super-discount on that one at the time. 🙂  If you buy anything under a 180gb you will probably have to ‘fiddle’ with it.  If you’re ok with that – knock yourself out.  It’s not worth $60 over 3+ years of ownership for me anymore.
  4. Plug the drive into one of the built-in Intel 6gb/Sata3 ports.  Some people report trouble/lowered perf with the ‘add on’ Marvell/AMD/etc SATA3 controller ports (if your MB has them).
  5. Upgrade to Win7.  Love or hate it, Windows 7 has lots of new tweaks and optimizations for SSD use.  If you use an older OS, you won’t get those optimizations, and at worse, maybe shortening the life of your drive.  What are those optimizations?  Things like using the page file linearly to minimize random writes, support for TRIM to combine writes/reads, etc.  Get the latest service packs + updates too.
  6. Install your OS from scratch on the new drive.  You can use a disk imaging tool to get things across, but it’s FAR better to re-install your OS from scratch.  Windows 7 has tweaks for SSD’s if the drive is detected during install that might not turn on if you just clone a drive.
    In addition, if you’re like me and have an original Win7 install CD, you can freely download a Win7+SP1 image instead which saves you at least 20-30 minutes of downloading and installing SP1 after the install.  You can find links to the unified packages below.  Simply pick the one that MATCHES the version you bought (or the serial number won’t work).  Yes, these are 100% legal because they are the 30-day trial versions that you unlock with your purchased serial number.
    http://www.w7forums.com/official-windows-7-sp1-iso-image-downloads-t12325.html

    http://msft.digitalrivercontent.net/win/X17-24395.iso   <-  Win7 Ultimate x64 (for me!)
  7. Use the SSD for OS and ‘core’ apps you use – put other programs and data on a platter drive.  Even the biggest SSD’s are not big enough to hold the hundreds of megabytes of stuff most of us have.  A good balance of minimizing writes and extracting speed a lot of people have worked out is to install the OS and apps you use daily on the SSD, then install everything else and data to the platter drive. This requires the annoyance of paying attention to what drive letter/path to install to when installing your apps – but you only have to do that once (thankfully).
    The bigger question is data.  People that do video editing/photoshop/etc generate tons of big files that results in lots of writes to the drive.  That can be huge slowdowns in their workflows, and prime candidates for using on the SSD.  But it also means lots of writing to big sections of the drive.  I would almost recommend a second SSD for that work so if it fails, you don’t end up with an unbootable machine.  Most people should be fine with keeping their data on the platters, but do as you need and keep good backups if you do use the primary drive for data too.
  8. Optimizations after OS install– after you install, here are some of the more common things you should do
    1. Install the SSD drive management software – these packages often have system tuners that automatically check that the OS is set up for optimal performance.  Run them.
    2. Update the firmware on your drive – check for firmware updates regularly.  The Intel management software actually does this checking for you.  Many bugs, perf problems, and issues can be solved by simply making sure your drive is updated to the latest firmware.  Be careful though, some updates require the re-formatting of the drive.
    3. Disable drive indexing – results in lots of background disk access/writes that are not really necessary on SSD’s
    4. Disable automatic defragging – drive defragmentation is ON by default and is 100% not needed by SSD’s which have no concern about physical location of data on the drive.  In fact, it does nothing but result in tons of extra writing that shortens the life of the drive.
    5. Page file – This is a swap space for active memory.  Some turn this completely off, or put it on another drive.  The current thought is that you should shrink this down to about 1-2gb if you have 8gb of ram (or more) and leave it on the SSD.
    6. Superfetch/prefetch/bootfetch – these result in extra writes to the drive, and really aren’t needed since SSD’s are so fast.  Consensus is turn them off and see if that’s ok for you.  If you see slowdowns, then turn them selectively back on.
    7. Log files – you can turn off some of the copious amounts of logging windows does (and turn it back on if you have troubles later)
    8. Enable Write caching – I bought a $50 UPS for cheap and then turned on write caching.  This lets the system use main memory to cache up reads/writes before committing to the drive.  Besides reducing writing – I saw a good 10-20% speed up from enabling this on my platter drives.
    9. Change the location of temp files for your OS – you can change the location of temporary file generation to a platter drive to help reduce writes, but it will likely slow down installs or anything else that generates temp files.  I’ve left mine on the SSD for now. We’ll see how that goes.
    10. Change the location of temp files for your browser – you can change the location of the copious temporary files generated by your browser too.  I have a unique technique I outline in my previous posting below.

So, those are some high-level tips.  Go to the link for detailed instructions and discussions for these steps.

I have an SSD in my laptop, and now one in my desktop.  The battery life improvements on my laptop were awesome.  The bootup, shudown, and app start time are nearly instantaneous on both – simply stunning.   It’s like using a brand new kind of machine.
I would recommend a SSD to anyone that wants to really improve their home PC/laptop experience.  It really is the wave of the future that is settling in the market now.  Once they get the capacities up to 1TB, keep up the great improvements in drive longevity, and get the prices down (all things that are happening with each new release) – there will be no reason to own platter drives beyond wanting huge, slow bit buckets.

Moving your browser cache to a ramdrive

Moving your browser cache to a ramdrive

So, memory is dirt cheap right now. Crazy considering the prices just 2 years ago. I started with 8GB in my machine, then upped it to 16GB.  The reality has been, sadly, that I haven’t really seen a speedup or perf improvement from that extra ram as I rarely seem to use over even 8gb of memory.  Think my max has been 12GB so far.  It’s not really wasted as Windows 7 Prefetch is populating it with programs in the background – but that’s not super- interesting now that I have an SSD drive.  However, I do want to save my SSD from lots of browser cache writes.  What if I told you that you could do that, speed up your browsing by about 20% AND keeping you more secure. How?  By moving the browsers cache to a ramdrive.

Benefits:

  • Speed – reports are anywhere from 20%-100% speedups
  • Privacy – When you shut down and the ramdrive goes away – your entire browsing cache and cookies are irrevocably erased unless you persist/restore it from a regular drive.  No tracking cookies or other nasty junk is left around.  No need to ‘safe delete’ files.
  • Security – I’ve also already seen where this method caught a pop-up virus because when I rebooted and the app tried to install itself during the bootup cycle, the payload that was in the cache was gone and I caught the installer’s error message.
  • As long as you’re mostly hibernating/waking and not rebooting, the cache stays active and in memory.
  • Free and automatic once set up with about 5 easy steps
  • Some browsers are building this method into the browser itself
  • If you want to persist the cache between reboots – you can with a simple checkbox select.

Downsides:

  • Unless you persist/restore the ramdrive to a regular drive, you have to rebuild the cache each time you reboot.  First browsing on a page requires the reload of all the data.
  • Could potentially slow down your entire system if you are running short of memory
  •  Requires an initial setup

So, how do you do it?  The detailed instructions are on the linked websites below, but I’ll summarize here in case those instructions go away.  This is for firefox, but works for all other browsers too.

  1. Download DataRam Ramdisk and install it.  Amazing little ramdrive program that works on x32 and x64 Windows systems all the way up and through Windows 7. Great GUI frontend, does everything you expect, super stable, restarts on boot automatically.
  2. Open the Ramdisk configuration utility after install:
    1. Select the Settings tab
      1. Set the size to anything from 500-1500mb
      2. Set the file system type to Fat32
      3. Check the Disk Label checkbox and make sure the drive name is ‘RAMDisk’
    2. Select the Load and Save tab (optional step if you want the cache to persist between boots)
      1. If you want the browser cache stored and reloaded when you shut down the machine, select ‘Save disk image on shutdown’ and ‘Load disk image on Startup’.  Make sure they point to the same image file.
      2. I don’t do either of these as I want my cache to go away.  Loading/Saving the state will also increase both your bootup and shutdown times.
  3. Open Firefox
    1. Type ‘about:config’ (no quotes) in the address bar
    2. Hit the ‘I’ll be careful’ button
    3. Right click – select New -> String
    4. Type ‘browser.cache.disk.parent_directory’ into the box and press OK
    5. Type the path of your BrowserCache directory using the drive letter of the Ramdrive i.e. ‘R:BrowserCache’
    6. Close all open Firefox tabs and windows
    7. Reopen Firefox, open any webpage, and see if there is a new directory called BrowserCache on your ramdrive.
  4. Fix the drive letter on reboot.  Ramdisk has an annoying feature.  On reboot, it’ll assign the Ramdrive whatever random drive letter is available.  Obviously, this breaks the cache directory assignment in Firefox.  You’d need to update Firefox each reboot to point to the right drive.  Totally unacceptable.  DataRam’s Ramdisk doesn’t allow you to specify the drive letter of the ramdisk.  Totally unacceptable.  But – you can get around this by having a script move the drive letter during bootup.
    1. Copy the below code, then use notepad or other text editor to save it in a file called C:RamdiskRename.bat
    2. Press Win + R (or find “Run” on start menu), a “Run” dialog will appear. Enter “gpedit.msc” and select the “gpedit” in Programs list.
    3. In the left pane, click “Local Computer Policy” -> “Windows Settings” -> “Scripts(Startup/Shutdown)”  then on the right side, click “Startup”
    4. In the pop-up dialog, On the “Scripts” tab, click “Add…” and add the “C:RamdiskRename.bat” to the list. Click “OK” to finish.

Thats it!  To test it, reboot your machine, and you should see the ramdisk always at R.  When you open the browser for the first time after a reboot, you should see the cache directory appear in that drive. Using the Chromium benchmarking tool, the original author found that page load times were reduced by around 20%.  Shutting down and restarting the browser is also a lot quicker.

Links:
http://downloadsquad.switched.com/2010/11/10/how-to-move-the-firefox-or-chrome-cache-to-a-ram-disk-and-speed/
http://www.zomeoff.com/fixing-the-drive-letter-for-your-ramdisk-a-simple-solution-to-dataram-ramdisk/

RamdiskRename.bat:
@echo off
:: Settings
SET _ramdisklabel=RAMDISK
SET _ramdiskletter=R:

:: Get ramdisk disk number in diskpart
echo list volume > %systemdrive%ListDrives.tmp
diskpart /s %systemdrive%ListDrives.tmp > %systemdrive%DriveList.tmp
FOR /F "tokens=2-4" %%a IN ('type %systemdrive%DriveList.tmp') DO @IF /I "%%c"=="%_ramdisklabel%" @set _ramdisknum=%%a

:: Create drive change script
echo. > %systemdrive%ChangeDrive.tmp
if DEFINED _ramdisknum (
echo select volume %_ramdisknum% >> %systemdrive%ChangeDrive.tmp
echo assign letter=%_ramdiskletter% >> %systemdrive%ChangeDrive.tmp
)

:: Run diskpart using the new script file
diskpart /s %systemdrive%ChangeDrive.tmp

:: Delete the script files
del /q /f %systemdrive%ListDrives.tmp
del /q /f %systemdrive%ChangeDrive.tmp
del /q /f %systemdrive%DriveList.tmp

exit /b 0