bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: CentOS Stream installation


From: Bruno Haible
Subject: Re: CentOS Stream installation
Date: Sun, 05 Feb 2023 23:46:44 +0100

Paul Smith wrote:
> How many CPUs did you give to the VM?  It shouldn't matter since we're
> doing multiprocessing here but... maybe...?  I was using 4G RAM and 4
> CPUs in my guest.

I am using 1 CPU in that VM.

> > I never install the VirtualBox guest additions. The downside is that
> > sharing data is less comfortable (I use 'scp' each time), and that
> > the mouse handling is a bit more annoying.
> 
> The problem is that I can't seem to open connections from my host
> machine to the guest machine: my host machine can't find the guests via
> any IP address I can come up with.

Yes, by default, in VirtualBox, you only have connectivity from the guest
to the host. For connectivity from the host to the guest, there appear to
be two approaches:
  - Give each guest a distinct IP address (means: list the guests in your
    LAN's DHCP server), and choose a "bridged" network adapter for each
    VM. Note: In my experience (with older versions of VirtualBox) this
    works fine when the host has an Ethernet network card, but not with
    a Wi-Fi network adapter.
  - Use the "Advanced > Port forwarding" setting, even with a "NAT" network
    adapter. The host port number must be > 1024.
Web searches for "virtualbox ssh into vm" or "virtualbox ssh from host to guest"
give some pointers.

Also, don't forget that many guest OSes have a built-in firewall. If from
within the guest VM, "ssh localhost" works but from the host, ssh to the VM
never responds, then this is the problem. In this case, you will need to "open"
the port 22 there. For older Linux distro the command to do it is
  sudo iptables -I INPUT -p tcp -m tcp --dport 22 -j ACCEPT
For CentOS 8 probably something like
  sudo nft add rule inet firewalld filter_IN_public_allow tcp dport 22 accept

> And normally I don't have an SSH server running on my host machine,
> since I don't need to log into it from anywhere and it's more secure
> that way

Yeah, everyone has different preferences. Leading to different network
topologies in each case.

Bruno






reply via email to

[Prev in Thread] Current Thread [Next in Thread]