I created a Fedora 20 virtual machine with VirtualBox 3.18.

I created a host-only network adapter for it, it has the ip address .

I ping that address from the host, it works.

I try to ssh into it, it does not work.

I get the following output from sudo firewall-cmd --list-all:

public (default, active)
  interfaces: p2p1, p7p1
  services: dhcpv6-client mdns ssh
  ports: 22/tcp
  masquerade: no
  rich rules

and ip addr shows that p7p1, which is the network adapter that has the MAC address of the VirtualBox host-only adapter, has only an ipv6 address.

When I ssh [email protected], my connection is refused. Might that p7p1 network interface not having an IPv4 address cause this problem? From the above firewalld output it seems that the port is open.

sshd is running.

  • What is your host range of IP Addresses? What does the ifconfig command return from inside the VM. Please update your question with that information.
    – eyoung100
    Oct 30, 2014 at 15:14

1 Answer 1


In a Host-Only environment, usually your host computer gets the address and all guests get addresses starting at This can be configured in the VirtualBox settings window. If you are trying to access the Fedora guest system, you probably want this:

ssh [email protected]

replace user with your username on the guest system (e.g. fedora). You should also make sure that the ssh daemon is running and your firewall is not blocking your port. You can test this from your host machine:

nmap -p 22

Assuming the guest is running an ssh server on port 22, this should tell you whether or not the port is open and whether or not it is being blocked by your firewall.

Also, VirtualBox can be kind of finicky about network interfaces attached to guest systems. If you are still having problems, try disconnecting all network interfaces except the host only network interface. Usually the guest system will ignore the host only network if you have nat configured.

  • Where can I find the address for the guest machine? does not work.
    – Gergely
    Oct 31, 2014 at 6:28
  • Never mind, the IPv6 address did work what ip addr did show. This was my first IPv6 address I ever used. Thanks for the above it did help.
    – Gergely
    Oct 31, 2014 at 6:51

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .