Easy *Native* Windows Self Extracting EXE Builder (SFX)

This is an oldie but goody… the gist is that even latest Windows 10 still ships with working IExpress.exe which is a self extracting exe builder! Who knew.

In my case, very handy for bundling a batch file and it’s dependencies into a single exe for a buddy.

For the record, I started out with 7zip’s SFX facility and eventually got it working but it’s a bit more clunky… besides the steps required to build an auto launch exe, you’ll get a mildly undesirable “Program Compatibility Assistant” “This program might not have installed correctly” warning… the IExpress generated exe doesn’t seem to have this issue.

Launching IExpress.exe without any args will present the wizard which will walk you through building a “SED” config file with several commonly desired “setup.exe” options like user confirmation prompt, etc… importantly, this includes specifying a batch file you wish to be launched after extract.

Handy batch for recreating exe whenever you update your script:

::start sets appropriate working directory
::especially crucial when launched as admin (which normally defaults to c:\windows\system32)
::and allows us to use relative file references in the SED config file so that launching from any path works (including UNC)

start "Title" /d"%~dp0" iexpress /n Project.sed


  • The program to be launched can indeed be a .BAT/.CMD
  • The IExpress SED wizard will hard code paths, just edit afterwards and remove to be relative. It works.
  • This would of course work for PowerShell or any other script that can be launched via its runner, either bundled in the EXE or native, e.g. ScriptCS

List all your Azure RDP’s

Get-AzureVM | #this first one gets the entire list of VMs in subscription
    Get-AzureVM | # this one gets the detailed object for each specific VM
        $port = ($_ | Get-AzureEndpoint | ? {$_.name -like "Remote*"})[0].Port;
        $null = $_.DNSName -match 'http://(.*?)/'
        write-host "$($_.Name) - $($matches[1]):$($port)"

[SOLVED] Acer Aspire One won’t boot Syslinux USB thumbdrive

Looks like my particular issue was the default partition size on my 16GB thumbdrive. Once I formatted the USB with a 2GB partition and installed Syslinux to that, it booted up right away where previously it would hang on the first “Syslinux Copyright Peter Anvin” message. More details:

  • Acer Aspire One model#: 722-C62bb (looks like this is an 11” model)
  • Always handy to have another computer to work from (for web searching, trial and error formats on the USB drive, etc) when trying to fiddle with boot issues on another… my other computer is a Win8 desktop.
  • Syslinux actually came into my picture because I was looking to create Comodo’s Rescue Disk. Comodo (v6.2) has a convenient point and click process to push their linux based rescue disk to a USB.
  • I used diskpart (on my Win8 box) to create the smaller partition… here’s the core commands:
    • list vol (to get a feel for your windows drive letters and not format the wrong one 🙂
    • list disk (same for raw physical disks)
    • select disk X (MAKE SURE YOU CHOOSE THE RIGHT ONE!!)
    • clean (THIS WIPES THE DISK!!!)
    • create part primary size=2048 (2GB worked for me in this context)
    • active
    • format fs=fat label=”COMODO” quick (I chose old school FAT filesystem looking for most downlevel compatibility, not sure if it was actually necessary vs FAT32. NTFS is notably the least compatible option for linux booting. Quick means do a quick format.)
  • Then I just let Comodo do it’s thing and that result booted up right away for me – yay 🙂

What’s this? A pretty decent “Time Machine” built into Win8!?

i’ve always considered the Vista/Win7 “previous versions” facility to be pretty similar to Time Machine just lacking Apple’s meticulous care to making it drop dead easy to use.
i hadn’t yet noticed the MS boys had taken yet another swipe at simplifying the UI in Win8… i’m assuming there’s still a usability gap that the Mac boys can laugh at us, but gee, first impression is “not bad Balmer you ol’ dog”

  1. search for “file history” in win8 home screen
  2. fire up the ui
  3. select my backup drive
  4. click the “turn on” button
  5. in normal explorer window right mouse all my favorite folders and add them to the documents “library” – since that’s included in what gets backed up (libraries are those fancy pants folder buckets that came along probably with Vista)
  6. click the “run now” link
  7. click “restore personal files” link and yep sure enough all the stuff is piling up out there

defaults to hourly file versions, just like time machine, but can be readily bumped down to minutes in obvious “advanced settings” UI if you want, just like time machine.
the restore UI is clean simple and has exactly what I’d want/expect out of the box… a standard folder explorer big current time stamped version at the top and previous, next and a big restore button (see attached)
not bad i say, not bad at all… ’bout f’ing time.

CTRL, 1 – Mutes Windows Sound?!?!

Is this a standard???  I can’t find reference to this hot key sequence out there in Google land. You need to hit CTRL, release and then hit 1, not CTRL-1, i.e don’t hold down CTRL. On my (*non* Windows Media Keys Keyboard under Windows 7) system here, it works with both left and right CTRL and main keyboard or numeric keyboard “1”.   Google Keywords: Windows 7, Audio, Mute, Volume, Control, CTRL, 1, One

Considering Home Network Storage Alternatives

My current bottom line is that I’ve got a 6 x SATA ICH9R just sitting there on my main Windows 7 machine’s mobo for free so I slapped on 2 TB x 2 in RAID1, published a few shared folders and leave that machine powered on 24/7. After everything else (optical & OS drives) I had two ports left doing nothing so the previous gen 750GB’s x 2 are in RAID0 receiving scheduled backups for a little more cheap peace of mind. I’m hoping by the time I actually need more space, that there will be something along the lines of a 5-bay Drobo engineered around SATA 3.0 (6 Gb/s) internally and USB 3.0 (5 Gb/s!!) externally to finally give us some serious speed for that $700 price point. My big up front consideration: NAS vs DAS

  • What’s better, a true stand alone NAS box –OR- a large/fast DAS array shared from your primary machine???
  • FOR THE HOME scenario: I always go back to preferring DAS connected to my main beefiest workstation/”home-server”
  • You get to rally the performance wagons around at least one location where you have absolute top end HDD access when you want it…
  • If you go with a NAS, you basically accept that GbE is your top end… true, even DAS RAID0 HDD configs generally level out around 100MB/s average xfer rate which is basically the GbE saturation point (1 Gb/s = 125 MB/s minus some packet overhead puts you right around 100 MB/s)… but sequential burst rates can go upwards of 300MB/s (2.4 Gb/s) … so I believe NAS over GbE could very well prevent your drives from spitting the bits as fast as they’re capable.
  • After chasing NAS box performance specs for a while you start to realize that the end game is basically spec’ing out a mid-range PC… so that’s why I can’t stop swinging back to throwing my money at the primary machine’s horsepower and just leave that powered up all the time to share files.
  • My current working scenario is based on a main machine that’s sits at the center of our home’s media universe as the do-it-all living room media player… projector, good speakers, VLC, iTunes, etc… after that, it’s a matter of streaming (primarily video) wirelessly for individual needs (internet tablet, wifey’s PC, etc)… even if I did have the luxury of hiding that main machine somewhere other than the main living space, I think I’d just roll with a cheapo networked media player (e.g. Western Digital TV) in the living room with network storage requirements still covered by the main box.
  • Invariably one wants to share a few things out on the internet as well as around the home… my config readily lends itself to accomplishing this from simple IIS Directory Browsing up to a full blown photo gallery (PHP/MySQL based zenPhoto, love it!!)… other NAS boxes (Synology, etc.) market themselves on more and more “server” oriented features, but why fuss with learning and navigating around the limitations of various embedded linux flavors when you can have the full power of your primary machine’s OS to load up all kinds of goodies?? e.g. Synology’s built in photo gallery is nice but open source is always going to be ahead of the game
  • Another consideration: you don’t hear much talk about virus checking and NAS… maybe I’m worrying about this too much but full scans are something that one must do from time to time… ok yes, most of what we’re putting out there is going to be non executable media that doesn’t require scanning… but being a developer, I’ve developed a fairly extensive library of software that I like to have on hand… it’s doesn’t add up as fast as movies but it’s substantial… and apparently even JPG’s can get viruses… the thought of scanning all those files over the wire (repeatedly) just doesn’t appeal to me.
  • I like the idea of running a reasonable database in this space… granted the optimal database drive configuration is not the same as your primary storage volume –BUT- you do still benefit from having those byte buckets near each other for backups and such
  • [29 Sep 2010] Another one hit me: We finally have full symbolic/hard-link flexibility under Windows 7 NTFS… we can cross phyiscal drives with a link, etc… this allows full granularity to choose exactly what consumes the more valuable RAID1 space but still symlink anything into the same visible folder hierarchy… e.g. a single “movie” shared folder is physically comprised of “classics” subfolder (hosted on RAID1) in addition to “unwatched” (hosted on RAID0)… Shell Link Extension makes symlinks awesomely convenient to create with Windows Explorer.
  • For the HOME sized problem: There starts to be a pile of compelling reasons in favor of connecting the physical storage to the main CPU horsepower over the highest bandwidth possible

Pertinent specs:

  • MB/s = MegaBytes per second, Mbit/s & Mb/s = MegaBits per sec, GbE = GigaBit Ethernet, Gb/s = GigaBits per sec
  • Notable NAS vendors: Synology, QNapBuffalo, LaCieHP, Acer, AsusNetGear, Cisco, ZyXEL
  • Performance rundown of many popular NAS boxes
    • RAID0 based units hold the crown – and nothing tops out much over 100MB/s read or write
    • Didn’t realize the Qnap’s were kicking so much arse
    • The NetGear seems to be the champ but she’s pricey (see my note about their X-RAID technology below under Holy Grail)
  • HD Video Streaming, minimum required bandwidth: in the ballpark of <10MB/s (per client)
    • Blu-ray spec max data transfer rate = 54 Mbit/s (~7 MB/s)
    • HD DVD spec max data transfer rate = 36 Mbit/s
The Holy Grail (at the raw storage level):
  1. Single Volume – a single logical storage pool
  2. Redundancy – at least single drive failure redundancy (with RAID 5 style efficiency)
  3. Different Size Drives – we all want to take advantage of the biggest/cheapest drive available from one year to the next

These are the only options I’m currently aware of:
  • Drobo
  • Windows Home Server
  • NeatGear has something called X-RAID2 in their ReadyNAS line that looks pretty good as well… 6 bay Pro model (empty) = $1000 street <yikes>
  • zFS – Solaris only…various OpenSolaris based versions out there… people do run it under a Windows VM with some success but seems clunky
  • BeyondRAID is like RAID 5 striping & redundancy yet with the freedom of on-the-fly swapping of any drive size
  • Pre-emptive, automatic self healing
  • Tool-less, Tray-less HDD slots
  • Sexy Health lights
  • OS X TimeMachine compatible
  • Downsides:
    • – a bit pricey (5 bay, eSata “Drobo S” = ~$700 empty!) … i feel like they’re charging about $100-$200 over average hardware for their secret sauce
    • – unfortunately it’s run of the mill speedy (60-90 MB/s over eSATA)… too bad we can’t justify the cost with some extra performance
    • – unavoidably it’s running a proprietary format in order to work its magic … the million dollar questions is: What is Drobo’s track record now that they’ve been out there a while??  Definitely need to dig up some solid reliability satistics…  If it ever does totally puke on you, you’d have to wait for a replacement unit to drop in your drives and see what’s still there… and after that, only Data Robotics Inc can possibly save you and it’ll cost you.
    • but is this really any different than RAID5?  RAID is pretty much the same vendor specific lock-in isn’t it??… if your RAID controller up and dies (for me that’d be my mobo 😐 … you’d have to obtain nearly identical duplicate hardware to salvage your drives… apparently you can migrate across same vendor like ICH9R –> ICH10R which does give slightly more flexibility
Windows Home Server
  • You can install PHP
  • It does run fine in a VM
  • OS X TimeMachine compatible
  • – When you add a drive you must designate it as either Storage or Backup (the Storage pool offers no redundancy)
  • – Obnoxious – there’s something whacky about how it does not balance allocation very well across available drives
  • WHS “v2” aka “Vail” due sometime 2010 (V2 is Windows 2008 based, V1 is Windows 2003 based)
  • Great AnandTech.com dissection
    • v1 was basically a fancy tack-on above NTFS – “Drive Extender was the biggest component of the secret sauce that made WHS unique from any other Microsoft OS. It was Drive Extender that abstracted the individual hard drives from the user so that the OS could present a single storage pool, and it was Drive Extender that enabled RAID-1 like file duplication on WHS v1. Drive Extender was also the most problematic component of WHS v1 however: it had to be partially rewritten for WHS Power Pack 1 after it was discovered that Drive Extender was leading to file corruption under certain situations.
    • v2 Drive Extender is now ‘below’ NTFS… proprietary block based storage… single file can/will be spread across multiple disks (“chunking”)
      • biggest downside is that you can no longer just plop a WHS drive in another server to pull files in an emergency
      • chunking means that you’re in a more RAID0 like risk category for your main storage
      • enables backup of open files… to me, Drive Extender v2 provides similar freedoms to what Volume Shadow Copy provides us elsewhere
    • Great stuff in the many comments:
      • This comment basically sums up my WHS vs Drobo question => [RE: Almost there by davepermen on Wednesday, April 28, 2010, on comment page 2] – “in storage-loss for the security, raid5 is superior. if all your data is in duplication mode on whs, it needs 2x the storage space. raid5 needs "one additional disk".” … so Drobo is more like WHS flexibility + RAID5 reliability… so they really are the only game in town and hence the price.
  • Generally accepted as a solid WHS implementation: HP Storage Works x510 (rebranded MediaSmart EX495)


Enable IIS7 under BitDefender 2009 Firewall Rules

Create the following rule and make sure that it’s positioned numerically “above” (i.e. lower number) than all the service.exe related rules… especially above the main “deny” rule at the last slot… i’m assuming we’re dealing with the System process because IIS7 (Windows Vista/Server 2008) moved the core listener daemon responsibility down to a lower level than W3SVC.exeimage  image image