Generate Participation Key getting error txn validity period is greater than protocol max txn lifetime 1000

I ran the first statement to add a partition key, which is generated successfully

sudo goal account addpartkey -a {address} --roundFirstValid 11539259 --roundLastValid 20725307 -d /var/lib/algorand
Participation key generation successful

Then I run the command to generate the online txn message and i get an error that protocol max lifetime is 1000

sudo goal account changeonlinestatus --address={address} --fee=2000 --firstvalid=11539259 --lastvalid=20725307 --online=true --txfile=/var/lib/algorand/online.txn -d /var/lib/algorand

cannot construct transaction: txn validity period ( 11539259 to 20725307 ) is greater than protocol max txn lifetime 1000

Can someone one give me a hand on what mistake I am making or is the limit really 1000?

Thanks

1 Like

In the latter, the firstvalid and lastvalid refer to the transaction validity period rather than the intended participation key validity period.
Does the roundfirstvalid works for goal account changeonlinestatus ?

In addition to Tsachi’s excellent answer, please be very careful when using sudo to generate the participation key.

When you run sudo goal account addpartkey ..., the partkey will be owned by the user root and will not be working properly if algod is run by a different user.
That is the case if you are using the default Debian installation, which runs algod under the user algorand.

In that case, you need to run all your commands using the user algorand:

sudo -u algorand -E goal account addpartkey -a {address} --roundFirstValid 11539259 --roundLastValid 20725307 -d /var/lib/algorand

Also, don’t hesitate to use the AlertHub portal to easily monitor your node: https://app.metrika.co

1 Like

I dropped the --firstvalid and --lastvalid parameters from the goal account changeonlinestatus command. This allowed me to generate and sign the message. My account is now online.

Really appreciate the help with the command and also the Sudo tip.

Thank you,
JV