2

Sometimes I got this error when deploy program with running "anchor deploy":

Error: Deploying program failed: RPC response error -32002: Transaction simulation failed: Error processing Instruction 0: account data too small for instruction [3 log messages]
There was a problem deploying: Output { status: ExitStatus(unix_wait_status(256)), stdout: "", stderr: "" }.

So I have to run "anchor clean, cargo clean" and change cluster, sometimes it works, sometimes it doesnot, please help. how to fix this?

1 Answer 1

4

You'll need to extend your program size.

Hopefully you are using a version greater than .18

 solana program extend PROGRAM_ID 20000 -u d -k KEYPAIR_FILE_PATH

replace PROGRAM_ID and KEYPAIR_FILE_PATH with your own, e.g

 solana program extend HMDRWmYvL2A9xVKZG8iA1ozxi4gMKiHQz9mFkURKrG4 20000 -u d -k ~/.config/solana/id.json

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.