tronprotocol / java-tron

Java implementation of the Tron whitepaper
GNU Lesser General Public License v3.0
3.71k stars 1.4k forks source link

Tron private chain build upgrade . #5994

Open 0xarmaansidhu opened 1 week ago

0xarmaansidhu commented 1 week ago

I have a tron private chain network i want to update the build for it as the current Fullnode.jar file has some error in it.

How can i update the build for the whole network which has 27 block producing nodes(Sr nodes )and 10 fullnodes, where i donot loose the current data of the blockchain

Also i don't want to stop the whole chain at once.

abn2357 commented 1 week ago

when updating, ensure that more than 19 sr nodes can operate normally.

0xarmaansidhu commented 1 week ago

@abn2357 which is more than 2/3 of total ,right?

tomatoishealthy commented 1 week ago

@abn2357 which is more than 2/3 of total ,right?

Yes, make sure 2/3 of SRs are online

0xarmaansidhu commented 6 hours ago

@tomatoishealthy @abn2357 we were able to upload a new build, but now in some of our products we get weird errors like ILLEGAL_OPERATION, whereas they were working previously,they all are contract ineractions.

{
    "id": "efc13d03267e053df51e4507137deeb94cb5e81bf8412f78a55c6518e76e5eb1",
    "fee": 847842,
    "blockNumber": 4529643,
    "blockTimeStamp": 1726672077000,
    "contractResult": [
        ""
    ],
    "contract_address": "PV6wk9edRFvc1JVRhwXHX1oEx7a16XjZFE",
    "receipt": {
        "energy_fee": 752642,
        "energy_usage_total": 752642,
        "net_fee": 95200,
        "result": "ILLEGAL_OPERATION"
    },
    "result": "FAILED",
    "resMessage": "Invalid operation code: opCode[30];"
}
tomatoishealthy commented 6 hours ago

According to the log, it seems that the opcode is not enabled, but the 0x30 opcode does not have a switch and is enabled by default.

Have you modified the code? You can follow the above ideas and solve it by enabling the proposal.

0xarmaansidhu commented 5 hours ago

@tomatoishealthy I have all the proposals enabled

{
    "chainParameter": [
        {
            "key": "getMaintenanceTimeInterval",
            "value": 1800000
        },
        {
            "key": "getAccountUpgradeCost",
            "value": 9999000000
        },
        {
            "key": "getCreateAccountFee"
        },
        {
            "key": "getTransactionFee",
            "value": 200
        },
        {
            "key": "getAssetIssueFee",
            "value": 1024000000
        },
        {
            "key": "getWitnessPayPerBlock",
            "value": 50000
        },
        {
            "key": "getWitnessStandbyAllowance",
            "value": 115200000000
        },
        {
            "key": "getCreateNewAccountFeeInSystemContract",
            "value": 100000
        },
        {
            "key": "getCreateNewAccountBandwidthRate",
            "value": 1
        },
        {
            "key": "getAllowCreationOfContracts",
            "value": 1
        },
        {
            "key": "getRemoveThePowerOfTheGr",
            "value": -1
        },
        {
            "key": "getEnergyFee",
            "value": 1
        },
        {
            "key": "getExchangeCreateFee",
            "value": 1024000000
        },
        {
            "key": "getMaxCpuTimeOfOneTx",
            "value": 100
        },
        {
            "key": "getAllowUpdateAccountName"
        },
        {
            "key": "getAllowSameTokenName",
            "value": 1
        },
        {
            "key": "getAllowDelegateResource",
            "value": 1
        },
        {
            "key": "getTotalEnergyLimit",
            "value": 100000000000
        },
        {
            "key": "getAllowTvmTransferTrc10",
            "value": 1
        },
        {
            "key": "getTotalEnergyCurrentLimit",
            "value": 100000000000
        },
        {
            "key": "getAllowMultiSign",
            "value": 1
        },
        {
            "key": "getAllowAdaptiveEnergy"
        },
        {
            "key": "getTotalEnergyTargetLimit",
            "value": 6944444
        },
        {
            "key": "getTotalEnergyAverageUsage"
        },
        {
            "key": "getUpdateAccountPermissionFee",
            "value": 100000000
        },
        {
            "key": "getMultiSignFee",
            "value": 1000000
        },
        {
            "key": "getAllowAccountStateRoot"
        },
        {
            "key": "getAllowProtoFilterNum"
        },
        {
            "key": "getAllowTvmConstantinople",
            "value": 1
        },
        {
            "key": "getAllowTvmSolidity059",
            "value": 1
        },
        {
            "key": "getAllowTvmIstanbul",
            "value": 1
        },
        {
            "key": "getAllowShieldedTRC20Transaction",
            "value": 1
        },
        {
            "key": "getForbidTransferToContract"
        },
        {
            "key": "getAdaptiveResourceLimitTargetRatio",
            "value": 10
        },
        {
            "key": "getAdaptiveResourceLimitMultiplier",
            "value": 1000
        },
        {
            "key": "getChangeDelegation",
            "value": 1
        },
        {
            "key": "getWitness127PayPerBlock",
            "value": 150000
        },
        {
            "key": "getAllowMarketTransaction"
        },
        {
            "key": "getMarketSellFee"
        },
        {
            "key": "getMarketCancelFee"
        },
        {
            "key": "getAllowPBFT"
        },
        {
            "key": "getAllowTransactionFeePool"
        },
        {
            "key": "getMaxFeeLimit",
            "value": 10000000000
        },
        {
            "key": "getAllowOptimizeBlackHole",
            "value": 1
        },
        {
            "key": "getAllowNewResourceModel"
        },
        {
            "key": "getAllowTvmFreeze",
            "value": 1
        },
        {
            "key": "getAllowTvmVote"
        },
        {
            "key": "getAllowTvmLondon",
            "value": 1
        },
        {
            "key": "getAllowTvmCompatibleEvm"
        },
        {
            "key": "getAllowAccountAssetOptimization"
        },
        {
            "key": "getFreeNetLimit",
            "value": 300
        },
        {
            "key": "getTotalNetLimit",
            "value": 2000000000
        },
        {
            "key": "getAllowHigherLimitForMaxCpuTimeOfOneTx"
        },
        {
            "key": "getAllowAssetOptimization"
        },
        {
            "key": "getAllowNewReward"
        },
        {
            "key": "getMemoFee"
        },
        {
            "key": "getAllowDelegateOptimization"
        },
        {
            "key": "getUnfreezeDelayDays",
            "value": 14
        },
        {
            "key": "getAllowOptimizedReturnValueOfChainId"
        },
        {
            "key": "getAllowDynamicEnergy",
            "value": 1
        },
        {
            "key": "getDynamicEnergyThreshold",
            "value": 3000000000
        },
        {
            "key": "getDynamicEnergyIncreaseFactor",
            "value": 2000
        },
        {
            "key": "getDynamicEnergyMaxFactor",
            "value": 12000
        },
        {
            "key": "getAllowTvmShangHai",
            "value": 1
        },
        {
            "key": "getAllowCancelAllUnfreezeV2",
            "value": 1
        },
        {
            "key": "getMaxDelegateLockPeriod",
            "value": 86400
        },
        {
            "key": "getAllowOldRewardOpt"
        },
        {
            "key": "getAllowEnergyAdjustment"
        },
        {
            "key": "getMaxCreateAccountTxSize",
            "value": 1000
        }
    ]
}