Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

calling personal.newAccount("mypassword") multiple times throws out of memory issue #2901

Closed
olahivepriyanka opened this issue Aug 11, 2016 · 5 comments

Comments

@olahivepriyanka
Copy link

olahivepriyanka commented Aug 11, 2016

System information

Geth version: Geth/v1.4.10-stable/linux/go1.5.1
OS & Version: Linux
Commit hash : (if develop)

creating accounts on calling personal.newAccount in recursive loop

but it is throwing out of memory after creating for second time or third time

runtime: out of memory: cannot allocate 65536-byte block (536870912 in use)
fatal error: out of memory

runtime stack:
runtime.throw(0x89bf910, 0xd)
/usr/lib/go/src/runtime/panic.go:527 +0x7f
runtime.mCache_Refill(0x8746a000, 0x2, 0x9760c600)
/usr/lib/go/src/runtime/mcache.go:120 +0xd1
runtime.mallocgc.func2()
/usr/lib/go/src/runtime/malloc.go:611 +0x2b
runtime.systemstack(0x977a6fe0)
/usr/lib/go/src/runtime/asm_386.s:267 +0x57
runtime.mstart()
/usr/lib/go/src/runtime/proc1.go:674
...........................................

call personal.newAccount again and again

is anyone facing this kind of issue? i heard that because of unstable version it happens, so installed stable version in another system with 8gb RAM still problem continues..please someone help me to sove this. thank you

@SinErgy84
Copy link

no problem here, doing the same: creating nearly 100 accounts in a loop.
only "issue" is that creation takes around 3 seconds per account.

maybe machine / vm / os issue?

@olahivepriyanka
Copy link
Author

i tried with 3 machines, problem appears to be the same.. with v1.4.9, v1.4.10, v1.5.0.... ubuntu 14.04 32bit

@SinErgy84
Copy link

maybe your selected passwords are the problem? what's their length? using special chars other than [0-9a-zA-z]?

mine are 51 chars long and alphanumeric with !@#$%&*? as special chars

@olahivepriyanka
Copy link
Author

the password which i am using is "mypassword"

@karalabe
Copy link
Member

A program running on a 32bit operating system can only ever access 2GB worth of memory. How much is your geth consuming when "idle"? The standard account crypto needs 256MB of memory to execute a single creation/unlock operation, though if you just create accounts iteratively it shouldn't pile up. Are you sure you're not creating the accounts concurrently, maxing out your 2GB 32 bit allowance?

I also started up an infinite loop with account creations and the memory usage is stable for me (left it running for 200 accounts).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants