Shard keys must all be ascending? I have a collection that I've been trying to shard, but I can't get it to shard with the index that I gave it.  

The collection in question uses a hashed index, which I created using: 

db.bar.ensureIndex({"_id": "hashed"}, {"background": 1})


But when I try to shard said collection, using: 

sh.shardCollection("foo.bar", {"_id": "hashed"})


I get an error saying: 

command failed: { "ok" : 0, "errmsg" : "shard keys must all be ascending" }


Does this mean that the data I have in collection bar needs to be ascending or that the version of Mongo that I'm using only supports range shard-keys?
Updating to the latest version of mongodb available for ubuntu fixed the issue.  This time, running db.bar.ensureIndex({"_id": "hashed"}, {"background": 1}), gave me:

Inserted 1 record(s) in 97564ms


and when I ran sh.shardCollection("foo.bar", {"_id": "hashed"}), I got:

{
  "collectionsharded": "foo.bar",
  "ok": 1
}


Here's the bash script that I used to update the servers:  

#!/bin/bash

# for installing the latest and greatest version of MongoDB on Ubuntu Servers
if [[ "$UID" != 0 ]]; then # if not root, then exit non-zero
  printf "$(basename $0): err: %s\n" "must be root"
  exit 1
fi

apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv 7F0CEB10 # import the MonboDB public GPG key
echo 'deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen' | tee /etc/apt/sources.list.d/mongodb.list # create `/etc/apt/sources.list.d/mongodb.list` containing the ubuntu repo for mongodb.  
apt-get update # refresh the apt repos

for each in mongodb-clients mongodb-dev mongodb-server mongodb; do # remove the old version of mongodb
  apt-get remove "$each"
done

apt-get install mongodb-10gen # install mongodb from the newly added repo