My newly compiled kernel loses Networking in qemu
up vote
0
down vote
favorite
I compiled a kernel from source :
make defconfig
make kvmconfig
make -j 4
After this , i use the resulting bzImage for my qemu command:
qemu-system-x86_64 -hda debian.img -kernel bzImage -append "root=/dev/sda console=ttyS0" -nographic -m 4096 -smp 2 --enable-kvm -net user,hostfwd=tcp::10021-:22 -net nic
It mounts, and I get a shell and everything, but it loses connectivity. In qemu, it logs :
[FAILED] Failed to start Raise network interfaces.
See 'systemctl status networking.service' for details.
Can someone guide me on this ? I already consulted Linux vanilla kernel on QEMU and networking with eth0 but it does not solve my issue. Also, Im not looking for hardcore qemu-bridge-solutions. Im pretty sure some network drivers are not getting loaded , but I can't figure out how to resolve it. Or maybe Im missing some kernel .config options.
linux networking linux-kernel kernel qemu
add a comment |
up vote
0
down vote
favorite
I compiled a kernel from source :
make defconfig
make kvmconfig
make -j 4
After this , i use the resulting bzImage for my qemu command:
qemu-system-x86_64 -hda debian.img -kernel bzImage -append "root=/dev/sda console=ttyS0" -nographic -m 4096 -smp 2 --enable-kvm -net user,hostfwd=tcp::10021-:22 -net nic
It mounts, and I get a shell and everything, but it loses connectivity. In qemu, it logs :
[FAILED] Failed to start Raise network interfaces.
See 'systemctl status networking.service' for details.
Can someone guide me on this ? I already consulted Linux vanilla kernel on QEMU and networking with eth0 but it does not solve my issue. Also, Im not looking for hardcore qemu-bridge-solutions. Im pretty sure some network drivers are not getting loaded , but I can't figure out how to resolve it. Or maybe Im missing some kernel .config options.
linux networking linux-kernel kernel qemu
add a comment |
up vote
0
down vote
favorite
up vote
0
down vote
favorite
I compiled a kernel from source :
make defconfig
make kvmconfig
make -j 4
After this , i use the resulting bzImage for my qemu command:
qemu-system-x86_64 -hda debian.img -kernel bzImage -append "root=/dev/sda console=ttyS0" -nographic -m 4096 -smp 2 --enable-kvm -net user,hostfwd=tcp::10021-:22 -net nic
It mounts, and I get a shell and everything, but it loses connectivity. In qemu, it logs :
[FAILED] Failed to start Raise network interfaces.
See 'systemctl status networking.service' for details.
Can someone guide me on this ? I already consulted Linux vanilla kernel on QEMU and networking with eth0 but it does not solve my issue. Also, Im not looking for hardcore qemu-bridge-solutions. Im pretty sure some network drivers are not getting loaded , but I can't figure out how to resolve it. Or maybe Im missing some kernel .config options.
linux networking linux-kernel kernel qemu
I compiled a kernel from source :
make defconfig
make kvmconfig
make -j 4
After this , i use the resulting bzImage for my qemu command:
qemu-system-x86_64 -hda debian.img -kernel bzImage -append "root=/dev/sda console=ttyS0" -nographic -m 4096 -smp 2 --enable-kvm -net user,hostfwd=tcp::10021-:22 -net nic
It mounts, and I get a shell and everything, but it loses connectivity. In qemu, it logs :
[FAILED] Failed to start Raise network interfaces.
See 'systemctl status networking.service' for details.
Can someone guide me on this ? I already consulted Linux vanilla kernel on QEMU and networking with eth0 but it does not solve my issue. Also, Im not looking for hardcore qemu-bridge-solutions. Im pretty sure some network drivers are not getting loaded , but I can't figure out how to resolve it. Or maybe Im missing some kernel .config options.
linux networking linux-kernel kernel qemu
linux networking linux-kernel kernel qemu
asked Nov 8 at 0:16
GreatPoseidon_11
82
82
add a comment |
add a comment |
1 Answer
1
active
oldest
votes
up vote
0
down vote
accepted
You are using a user socket. For this qemu creates a regular socket in its host process and forwards the packets for specific ports in your guest machine to the host socket. It is doable but I find it annoying.
I always prefer creating a tap device and bridging it to my physical interface with these QEMU switches:
-netdev tap,ifname=tap0,script=no,downscript=no,id=my_net_id
-device driver=virtio-net,netdev=my_net_id
This way you have full network capabilities and you don't need to use some weird port redirection.
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
add a comment |
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
up vote
0
down vote
accepted
You are using a user socket. For this qemu creates a regular socket in its host process and forwards the packets for specific ports in your guest machine to the host socket. It is doable but I find it annoying.
I always prefer creating a tap device and bridging it to my physical interface with these QEMU switches:
-netdev tap,ifname=tap0,script=no,downscript=no,id=my_net_id
-device driver=virtio-net,netdev=my_net_id
This way you have full network capabilities and you don't need to use some weird port redirection.
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
add a comment |
up vote
0
down vote
accepted
You are using a user socket. For this qemu creates a regular socket in its host process and forwards the packets for specific ports in your guest machine to the host socket. It is doable but I find it annoying.
I always prefer creating a tap device and bridging it to my physical interface with these QEMU switches:
-netdev tap,ifname=tap0,script=no,downscript=no,id=my_net_id
-device driver=virtio-net,netdev=my_net_id
This way you have full network capabilities and you don't need to use some weird port redirection.
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
add a comment |
up vote
0
down vote
accepted
up vote
0
down vote
accepted
You are using a user socket. For this qemu creates a regular socket in its host process and forwards the packets for specific ports in your guest machine to the host socket. It is doable but I find it annoying.
I always prefer creating a tap device and bridging it to my physical interface with these QEMU switches:
-netdev tap,ifname=tap0,script=no,downscript=no,id=my_net_id
-device driver=virtio-net,netdev=my_net_id
This way you have full network capabilities and you don't need to use some weird port redirection.
You are using a user socket. For this qemu creates a regular socket in its host process and forwards the packets for specific ports in your guest machine to the host socket. It is doable but I find it annoying.
I always prefer creating a tap device and bridging it to my physical interface with these QEMU switches:
-netdev tap,ifname=tap0,script=no,downscript=no,id=my_net_id
-device driver=virtio-net,netdev=my_net_id
This way you have full network capabilities and you don't need to use some weird port redirection.
answered Nov 8 at 12:41
Knightingale
1115
1115
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
add a comment |
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
Many thanks, while I did not actually use this technique, I googled about it, and how to setup tap0 on bridge, and came across a command called "dhclient", apparently running it allows the vm to reconnect to the network drivers (probably) , and it ups the network interface .
– GreatPoseidon_11
Nov 10 at 16:53
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Some of your past answers have not been well-received, and you're in danger of being blocked from answering.
Please pay close attention to the following guidance:
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53199827%2fmy-newly-compiled-kernel-loses-networking-in-qemu%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown