Sep 7

Ugh, while the title of this post doesn’t sound like that much of an issue chalk this one up to an experience I hope someone else doesn’t have to deal with.

We had an issue with our A/C unit in our data center last night and several of our servers were shut down due to excessive temperatures.  We are slowly brining them up as we are managing the cooling and they are all fairly coming up as normal. Some of the older servers reported errors with batteries or failed drives but these are fairly routine.

However, we had one of our brand new servers start up with seemingly no issues but IIS 7 was not responding to web requests.

This server serves up only two web applications over SSL and has worked fine for the last month that it has been in service.

Looking at the IIS logs, event viewer and any other sort of diagnostic tool we could think of reported no errors at all…and no connection attempts either.  Connecting from the local host offered no error messages.  Connecting through Fiddler2 only showed the cryptic message, “the server has actively closed the connection”.

Finally after restarting the entire server, the IIS service, the web site and the app pools we were grasping at straws.  Bindings were correct, permissions were correct, doing a “netstat –an” revealed the server was indeed listening on port 443.

In the end, what solved it is in the binding settings the Certificate dropdown showed None.  I selected the self-signed server certificate and the whole thing suddenly came alive.  I attempted to set the SSL certificate back to None, which wasn’t an option anymore.

Of course that makes sense.  How can you serve up SSL traffic when there is no certificate to authenticate the request with?  However, why a server restart caused the certificate to no longer be selected is beyond me. 

And why did IIS never throw an event or some type of log error that said, “Hey, you’re trying to serve SSL but no certificate is selected!”???

Anyway, hopefully this will show up on a Google search for someone else.  Cheers. Smile

Aug 11

Recently I’ve started using an iPad 2 in my work environment and I’ve been doing a few presentations about it.  So I was on the hunt for a decent presentation software.  I just picked up KeyNote on the iPad and I have to say I love it.  So much that I had to blog about it, and that’s saying a lot. Smile

KeyNote is a touch app done right.  There is a discussion going on that touch devices should have a touch O/S and a point and click device should have a point and click UI, and very rarely should they actually be merged.  That’s one reason why Windows on an iPad has never really worked and probably never will unless Windows 8 changes the game.

KeyNote is an example of a great app that is designed with the iPad as the only device it is intended for.  The entire interface is based on the touch/swipe model of the iPad, of course.  The UI is very intuitive and very easy to use .  All the interactions make perfect sense and are very easy to use, including adding images, sizing, rotating, adding animation effects, etc.  I’m amazed at the power of the editor while still being a simple touch device.

It’s nice being able to create presentations on the fly with it.  Had I not had Internet access when I was at the Ontario airport I would have been severely hampered when trying to create a recent iPad presentation on the fly.  Had I had KeyNote it would have been a snap other than the graphics I downloaded from Google Images.

I’ll be using KeyNote for the majority of my presentations from now on.  I’ll probably spring for the $0.99 KeyNote presenter remote app that allows me to control the presentation from my iPhone along with viewing what slide I’m on and the presentation notes.

It is just such a pleasure to use an app that blows away all expectations of the iPad and just makes perfect sense.  KeyNote hits the ball out of the park. I know it sounds like I’m an Apple fan boy but believe me, this app deserves it.

Jul 14

PowerShell is a lot of fun but I don’t always get to play with it.  Anytime I have to do large tasks that move a lot of simple data or AD type tasks then I’ll sometimes pull it out.

Recently we installed Windows 7 across our district.  During that process we renamed all the computers because our old naming convention wasn’t always followed and it created a lot of confusion and inconsistency.

All our library staff computers have a special application that allows them to download barcodes that are read using a handheld barcode scanner for inventories.  This previously was pushed out by a group policy.  Since the computers were erased during the Win7 install and the computer names had changed we had about 25 computers that needed to be added to the group again.

Sounds like a perfect chore for PowerShell.

First of all, I forgot the name of the group that they needed to be added to, but I knew it had “dolphin” in the name, since that is the name of the software.  Active Directory Users and Computers (ADUC) won’t let you search on a portion of the name, just the beginning or the end.  Not much help there.

PowerShell makes this trivial:

Get-ADGroup -filter {name -like "*dolph*"}

This returned the following:

DistinguishedName : CN=g-InstallLibraryDolphin,OU=Computer,OU=Software Install,DC=valverde,DC=edu
GroupCategory     : Security
GroupScope        : Global
Name              : g-InstallLibraryDolphin
ObjectClass       : group
ObjectGUID        : 0909537b-ddcc-41c1-bd37-667fdb943a95
SamAccountName    : g-InstallLibraryDolphin
SID               : S-1-5-21-1659004503-746137067-682003330-69446

That’s the one!

Our naming convention for or library computers is wXX-Library, where XX is the two character code for the school the computer is at.  However, simply filtering on this wouldn’t help, because we name all our library student computers as follows: wXX-LibrarySYY, where YY is simply a number stating at 01 and goes up for however many student computers are in the library.

So, here is the PowerShell command that stores all our library staff computers into a $libcomps variable, excluding the student machines:

$libcomps = Get-ADComputer -filter {name -like "*library*" -and name -notlike "*libraryS*"}

Since you cannot pipe computer objects straight into the Add-ADGroupMember commandlet (why, I have no idea but it doesn’t make sense to me) you have to iterate over the $libcomps collection and add them one by one:

foreach ($c in $libcomps) {Add-ADGroupMember g-InstallLibraryDolphin -Members $c}

The command ran for about .25 seconds and did all the work for me.  I think researching the right commands to use took about 2 minutes, which is still faster than had I had to move them all over one by one. 

Heck, this post took longer than the entire task all together. Smile

Jul 7

This was a pretty amazing article about how to extend your jQuery code even further using Amplify.js.  Elijah has a great writing style with very organized and clear examples. 

He first starts out with what I think is a pretty nice and clean example app.  Then he proceeds to discuss various improvements he makes using Amplify.js and refactoring to various patterns that really start to bring out the flexibility of the app.

Definitely take a look!

http://msdn.microsoft.com/en-us/scriptjunkie/hh147623.aspx

Jul 6

This is just amazing stuff.  When Microsoft Surface first came out you knew this was opening the door to the future.  All the flashy futuristic movies where video screens are interactive and everywhere, tables, walls, etc are now coming to reality.

With Surface 2 they have really taken a huge leap forward.  Now they are using LCD screens with what they call PixelSense technology.  Along with R, G and B pixels there is now a fourth pixel that can detect in the infrared range.  The LCD screen actually can detect the objects on the table.

What this does is change the older hardware with complex projectors, cameras and sensors into a sleek tabletop design.

Just to give you an idea here is what the original Surface typically looked like:

The large enclosed portion below the glass is actually hiding the set of projectors and cameras along with the computer hardware.

Now, with most of the complex sensing technology actually built into the LCD they can now produce tables that look like this:

I’ve seen Microsoft Surface products built into the wall at fancy hotels or casinos in Las Vegas.  Now we’ll start seeing a lot more of these pop up everywhere.

It’s an amazing time to be alive! Smile

May 9

Destiny is the district-wide library system we use from Follett.

One common request I get is to update a due date for a large number of books.  Usually this is because a librarian has checked out textbooks but then the end of the school year changes by a day, or the original checkout date was incorrect.

If the due date is in the future, and you are on Destiny 9.9 or later, Destiny has a feature for this.  Simply click on the Circulation tab at the top, click the Renew tab at the left and select the By Date tab on the upper right (could there be any more tabs? Smile).  This allows you to find books due in the future by date and renew them in bulk.

If your due dates are already past, or if you need to filter your books using more detailed criteria Destiny has no built-in way to fix this.  You have to manually go to each checkout and change the due date.  When you’re dealing with hundreds or thousands of books this can be prohibitive.

Destiny does, however, have what they call an Offline Circulation feature.  This is primarily used in case the Destiny server is unavailable but you still have to check in/out books to students.  You use a barcode scanner to scan in a checkout code, then scan the student’s ID and then finally the book they are checking out.  This creates a simple text file that you then upload into Destiny.  The really nice thing is that during the upload Destiny lets you select a date of the transaction.  So, if a mistake happened several weeks ago, you can set the date of the transaction to the day after, assuming that no transactions have happened on these books since the mistake.

The really nice perk about this is if you have had several hundred books marked as lost (because they were overdue for a long period of time) then you may have students with all sorts of fees on their records.  Simply checking out the books again to their accounts reverses all the fees and marks the books correctly as checked out.

But how do you create an Offline Circulation file for thousands of books?  Unfortunately Destiny doesn’t have a built-in way to do this either.

This is where SQL comes in. Smile  I’ve been working with the Destiny database directly in SQL for over 4 years for various reasons.  The Follett development staff do a good job of keeping it fairly well organized and understandable.

If you don’t have access to your Destiny database then buy lunch for one of your IT database admins and they’ll help you. Smile  We love free food.

Here is a sample script that will generate a Destiny Offline Circulation file.  It does this for all textbooks at a specific site that were marked lost on 4/24/2011.

-- Create Offline Circulation file to recheck-out all RVHS textbooks that were lost on 4/24/2011

SELECT  '%C125J' + char(13) -- Checkout to patron code
    + patronbarcode + char(13) -- Patron's barcode
    + copybarcode -- Textbook barcode
FROM
    copy c -- copy table
    join bibtextbook t on (c.bibid = t.bibid) -- textbooks only
    join sitepatron p on (c.patronid = p.patronid) -- patron table
where
    c.status = 200 -- only lost books
    and c.siteid = 215 -- only RVHS
    and p.status = 0 -- Active students only
    and datelost >= '2011-04-24'
    and datelost < '2011-04-25'
ORDER BY patronbarcode, copybarcode

The real magic is the ‘%C125J’ = char(13) portion.  This is the code that Destiny uses for checkout to patron.  The char(13) adds a line feed.  If you execute this and display the results as Text, rather than a table, you will get a line for the checkout code, a line for the patron’s barcode and an line for the textbook barcode.  This is formatted exactly like the Offline Circulation feature.

I hope this helps!

Apr 21

Toms Hardware has a lot of great tech news every day.  This one caught my eye from a gaming cloud vendor talking about where gaming was going.  Here’s a hint, he thinks it’s going to the cloud. Smile

I’m really surprised at a lot of the comments about the article. In fact, I was hard pressed to find a single optimistic one.

A good percentage of the arguments seem to be that "games" should be physical media that you can buy in a store and touch. That’s the same argument music providers and purchasers were pushing 10 years ago. Now if you want to actually visit a store to browse and purchase a CD it’s more because you’re a purist or you want to take a walk in "simpler times". If I hear a song I like and actually want to buy it I don’t think twice about going to my favorite online provider and downloading it to my phone. In fact I love the convenience, speed and knowing that that purchase is mine no matter what happens to my phone. There is no physical medium to break or lose.

Other arguments seem to think that bandwidth is too slow/inaccessible/expensive/capped/et and set in stone. Bandwidth will always get faster and more accessible. I know that right now there are arguments at the cost, ISP caps, geographical limitations, but these have always been the same issues in one form or another. ~15 years ago (I’m 34) I was downloading at 2400bps. 10 years ago ISPs were having wars as to which 56k bps technology was to be used. DSL and Cable then started fighting it out and the government was being lobbied as to whether telco companies should be allowed in the entertainment medium (because Internet was seen as serving video and other "TV killers") or whether cable companies should be allowed in the telecommunications medium (because Internet was seen as communication and "telco killers"). Meanwhile computers have been getting faster and mobile devices smaller/more capable. In the end, 10 years from now communication methods will be much faster and potentially very different, but I’m sure there will be similar "debates" going on.

Another set of arguments seem to be geared towards real games are only fit on consoles or high end desktops. I really don’t know why the gaming genre constantly has to be fit into a small space. Already gaming is on a variety of platforms in variety of forms from simple little text games on old cell phones to Crysis II on a $4,000 gaming rig. The gaming platform as a whole is already incredibly broad and it won’t be getting any smaller.

The real argument in this article is where are high-end games going. Again, I don’t think it matters what one guy (who obviously wants to promote his company and that’s what marketing is, don’t be surprised or offended) thinks about where gaming is going.

In my personal opinion (because hopefully much of the above was objective :) ) I have no problem with another company attempting to push gaming into the cloud with an alternative publishing platform. If I don’t like it I don’t have to use it. No big deal.

However, the potential is actually quite amazing and simply mirrors what other industries have done (i.e. music purchases/distribution and now movie subscription/distribution). I’ll just use the Microsoft XNA platform as an example. Potentially (not yet but potentially) the XNA platform can run on the XBOX, PC, Silverlight and a Windows Phone 7. If Microsoft can take this to the ultimate end then why can’t I subscribe or purchase a game online and play it on my XBOX when I’m at home on my 50" LCD and play it on my laptop or enthusiast PC when I want, then play it online within my Silverlight hardware accelerated browser and finally pop in for a few minutes on my dual-core (or whatever in the future) WP7 phone? I purchased or subscribed to the game and have four platforms. I think the argument in the future would be "what do you mean you’re going to sell me a game on a single DVD and not let me play it on any device I want?"

Right now if I buy a song I would expect to be able to play it on any of my devices in any location I’m at and it would infringe on my right as a customer to be told I can’t play it on my phone and my stereo at home and in my car or on my computer at work. We only allow gaming companies to do this because the current technology doesn’t allow me to move Crysis to my phone as easily as a song. Technology will one day make that available and I fully expect to be able to one day buy/subscribe to a game once and play it on any device I choose to because it’s my game/subscription and my devices.

Heck, I expect that one day bandwidth will be fast enough and $500 PCs will be fast enough that I can travel to another country, take photos, go into an Internet cafe (or just use my phone), upload photos to my online account, retouch them and edit video, make them available to family and friends, and even play a WoW (or whatever) for a little bit all without having to carry around a laptop.

That’s where I think we’re going.

Feb 11

Have you ever wished that hitting the F1 key in Visual Studio actually returned good search results in a quick manner? 

Personally I think the F1 key returns decent results, but there certainly are a lot out there who don’t.  I mostly work in .Net so I’m in the camp of users that F1 works well for.

The think I really don’t like though is the 30 seconds or so it takes to launch the help window.  Once you’re there navigation is pretty painful.

For the last several years I’ve all but abandoned F1 and just search Google with “msdn” and my search term.  95% of the time this returns exactly what I want in the first hit.

Wouldn’t it be nice if we could make Visual Studio do this for us?  Well, we can, and have been able to for years!

Check out OriginalGriff’s solution on Code Project.  He clearly outlines the steps and I have to say his solution is quite nice and tidy.

However, I had two very minor criticism, purely for my own tastes.  This solution opens the webpage inside of Visual Studio’s web browser inside the IDE.  This works, but I really like using my own default browser (currently Chrome).  This allows me to open up various hits in several tabs and bookmark interesting solutions.  I can’t do that in the VS browser window.

Second is it grabs the selected text and performs the search on this.  If you don’t select anything it just opens up a search for “msdn”.  The original F1 functionality use to search whatever word your text cursor was on, nothing had to be selected.  I’m lazy and I like this ability.

Last, but not least, as I was writing this blog post and stated above that 95% of the time my search term came up in the first result it hit me. OMG If I think that what I want will be my first hit, why not just return Google’s first result; the equivalent of hitting the older I’m Feeling Lucky button on Google’s home page. If you look at Griff’s solution you will see below it that I proposed an alternate solution that adds these three features.  Now, when I hit F1 or Shift+F1 I, respectively, get the Google search or the first hit directly.

Enjoy!

Feb 9

I’m fairly busy with a load of tasks at work, but often I use a fun technology or enhance my learning when I can’t find a solution on Google and I think these would make good blog posts. The problem is finding the time to actually write them. Writing a blog post (at least for me) is often more than just typing for a few minutes. It involves code samples, occasional screen shots, previewing and making corrections and then finally posting. For a somewhat in-depth post this can take an hour or several. I have a running set of potential posts I would like to write but my list is getting longer and longer without much actually happening.

So, here’s my question. If you blog on a fairly regular basis (every week or a few times a month) and your posts are mostly instructional when do you do it? Do you have a few hours a week (like Friday after lunch) set aside to do this? Do you do it at 2am when the family is sleeping? Does your employer frown on you blogging on work time or do they actually promote it? For me, my employer doesn’t really know that I do it but they do occasionally see a post or two. I just discipline myself not to take too much work time to do it.

Do you have any tips that you have discovered that make the process a little smoother?

Do you have an assistant?   I’m serious on this one. A lot of my time is spent on correcting errors, re-wording sections and fiddling with format. If I was a professional blogger I’d probably do like movie composers do. I’d write the content, throw it together and then throw it over the wall. Let my assistant clean it up and rephrase complicated sections. Then I’d proof it and post it. I’m sure many professional bloggers have a similar set up. Any services that are somewhat reasonable that you use and would recommend? Maybe this is a market that is yet untapped. 

Thanks!

Dec 16

When you are a website developer, hardly ever do you get to mandate what browsers your users will use.  At my last employment we built a lot of Intranet web applications for our users, who all used the same version of IE that was managed automatically on their work computers via Active Directory.  That was nice.

At my current position the websites I create are used by a variety of school districts and the public.  While the majority of users are browsing my sites with IE7 and IE8 there are a few Chrome, FireFox, Safari and, yes, IE6 users.

 

There is a great community of software applications and web services to help you test how your site will react with different browsers.  Most of them are fairly static showing you how a page will render, but with highly dynamic sites you just need to see how it will work on the actual browser.

Fortunately Microsoft makes this really easy by releasing VHDs with various operating systems and browsers loaded, from WinXP and IE6 up to Vista and IE8.  That’s not the whole Microsoft gamut but it is a good portion and easy to use.  Just load up Microsoft Virtual PC and you are set to go.

Take a look at Microsoft’s offerings here.

« Previous Entries Next Entries »