How to Change Interface on Cisco IOU

Hello Experts,

Can someone please let me know how to change the interface eth0 in the image with the appropriate Unix / Linux commands. I would like to change the interface from 192.168.80.160 to 192.168.99.5.

Thank you

Regards
ciscoIOU.png
LVL 1
Member_2_7966113Asked:
Who is Participating?
 
James BilousSoftware EngineerCommented:
Ah, sorry, thought you meant mask and not gateway.  

route add default gw 10.1.1.1

Open in new window


should work
0
 
James BilousSoftware EngineerCommented:
Yup:

ifconfig eth0 192.168.99.5 netmask 255.255.255.0 up

Open in new window

0
 
Member_2_7966113Author Commented:
James,

Thanks spot on.

Cheers
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
Member_2_7966113Author Commented:
James

Can you let me know how to save the configuration?
0
 
James BilousSoftware EngineerCommented:
Whats your distro? This usually involves editing a config file which is distribution independent.
0
 
Member_2_7966113Author Commented:
James,

No idea what distro is.

I thought there would be a simple command to save the configuration - or does it work the same was Windows?
0
 
James BilousSoftware EngineerCommented:
Distro is your linux distribution. For example, you may have Ubuntu, Linux Mint, Suse, Red Hat, etc. etc, all linux based but still different operating systems, each with different ways of saving configurations.

If you are on Ubuntu, for example, you can simply use the "network management" application to set and save the IP for the eth0 interface. You can also edit a configuration file, /etc/network/interfaces, and save it to persist the changes across reboot.
0
 
Member_2_7966113Author Commented:
Hi James,

Can you show me the linux / unix commands to set the default gateway?

Thanks
0
 
James BilousSoftware EngineerCommented:
You can simply use the same command but leave the IP unchanged while changing the default gateway.
0
 
Member_2_7966113Author Commented:
James,

Do you mean

ifconfig eth0 192.168.99.5 defaultgateway 10.1.1.1
0
 
Member_2_7966113Author Commented:
Perfect .  Thanks
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.