Error in mongoimportjson in Win32

36 views
Skip to first unread message

tigerfoot

unread,
Oct 10, 2009, 7:59:07 PM10/10/09
to mongodb-user
Hello,

I'm trying to import my first trivial database using
mongoimportjson.

My trivial file, parts.json, contains this text:

{"a":"1","b":"John","c":"Smith"}

I've tried with and without quotes on the field names--get same error.

Then I run this command:

mongoimportjson -d mydb -c parts --file parts.json --id

I get one message on the screen saying "connected to: 127.0.0.1" then
get a Windows pop-up dialog that says: mongoimportjson.exe has
encountered a problem and needs to close. We are sorry for the
inconvenience.

No other useful information or logs could be found.

Mongo server seems to be alive and healthy and I'm able to
successfully exercise the trivial get-it-working test in the
documentation to add a single doc to the database w/no errors.

Any idea what this is and how to fix it?
Thanks!

Eliot Horowitz

unread,
Oct 10, 2009, 8:47:47 PM10/10/09
to mongod...@googlegroups.com
we made some changes in the nightly.
would you mind trying the latest windows nightly.
the tool has changed the name to mongoimport but defaults to json so
you can use the same command.
if that doesn't work - we can add some more debugging logic

tigerfoot

unread,
Oct 11, 2009, 2:19:26 PM10/11/09
to mongodb-user
Ok, tried the latest nightly.
Unfortunately same issue.
Some descriptive output or log file would be good if you can enable
something.
Thanks!

On Oct 10, 7:47 pm, Eliot Horowitz <eliothorow...@gmail.com> wrote:
> we made some changes in the nightly.
> would you mind trying the latest windows nightly.
> the tool has changed the name to mongoimport but defaults to json so
> you can use the same command.
> if that doesn't work - we can add some more debugging logic
>

Eliot Horowitz

unread,
Oct 11, 2009, 8:24:07 PM10/11/09
to mongod...@googlegroups.com
I added some debugging to mongoimport
Tomorrow, can you run it with -v, so:
mongoimportjson -d mydb -c parts --file parts.json -v

tigerfoot

unread,
Oct 12, 2009, 10:21:09 AM10/12/09
to mongodb-user
Thanks, Eliot.

This morning I tried with -v and nothing additional was output. The
date stamp on the release directory was mongodb-win32-i386-2009-10-12

I also tried just "mongoimport -v" (no parameters) and got the same
error. The system I'm using is XP but I also tried 32-bit Vista.

Clicking the additional info button on the windows error popup gave me
some kind of dump that I can't select/copy. There was also a temp
file containing this:

<?xml version="1.0" encoding="UTF-16"?>
<DATABASE>
<EXE NAME="mongoimport.exe" FILTER="GRABMI_FILTER_PRIVACY">
<MATCHING_FILE NAME="mongo.exe" SIZE="1394688"
CHECKSUM="0x6D007812" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:00:53"
UPTO_LINK_DATE="10/12/2009 06:00:53" />
<MATCHING_FILE NAME="mongod.exe" SIZE="2312704"
CHECKSUM="0x72A28579" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:02"
UPTO_LINK_DATE="10/12/2009 06:01:02" />
<MATCHING_FILE NAME="mongodump.exe" SIZE="2061312"
CHECKSUM="0x24D7BBE0" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:04"
UPTO_LINK_DATE="10/12/2009 06:01:04" />
<MATCHING_FILE NAME="mongoexport.exe" SIZE="2065920"
CHECKSUM="0x580C30B6" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:05"
UPTO_LINK_DATE="10/12/2009 06:01:05" />
<MATCHING_FILE NAME="mongofiles.exe" SIZE="2069504"
CHECKSUM="0x906C1F92" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:07"
UPTO_LINK_DATE="10/12/2009 06:01:07" />
<MATCHING_FILE NAME="mongoimport.exe" SIZE="2063872"
CHECKSUM="0xACEA0221" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:17"
UPTO_LINK_DATE="10/12/2009 06:01:17" />
<MATCHING_FILE NAME="mongorestore.exe" SIZE="2061824"
CHECKSUM="0x4090C555" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:18"
UPTO_LINK_DATE="10/12/2009 06:01:18" />
<MATCHING_FILE NAME="mongos.exe" SIZE="1579520"
CHECKSUM="0x33F9A911" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:21"
UPTO_LINK_DATE="10/12/2009 06:01:21" />
<MATCHING_FILE NAME="mongosniff.exe" SIZE="437248"
CHECKSUM="0xB5B01202" MODULE_TYPE="WIN32" PE_CHECKSUM="0x0"
LINKER_VERSION="0x0" LINK_DATE="10/12/2009 06:01:22"
UPTO_LINK_DATE="10/12/2009 06:01:22" />
</EXE>
<EXE NAME="kernel32.dll" FILTER="GRABMI_FILTER_THISFILEONLY">
<MATCHING_FILE NAME="kernel32.dll" SIZE="984576"
CHECKSUM="0xF0B331F6" BIN_FILE_VERSION="5.1.2600.3119"
BIN_PRODUCT_VERSION="5.1.2600.3119" PRODUCT_VERSION="5.1.2600.3119"
FILE_DESCRIPTION="Windows NT BASE API Client DLL"
COMPANY_NAME="Microsoft Corporation" PRODUCT_NAME="Microsoft® Windows®
Operating System" FILE_VERSION="5.1.2600.3119 (xpsp_sp2_gdr.
070416-1301)" ORIGINAL_FILENAME="kernel32" INTERNAL_NAME="kernel32"
LEGAL_COPYRIGHT="© Microsoft Corporation. All rights reserved."
VERFILEDATEHI="0x0" VERFILEDATELO="0x0" VERFILEOS="0x40004"
VERFILETYPE="0x2" MODULE_TYPE="WIN32" PE_CHECKSUM="0xF9293"
LINKER_VERSION="0x50001" UPTO_BIN_FILE_VERSION="5.1.2600.3119"
UPTO_BIN_PRODUCT_VERSION="5.1.2600.3119" LINK_DATE="04/16/2007
15:52:53" UPTO_LINK_DATE="04/16/2007 15:52:53" VER_LANGUAGE="English
(United States) [0x409]" />
</EXE>
</DATABASE>

Greg

On Oct 11, 7:24 pm, Eliot Horowitz <eliothorow...@gmail.com> wrote:
> I added some debugging to mongoimport
> Tomorrow, can you run it with -v, so:
> mongoimportjson -d mydb -c parts --file parts.json -v
>

Scott

unread,
Oct 31, 2009, 10:36:48 AM10/31/09
to mongodb-user
Eliot,
I'm seeing the same thing with mongoimport on Windows Vista (32bit)
running mongo version 1.1.2. Any change in status on this?

Command: mongoimport -v -d test -c fec --file c:\temp\junk.csv --type
csv -f this,that,other
Data:
a,b,c
1,2,3

Response from mongoimport is "connected to: 127.0.0.1" then crashes.
Response at server is:
connection accepted from 127.0.0.1:20173 #1
MessagingPort recv() error "No error" (0) 127.0.0.1:20173
end connection 127.0.0.1:20173

Eliot Horowitz

unread,
Oct 31, 2009, 11:12:40 AM10/31/09
to mongod...@googlegroups.com
Can you try the nightly? There were some changes that might have fixed.
If it still fails, can you run with verbose (-v) and send the output.

Scott

unread,
Oct 31, 2009, 3:06:01 PM10/31/09
to mongodb-user
Same thing with the nightly. The -v doesn't give any additional
output. It crashes pretty much immediatly, although it does seem to
connect to the server before crashing.

c:\Program Files\MongoDB\bin>mongoimport -v -d test -c fec --file c:
\temp\junk.csv --type csv -f this,that,other
connected to: 127.0.0.1

c:\Program Files\MongoDB\bin>mongoimport -vvvvv -d test -c fec --file
c:\temp\junk.csv --type csv -f this,that,other
connected to: 127.0.0.1

Eric

unread,
Nov 25, 2009, 5:33:05 AM11/25/09
to mongodb-user
Same problem than Scott.

the mongoimport crashes without any error code or logging on my
windows server 2003 (32b) .

Tried 1.1.3 & nightly. I got the same issue even if i run the
mongoimport without any arg.

I'm actually studying the possibility of using mongoDB in a huge
business project and this problem could stop it all right now if no
solution is found.

Any idea ?

Thanks

Eric

unread,
Nov 25, 2009, 5:33:26 AM11/25/09
to mongodb-user

Eric

unread,
Nov 25, 2009, 5:36:50 AM11/25/09
to mongodb-user
ok i just read that you planned to solve it for the 1.1.4 version.
When have you planned to release it ?

tigerfoot

unread,
Dec 8, 2009, 2:09:38 PM12/8/09
to mongodb-user
After working on some other stuff for a while I wanted to revisit
mongodb, so I just tried mongoimport again on both the 1.1.4 and the
1.3.x nightly releases. Unfortunately still not working. In fact if
I just run mongoimport.exe w/no parameters I get a crash box.

This is really frustrating because I absolutely love the potential I
see for using mongodb, but I need scripted bulk load import to work.

I even tried mongoexport to dump out a trivial collection to a file
(worked fine), then edited the file to remove the id fields and then
tried to run mongoimport to slurp in the exact formatted JSON that
mongodb just dumped out. No dice. Here's the console output on the
mongod server:

Tue Dec 08 13:08:00 connection accepted from 127.0.0.1:4407 #6
Tue Dec 08 13:08:02 MessagingPort recv() error "No error" (0)
127.0.0.1:4407
Tue Dec 08 13:08:02 end connection 127.0.0.1:4407

Running mongoimport.exe --help works without crashing. 32-bit Windows
XP installation.

:-(
Hoping for an answer.

tigerfoot

unread,
Jan 11, 2010, 1:11:47 PM1/11/10
to mongodb-user
Woohoo! This is now working in the 1.3.0 branch. I see from the JIRA
for this bug that it may have been backported to the 1.2.x branch too.
In any event, muchas gracias guys! I'm looking forward to exploring
mongodb.


On Dec 8 2009, 1:09 pm, tigerfoot <gzol...@gmail.com> wrote:
> After working on some other stuff for a while I wanted to revisit

> mongodb, so I just triedmongoimportagain on both the 1.1.4 and the


> 1.3.x nightly releases.  Unfortunately still not working.  In fact if

> I just runmongoimport.exe w/no parameters I get a crash box.


>
> This is really frustrating because I absolutely love the potential I
> see for using mongodb, but I need scripted bulk load import to work.
>
> I even tried mongoexport to dump out a trivial collection to a file
> (worked fine), then edited the file to remove the id fields and then

> tried to runmongoimportto slurp in the exact formatted JSON that


> mongodb just dumped out.  No dice.  Here's the console output on the
> mongod server:
>
> Tue Dec 08 13:08:00 connection accepted from 127.0.0.1:4407 #6
> Tue Dec 08 13:08:02 MessagingPort recv() error "No error" (0)
> 127.0.0.1:4407
> Tue Dec 08 13:08:02 end connection 127.0.0.1:4407
>

> Runningmongoimport.exe --help works without crashing.  32-bit Windows

Reply all
Reply to author
Forward
0 new messages