MongoDB: mongoimport isodate on Ubuntu 14.04LTS
Question: Platform: Ubuntu 14.04 LTS 64bit Python installed, can't remember its version
right now: I can update this question later

    
    
    ....$>sudo mongod --versiondb 
    version v2.4.9 git 
    git version: nogitversion
    
    ....$>sudo service mongodb status
    start
    

My dbpath variable set on _/etc/mongod.config_ is equals to
_/home/utente/OFS/datasource_. I gave right permissions with chmod. From
mongodb.log file I can see last line like:"_...waiting for connection on port
27017_ " Open a terminal, trying to import the json here below:

> { "_id":ObjectId("572f36bcb69df6b4280cee68"),
> "formatoPreferito":ObjectId("57121b0d1dab7d841d149ed0"), "nome":"fra",
> "cognome":"back", "dataNascita":ISODate("1987-09-17T22:00:00Z"),
> "email":"test@test.com",
> "password":"$2a$10$4LR/kFI.FHPXHug7Jo9z0.mSgFqT4j4ZMeM.x1MdBfp5HGAFCvdOG",
> "ereader":"kindle",
> "token":"$2a$10$WBT5.ylZiRkfSZM./7XUtemllTNN5jaJJy8KsVISvJTvUyUmP49ki",
> "dataRegistrazione":ISODate("2016-05-08T12:53:15.262Z"), "attivo":true }

With the command:

    
    
    mongoimport --db ofs --collection utenti --host localhost --port 27017 --drop --file /home/utente/OFS/load.utenti.json
    

With the output:

> connected to: localhost:27017 Tue May 24 00:04:27.151 dropping: ofs.utenti
> Tue May 24 00:04:27.152 exception:BSON representation of supplied JSON is
> too large: code FailedToParse: FailedToParse: **Bad characters in value:
> offset:149** Tue May 24 00:04:27.152  
>  Tue May 24 00:04:27.152 exception:BSON representation of supplied JSON is
> too large: code FailedToParse: FailedToParse: Bad characters in value:
> offset:149 Tue May 24 00:04:27.152 imported 0 objects Tue May 24
> 00:04:27.152 ERROR: encountered 2 error(s)s utente@utente-X551CAP:~/OFS$Tue
> May 24 00:04:27.152 Tue May 24 00:04:27.152 check 0 0

offset 149, watched on text editor, is the position of the ':' character on
the **dataNascita** field. The --jsonArray parameter does not fix the errors.
Question: is It something wrong with the json file or is It something wrong
with ISODate data type and my version of mongodb? (it is not the mongodb-org
software installed).

### On Microsoft Windows 7

with a later mongodb version it seems all to work just fine: [![on Windows7 64
bit](http://i.stack.imgur.com/VHEbv.jpg)](http://i.stack.imgur.com/VHEbv.jpg)

So now I am going back home, remove mongodb installed, install [later
version](https://www.mongodb.com/download-center#community) and update here.


Answer: It turns the installation was not successfully ended. **I installed the same
mongodb version one time again.** As soon as the installation ended, I was
able to run successfully the mongoimport command with the ISODate objects
inside the json input file.

