Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Used bridge networking to provide ip to qemu kvm guest vm through packer, but getting SSH ip/port failed: dial tcp 10.0.0.8:22: connect: connection #12625

Closed
pravinjec opened this issue Sep 15, 2023 · 3 comments

Comments

@pravinjec
Copy link

pravinjec commented Sep 15, 2023

Used net_bridge: br0 in json file to connect with br0 bridge , with nat it is working fine, but want to create multiple guest vm through packer and with default nat all the guest vm getting same ip. But i want different ip for all the guest vm.
If there is way with nat network to provide different ip to guest vm's then please let me know that as well, else please help me to fix this issue. There is not much information on internet about bridge networking issue

Also when build starts tap interfaces are getting created for bridge.

==> qemu.aux-node: Waiting for the guest address to become available in the br0 network bridge...
2023/09/15 06:39:11 packer-builder-qemu plugin: Found guest address 10.0.0.8
==> qemu.aux-node: Using SSH communicator to connect: 10.0.0.8
2023/09/15 06:39:11 packer-builder-qemu plugin: [INFO] Waiting for SSH, up to timeout: 20m0s
==> qemu.aux-node: Waiting for SSH to become available...
2023/09/15 06:39:11 packer-builder-qemu plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 10.0.0.8:22: connect: connection
refused
2023/09/15 06:39:16 packer-builder-qemu plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 10.0.0.8:22: connect: connection
refused

After sometime in place of connection refused getting no route to host

2023/09/15 07:17:11 packer-builder-qemu plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 10.0.0.8:22: connect: no route to
host
2023/09/15 07:17:14 packer-builder-qemu plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 10.0.0.8:22: connect: no route to
host
2023/09/15 07:17:17 packer-builder-qemu plugin: [DEBUG] TCP connection to SSH ip/port failed: dial tcp 10.0.0.8:22: connect: no route to
host

@pravinjec pravinjec changed the title Used bridge networking to provide ip to guest vm through packer, but getting SSH ip/port failed: dial tcp 10.0.0.8:22: connect: connection Used bridge networking to provide ip to qemu kvm guest vm through packer, but getting SSH ip/port failed: dial tcp 10.0.0.8:22: connect: connection Sep 15, 2023
@pravinjec
Copy link
Author

I have tried using nats to provide different ip to different vm by adding mac address with static ip in the default.xml file. But still same ip is getting assigned, Can anyone please help me into it

@lbajolet-hashicorp
Copy link
Contributor

Hi @pravinjec,

This issue tracker is for us maintainers to keep track of the community-reported shortcomings with Packer itself, for asking more general usage questions, please use our Discuss forum, where other members of the community tend to be active and may help you with your issue.

Since this issue is a usage question and not a bug or a feature request with Packer, I'll close this now, feel free to reopen if I misinterpreted the issue at hand.

Thanks

Copy link

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.
If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 13, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants