I’m trying to up my game in the command line. At the moment I am attempting to set up a DHCP server on an ER-4. Below are the commands that I am issuing via putty.
When I paste it into the terminal I get an error that states "The specified configuration node is not valid.
I grabbed these straight from ubiquiti’s website and haven’t really been able to find any other information about it.
configure
Set service DHCP-server disabled false
Set service DHCP-server shared-network-name LAN1 authoritative enable
Set service DHCP-server shared-network-name LAN1 subnet 192.168.50.0/24 default-router 192.168.50.1
Set service DHCP-server shared-network-name LAN1 subnet 192.168.50.0/24 DNS-server 192.168.50.1
Set service DHCP-server shared-network-name LAN1 subnet 192.168.50.0/24 Lease 86400
Set service DHCP-server shared-network-name LAN1 subnet 192.168.50.0/24 start 192.168.50.100 stop 192.168.50.240
commit
save
When I paste it into the terminal I get an error that states "The
I was able to set up some basic firewall rules and they worked putting the whole block in at once and it starts of with the configure
on the first line
@Dutch_Master I am able to set it up via the GUI with no problem. just trying to expand my skills.
I checked the GUI and there are no DHCP server configured,
I would think that the first line
Set service DHCP-server disabled false
would add in a new DHCP server. But maybe that is the issue where it is trying to make edits to something that does not exist.
I noticed prior that when I tried to run the configure
I typed in a capital c Configure. When I did that I received the error the command not found. But when it is lowercase I was able to enter it with no issue.
Yea. I think what did me in was I pre-typed it all up in a .txt file. Then force of habit I capitalize things like DHCP and DNS. Were not even gonna talk about why I put in a capital L in lease.
I think my pinkie just likes to hit the shift key on me at random lol.
decided that I would add in some more to this thread rather than open a new one.
If I need to change the category just let me know,
Working on adding in static routes at the moment,
Was able to add in a static route successfully using the below
set protocols static route 172.41.25.0/24 next-hop 192.168.66.1 description
set protocols static route 172.41.25.0/24 next-hop 192.168.66.1 distance 1
commit ; save
How would I go about adding it in to use an interface instead of a gateway.
Spent lots of time googling and have not been able to come up with anything.