---
title: 'Tutorial: Reset Multi-Daemon Mode and Number of TCP/UDP Daemons'
canonical: https://openvpn.net/as-docs/v3/tutorials/tutorial--reset-multi-daemon-and-tcp-udp-daemons/
product: Access Server Docs
description: How to reset the multi-daemon mode in Access Server to the default settings. This includes configuring the number of TCP and UDP daemons.
---

# Tutorial: Reset Multi-Daemon Mode and Number of TCP/UDP Daemons

## Overview

This tutorial guides you through resetting the multi-daemon mode in Access Server to its default settings. This involves configuring the number of TCP and UDP daemons to match the number of CPU cores on your system.

## Prerequisites

- An installed Access Server.
- Console access and the ability to get root access.

## Option 1: Reset multi-daemon mode and the number of TCP and UDP daemons from the command line

1. Connect to the console and get root privileges.
2. Run the commands below, which use the `sacli GetNCores` command to detect the number of CPU cores and set the number of TCP and UDP daemons accordingly.

   ```
   sacli --key "vpn.server.daemon.enable" --value "true" ConfigPut
   sacli --key "vpn.daemon.0.listen.protocol" --value "tcp" ConfigPut
   sacli --key "vpn.server.port_share.enable" --value "true" ConfigPut
   sacli --key "vpn.server.daemon.tcp.n_daemons" --value "`./sacli GetNCores`" ConfigPut
   sacli --key "vpn.server.daemon.udp.n_daemons" --value "`./sacli GetNCores`" ConfigPut
   sacli start
   ```

   Turns on multi-daemon mode.

   Sets the first daemon's protocol to TCP.

   Turns on port sharing for TCP.

   Sets the number of TCP daemons to match the number of CPU cores.

   Sets the number of UDP daemons to match the number of CPU cores.

   Restarts the Access Server service to apply changes.

   - You've now reset your Access Server to use multi-daemon mode, with the number of TCP and UDP daemons set according to your CPU cores. This setup helps optimize VPN connection performance and load balancing.

## Option 2: Reset multi-daemon mode and the number of TCP and UDP daemons from the Admin Web UI

1. Sign in to the Admin Web UI.
2. Click **VPN Server**.
3. On the **Network Settings** tab, go to the **OpenVPN daemons** section.
4. Set the **Protocol** to **TCP and UDP**.
5. Set the **Number of daemons** for each protocol to the number listed as system-supported.
6. Click **Save** and **Restart**.

---

Prev: [Tutorial: Turn Off Multi-Daemon Mode and Use Only TCP or UDP](https://openvpn.net/as-docs/v3/tutorials/tutorial--turn-off-multi-daemon.md)
Next: [Tutorial: Reset OpenVPN Web Services and Daemons to Default Settings](https://openvpn.net/as-docs/v3/tutorials/tutorial--reset-web-services-and-daemons.md)
Index: https://openvpn.net/as-docs/llms.txt
