Friday, May 3, 2024
 Popular · Latest · Hot · Upcoming
10
rated 0 times [  10] [ 0]  / answers: 1 / hits: 8782  / 1 Year ago, tue, december 6, 2022, 8:43:37

I've installed Debian in my VirtualBox (my host OS is Ubuntu). And there I configured two network interfaces: eth0 as NAT, and eth1 as Bridge.



NAT I need to have access to the internet in virtual OS, but Bridge I need because I want this virtual OS to be a part of my local network.



How to switch from these network interfaces? For example now I use eth0 (NAT), but some time later I need to turn off eth0 and turn on eth1.



P.S. There is no Desktop Environment in guest OS (Debian), so I need to do this in terminal.



Thanks in advance.


More From » virtualbox

 Answers
2

If both interface are configured in /etc/network/interfaces you can use



sudo ifup eth0


to bring eth0 up and



sudo ifdown eth0


to take eth0 down


[#43537] Wednesday, December 7, 2022, 1 Year  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
odenanno

Total Points: 207
Total Questions: 113
Total Answers: 94

Location: South Korea
Member since Sat, Oct 2, 2021
3 Years ago
odenanno questions
;