Cannot Assign Network Address as IP address

I am trying to add/change VLAN IP addresses. I am in configure, and I type the following:
set interfaces ethernet eth1 vif 46 address ‘XXX.XXX.XX.XXX’, where ‘X’ is a number, and when I hit enter, I get the following “Cannot assign network address as IP address”
“Value validation failed”
“Set failed”
What am I doing wrong?

Verify that the IP address you are assigning follows IPV4 addressing conventions.
Here’s an example for a /24: <----- network address (nope) <---- usable <---- broadcast address (nope)

How about
Just to be clear, can this IP be used as a gateway, since it ends in ‘0’?

in subnet, is the subnet-id and you can only use addresses - for hosts. Check a subnet calculator.

I’m just making sure about this before I put a statement into the Vyos. I tried using an IP like (this is an example, not the actual IP), but kept getting an error message about Cannot assign network address as IP address. I then put in then Vyos would accept it. I just wanted to check to make sure I was not creating a problem by having and range from 160-163.

Hi skeating,

the error message is correct, the IP is not useable like @Line2 explained
you can calculate the IP spaces here:

or i misunderstand your question/problem

I finally figured that out, What I did not understand was the IP range for (example) is 160-163. But if I put into the vyos, (since is unacceptable) then .161 is now the gateway, even though the range has 160 in it. Out of 4 possible IPs, only one can be use on a device, the other must be the gateway. Am I getting this right?

yes, because in a /30 net there are 4 IPs but only 2 are useable.

Thanks so much for your help.

Here is what that command shows.
Filesystem Size Used Avail Use% Mounted on
overlayfs 7.3G 7.2G 0 100% /
tmpfs 1.9G 0 1.9G 0% /lib/init/rw
udev 1.9G 316K 1.9G 1% /dev
tmpfs 1.9G 4.0K 1.9G 1% /dev/shm
/dev/sda1 7.3G 7.2G 0 100% /live/image
/dev/sda1 7.3G 7.2G 0 100% /live/cow
tmpfs 1.9G 0 1.9G 0% /live
tmpfs 1.9G 40K 1.9G 1% /tmp
/dev/sda1 7.3G 7.2G 0 100% /opt/vyatta/etc/config
tmpfs 1.9G 68K 1.9G 1% /var/run
none 1.9G 408K 1.9G 1% /opt/vyatta/config

How close is this to not being able to function, and where should I reduce stuff?

maybe post is in wrong thread

Where should I put it?

maybe to this one: :wink: