# 🛠️  Upgrade

***Automatic upgrade***

```bash
source <(curl -s https://raw.githubusercontent.com/validexisinfra/Agoric/main/upgrademain.sh)
```

***Manual upgrade***

<pre class="language-bash"><code class="lang-bash">cd $HOME
rm -rf agoric-upgrade-20
git clone https://github.com/Agoric/agoric-sdk.git agoric-upgrade-21
cd agoric-upgrade-21
git checkout agoric-upgrade-21

# Install and build Agoric Javascript packages
<strong>yarn install &#x26;&#x26; yarn build
</strong><strong>
</strong># Install and build Agoric Cosmos SDK support
(cd packages/cosmic-swingset &#x26;&#x26; make)

sudo systemctl restart agoricd &#x26;&#x26; sudo journalctl -fu agoricd -o cat
</code></pre>
