Can't SSH to Ubuntu guest

Discussions related to using VirtualBox on Windows hosts.
Post Reply
keith73
Posts: 15
Joined: 3. Feb 2013, 21:54
Primary OS: MS Windows 7
VBox Version: OSE other
Guest OSses: Ubuntu 12
Location: New York, NY

Can't SSH to Ubuntu guest

Post by keith73 »

I have a Windows 7 host and Ubuntu Server 12 guest and everything in the guest works fine on one computer but not on another.
I exported the guest from laptop #1 and then imported it on laptop #2. Both laptops are Win7 64-bit.
On laptop #1 everything runs fine and I can access the web server in a browser and ssh into the guest from the host.
On laptop #2 it runs but I can't ssh to the guest or access the web server.
Do I need to change the advanced settings in the Adapter?
Is this a problem with DHCP?
Network configs tend to baffle me a bit.

Relevant stats:
Host: Windows7 64bit
Virtualbox 4.2.6
My home network is Verizon Fios accessing via Wireless from the laptop.

Guest: Ubuntu Server 12.04
Network: Host-only Adapter
sshd is running
ifconfig -a
eth0 Link encap:Ethernet HWaddr 08:00:27:f9:14:83
inet addr:192.168.56.101 Bcast:192.168.56.255 Mask:255.255.255.0
inet6 addr: fe80::a00:27ff:fef9:1483/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:146 errors:0 dropped:0 overruns:0 frame:0
TX packets:56 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:23660 (23.6 KB) TX bytes:8661 (8.6 KB)
Interrupt:19 Base address:0xd020

lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
inet6 addr: ::1/128 Scope:Host
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:8 errors:0 dropped:0 overruns:0 frame:0
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:480 (480.0 B) TX bytes:480 (480.0 B)


Vbox Runtime Attributes
Screen Resolution 640x480x32
Clipboard Mode Bidirectional
Drag'n'Drop Mode Disabled
VT-x/AMD-V Disabled
Nested Paging Disabled
Guest Additions 4.1.18 r78361
Guest OS Type Linux 2.6
Remote Desktop Server Port Not Available

Storage Statistics
Controller: IDE Controller
  IDE Secondary Master:
    DMA Transfers 1
    PIO Transfers 404
    Data Read 0 B
    Data Written 0 B

Controller: SATA Controller
  SATA Port 0:
    DMA Transfers 7357
    Data Read 172,552,192 B
    Data Written 5,917,696 B

Network Statistics
Adapter 1
  Data Transmitted 8,122 B
  Data Received 15,987 B
keith73
Posts: 15
Joined: 3. Feb 2013, 21:54
Primary OS: MS Windows 7
VBox Version: OSE other
Guest OSses: Ubuntu 12
Location: New York, NY

Re: Can't SSH to Ubuntu guest

Post by keith73 »

Ok, switching to Bridged Adapter worked for SSH. I thought bridged wasn't working because I can't access the web server on the vbox machine. Turns out it might be Verizon Fios blocking the port. I'm trying to mess with port forwarding on the router and still not working.
keith73
Posts: 15
Joined: 3. Feb 2013, 21:54
Primary OS: MS Windows 7
VBox Version: OSE other
Guest OSses: Ubuntu 12
Location: New York, NY

Re: Can't SSH to Ubuntu guest

Post by keith73 »

All good now. there was some PEBKAC on my part. thanks for listening, I just needed to think out loud I guess.
mfort
Posts: 1
Joined: 5. Feb 2013, 11:15

Re: Can't SSH to Ubuntu guest

Post by mfort »

Hi, I had similar problem with NAT and I found simple solution. In VirtualBox settings > Network > Port Forwarding I added new rule SSH TCP (empty IP) 2222 10.0.2.15 22. Immediately remote SSH connection to localhost:2222 works.
Post Reply