[SERVER-7342] jstests/disk/directoryperdb.js fails on Windows Created: 12/Oct/12  Updated: 28/Oct/15  Resolved: 15/Oct/12

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: 2.3.0

Type: Bug Priority: Major - P3
Reporter: Tad Marshall Assignee: Andy Schwerin
Resolution: Done Votes: 0
Labels: Windows, buildbot
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Windows build slave


Operating System: Windows
Participants:

 Description   

With recent changes to command line parsing and to Boost::filesystem v3, the jstests/disk/directoryperdb.js test has been failing. The problem is some hardcoding of forward slash as a directory separator and issues with mongorestore in Windows. The mongorestore issues are addressed in SERVER-7341; this ticket is for the rest of getting this test to pass on Windows.

http://buildlogs.mongodb.org/Windows%2064-bit/builds/5105/test/disk/directoryperdb.js

Fri Oct 12 06:30:36 [initandlisten] connection accepted from 127.0.0.1:52045 #3 (1 connection now open)
Fri Oct 12 06:30:36 [conn3] end connection 127.0.0.1:52045 (0 connections now open)
MongoDB shell version: 2.3.0-pre-
connecting to: 127.0.0.1:27999/test
Fri Oct 12 06:30:36 [initandlisten] connection accepted from 127.0.0.1:52052 #4 (1 connection now open)
null
Fri Oct 12 06:30:36 shell: started program mongod.exe --port 31000 --dbpath /data/db/jstests_disk_directoryper --noprealloc --smallfiles --oplogSize 40 --nohttpinterface --directoryperdb --bind_ip 127.0.0.1
 m31000| note: noprealloc may hurt performance in many applications
 m31000| Fri Oct 12 06:30:36 [initandlisten] MongoDB starting : pid=4060 port=31000 dbpath=/data/db/jstests_disk_directoryper 64-bit host=AMAZONA-JD1A6QA
 m31000| Fri Oct 12 06:30:36 [initandlisten] 
 m31000| Fri Oct 12 06:30:36 [initandlisten] ** NOTE: This is a development version (2.3.0-pre-) of MongoDB.
 m31000| Fri Oct 12 06:30:36 [initandlisten] **       Not recommended for production.
 m31000| Fri Oct 12 06:30:36 [initandlisten] 
 m31000| Fri Oct 12 06:30:36 [initandlisten] db version v2.3.0-pre-, pdfile version 4.5
 m31000| Fri Oct 12 06:30:36 [initandlisten] git version: cfd233fc99619d38c7be786277bcd9d929b2b7b0
 m31000| Fri Oct 12 06:30:36 [initandlisten] build info: windows sys.getwindowsversion(major=6, minor=1, build=7601, platform=2, service_pack='Service Pack 1') BOOST_LIB_VERSION=1_49
 m31000| Fri Oct 12 06:30:36 [initandlisten] options: { bind_ip: "127.0.0.1", dbpath: "/data/db/jstests_disk_directoryper", directoryperdb: true, nohttpinterface: true, noprealloc: true, oplogSize: 40, port: 31000, smallfiles: true }
 m31000| Fri Oct 12 06:30:36 [initandlisten] journal dir=/data/db/jstests_disk_directoryper\journal
 m31000| Fri Oct 12 06:30:36 [initandlisten] recover : no journal files present, no recovery needed
 m31000| Fri Oct 12 06:30:36 [initandlisten] waiting for connections on port 31000
 m31000| Fri Oct 12 06:30:37 [initandlisten] connection accepted from 127.0.0.1:52053 #1 (1 connection now open)
 m31000| Fri Oct 12 06:30:37 [FileAllocator] allocating new datafile /data/db/jstests_disk_directoryper\directoryperdb\directoryperdb.ns, filling with zeroes...
 m31000| Fri Oct 12 06:30:37 [FileAllocator] creating directory /data/db/jstests_disk_directoryper\directoryperdb\_tmp
 m31000| Fri Oct 12 06:30:37 [FileAllocator] done allocating datafile /data/db/jstests_disk_directoryper\directoryperdb\directoryperdb.ns, size: 16MB,  took 0.047 secs
 m31000| Fri Oct 12 06:30:37 [FileAllocator] allocating new datafile /data/db/jstests_disk_directoryper\directoryperdb\directoryperdb.0, filling with zeroes...
 m31000| Fri Oct 12 06:30:37 [FileAllocator] done allocating datafile /data/db/jstests_disk_directoryper\directoryperdb\directoryperdb.0, size: 16MB,  took 0.047 secs
 m31000| Fri Oct 12 06:30:37 [conn1] build index directoryperdb.directoryperdb { _id: 1 }
 m31000| Fri Oct 12 06:30:37 [conn1] build index done.  scanned 0 total records. 0.001 secs
 m31000| Fri Oct 12 06:30:37 [conn1] CMD fsync: sync:1 lock:0
 m31000| Fri Oct 12 06:30:37 [conn1] command admin.$cmd command: { fsync: 1.0 } ntoreturn:1 keyUpdates:0 locks(micros) W:4565 reslen:51 748ms
assert failed : B dir:/data/db/jstests_disk_directoryper/ f: 0
Error("Printing Stack Trace")@:0
()@src/mongo/shell/utils.js:37
("assert failed : B dir:/data/db/jstests_disk_directoryper/ f: 0")@src/mongo/shell/utils.js:58
(false,"B dir:/data/db/jstests_disk_directoryper/ f: 0")@src/mongo/shell/utils.js:66
("/data/db/jstests_disk_directoryper/")@D:\slave\Windows_64bit\mongo\jstests\disk\directoryperdb.js:27
@D:\slave\Windows_64bit\mongo\jstests\disk\directoryperdb.js:30
 
Fri Oct 12 06:30:37 uncaught exception: assert failed : B dir:/data/db/jstests_disk_directoryper/ f: 0
failed to load: D:\slave\Windows_64bit\mongo\jstests\disk\directoryperdb.js



 Comments   
Comment by Tad Marshall [ 15/Oct/12 ]

We should document that the shell's listFiles() function will return forward slashes on all operating systems, including Windows.

Comment by auto [ 15/Oct/12 ]

Author:

{u'date': u'2012-10-15T08:23:18-07:00', u'name': u'Andy Schwerin', u'email': u'schwerin@10gen.com'}

Message: SERVER-7342 Have the listFiles() shell command always use foreward slash as the path separator.
Branch: master
https://github.com/mongodb/mongo/commit/3db903709a0ddb23072cd43d1e3e440be4aa75cc

Generated at Thu Feb 08 03:14:15 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.