---
title: Set a Static IP Address
slug: bhdm/set-a-static-ip-address
createdAt: 2022-07-06T18:39:24.000Z
---

You can set a static IP address for Belden Horizon Data Manager instead of using DHCP.

If you have installed Belden Horizon Data Manager on ESXi and there is no IP address shown to access the interface, you must set a static IP address.

**Use the following example to set your own static IP address**:

1\. From a command prompt, enter the following:

:::BlockQuote
NEW\_IP=xxx.xxx.1.222
sudo /opt/lem/bin/lem-update-domain-names.sh $NEW\_IP $NEW\_IP
sudo /opt/lem/bin/stop-all-nomad-jobs.sh
\#disable dhcp and set static IP, see an example below
sudo vi /etc/netplan/01-netcfg.yaml
:::

The `.yaml` file opens.

:::hint{type="info"}
**Note**: The `.yaml` file is located in `/etc/netplan/01-netcfg.yaml`.
:::

2\. Enter the following lines in the `.yaml `file while substituting "x" with the relevant numbers:

```yaml
network:
  version: x
  ethernets:
    eth0:
      dhcp4: false
      addresses: [xxx.xxx.x.xxx/xx]
      gateway4: xxx.xxx.x.x
      nameservers:
        addresses: [x.x.x.x,x.x.x.x]
```

3\. From a command prompt, enter the following:

:::BlockQuote
sudo netplan apply
sudo reboot
:::

