I have 32bit system. Developer sent me mongo's dump contains fs.chunks.bson - 3 GB. I dont need such many files. Mongorestore fails saing
mmap failed with out of memory, if you're using 32-bits, then you probably need to upgrade to 64
How can I delete some data before using mongorestore?
You can't. The files are not sequential, the data could be anywhere in the files, so you cannot simply update the files.
The only way to delete data is first to load the DB (which you cannot do on 32-bit) and then delete. If you have a 64-bit machine handy, try that.
If you do not have a 64-bit machine available, several "cloud providers", such as Amazon's EC2, allow you to rent a 64-bit server for pennies an hour.