You upgrade an agent by installing a new agent on top of the old one. Follow the installation instructions for installing an agent.