# Help changing static ip

**URL:** https://discuss.pynq.io/t/help-changing-static-ip/260
**Category:** Support
**Created:** [June 28, 2019, 9:44pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260 "2019-06-28T21:44:35Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![rvq](https://avatars.discourse-cdn.com/v4/letter/r/4af34b/32.png) [@rvq](https://discuss.pynq.io/u/rvq)
#### Post date: [June 28, 2019, 9:44pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/1 "2019-06-28T21:44:35Z")

</div>

I’m trying to change the static IP. I’ve gone to /etc/netplan/ directory and there is no ‘.yaml’ file. is there supposed to be one here?

It looks like the networkd service is running so I create a yaml file in /etc/netplan called 01-netcfg.yaml with the following contents:

```
# This file is generated from information provided by
# the datasource. Changes to it will not persist across an instance.
# To disable cloud-init's network configuration capabilities, write a file
# /etc/cloud/cloud.cfg.d/99-disable-network-config.cfg with the following:
# network: {config: disabled}

network:
        version: 2
        renderer: networkd
        ethernets:
                eth0:
                        address:
                                - 192,168.1.31/24
                                  #gateway4: 192.168.1.1
                        nameservers:
                                addresses: [8.8.8.8, 8.8.4.4]

```

This approach is taken from

[https://netplan.io/examples](https://netplan.io/examples)

When I run sudo netplan apply I get the following error

**Error in network definition //etc/netplan/01-netcfg.yaml line 12 column 24: unknown key address**

What am I missing here?

I did find this

[https://pynq.readthedocs.io/en/v2.0/faqs.html#how-do-i-set-change-the-static-ip-address-on-the-board](https://pynq.readthedocs.io/en/v2.0/faqs.html#how-do-i-set-change-the-static-ip-address-on-the-board)

Why do we edit this instead of using the regular netplan yaml config?

---

<div class="post-metadata">

### Author: ![cathalmccabe](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/cathalmccabe/32/3348_2.png) [@cathalmccabe](https://discuss.pynq.io/u/cathalmccabe)
#### Post date: [June 30, 2019, 8:54am UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/2 "2019-06-30T08:54:41Z")

</div>

Are you just trying to change it after the board has booted?

From terminal:  
sudo ifconfig eth0:0 [new IP address]

Cathal

---

<div class="post-metadata">

### Author: ![rvq](https://avatars.discourse-cdn.com/v4/letter/r/4af34b/32.png) [@rvq](https://discuss.pynq.io/u/rvq)
#### Post date: [July 2, 2019, 8:37pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/3 "2019-07-02T20:37:19Z")

</div>

I was trying to change it permanently so it is set to a different address (different than .99) once booted and for all other boots.

---

<div class="post-metadata">

### Author: ![sleach3](https://avatars.discourse-cdn.com/v4/letter/s/c0e974/32.png) [@sleach3](https://discuss.pynq.io/u/sleach3)
#### Post date: [July 3, 2019, 4:47pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/4 "2019-07-03T16:47:57Z")

</div>

If you go to /etc/network/interface.d and open the eth0 file. You can change the boards default IP address for every boot.

Also, if you aren’t planning on connecting this board to a router or anything you could comment out the top two lines while you are editing the file.

---

<div class="post-metadata">

### Author: ![rvq](https://avatars.discourse-cdn.com/v4/letter/r/4af34b/32.png) [@rvq](https://discuss.pynq.io/u/rvq)
#### Post date: [July 3, 2019, 4:52pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/5 "2019-07-03T16:52:36Z")

</div>

Thank you sleach3! I’m curious - I thought Ubuntu18x used netplan. It looks like bionic is Ubuntu 18.x why isn’t this using netplan like Ubuntu 18?

---

<div class="post-metadata">

### Author: ![sleach3](https://avatars.discourse-cdn.com/v4/letter/s/c0e974/32.png) [@sleach3](https://discuss.pynq.io/u/sleach3)
#### Post date: [July 3, 2019, 4:57pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/6 "2019-07-03T16:57:33Z")

</div>

That I can not help you with. I assume that they use some modified system to make it run more efficiently.

---

<div class="post-metadata">

### Author: ![rock](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.pynq.io/rock/32/32_2.png) [@rock](https://discuss.pynq.io/u/rock)
#### Post date: [July 3, 2019, 7:02pm UTC](https://discuss.pynq.io/t/help-changing-static-ip/260/7 "2019-07-03T19:02:52Z")

</div>

Using `/etc/network/interface.d` is quite a standard technique…

You can probably try netplan, but you have to apt install it before using it.
