cURL/telnet connections refused on guest

Discussions related to using VirtualBox on Linux hosts.
Post Reply
csmadden
Posts: 3
Joined: 24. May 2016, 17:59

cURL/telnet connections refused on guest

Post by csmadden »

Host:
  • OS: Ubuntu 15.10, x64
  • RAM: 8GB
Guest:
  • OS: Windows 7 - IE 11 OVA(from MS's VM page), 32-bit
  • RAM: 1GB

Every time I try to cURL or telnet to my guest machine it tells me I get a connection refused error. Here's the exact response:

Code: Select all

C:\>telnet localhost 80
Connecting To localhost...Could not open connection to the host, on port 80: Con
nect failed

C:\>telnet localhost 80
Connecting To localhost...Could not open connection to the host, on port 80: Con
nect failed

<insert cURL attempt to localhost>
curl: (7) Failed to connect to localhost port 80: Connection refused

Forum rules won't let me post "URLs" so just assume that I did something that looks like this before the cURL request failed: "curl -v -i h.t.t.p.:././.localhost.:.80", I've also tried using the machine's actual IP(192.168.1.6). They all give me the same exact response. I can't curl/telnet from the host machine, either. Same error message. I've tried using NAT, Bridged Connection, and Host Only. The firewall is off, set to a home network, I've tried running VB as root, and I've restarted the VM and host machine a couple times since I started trying.

Thanks!

Forum isn't letting me upload my VB log file, it's taking me to an error page whenever I click "Add the file" but I'll keep trying...

...

Still not working. Getting "Site cannot be reached, may have moved blah blah" error message when I try to upload.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: cURL/telnet connections refused on guest

Post by socratis »

First of all, if you're trying to 'telnet localhost' from the host to your guest, that's the wrong address. Localhost is ... localhost, i.e. the "machine" that you're typing the commands from. If you're trying it from the guest, take a look at the next point.

Second, does your guest run a telnet server or an http server? If not, nobody is listening, therefore the connection will be refused. Nobody's home. In any event, if you're simply trying 'telnet' and 'curl' from within your Win7 guest, networking has absolutely nothing to do with it. You could remove all networking and it would work, if it was setup correctly (the telnet/http server that is).
csmadden wrote:I've tried running VB as root
DON'T DO THAT! You won't see other users' VMs, including your own.
csmadden wrote:Forum isn't letting me upload my VB log file
Maybe there was a temporary network glitch. But for future reference, please ZIP the log before uploading it. You would be saving a digital tree ;) .
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
csmadden
Posts: 3
Joined: 24. May 2016, 17:59

Re: cURL/telnet connections refused on guest

Post by csmadden »

First of all, if you're trying to 'telnet localhost' from the host to your guest, that's the wrong address. Localhost is ... localhost, i.e. the "machine" that you're typing the commands from. If you're trying it from the guest, take a look at the next point.
Not the case, trying from guest.
DON'T DO THAT! You won't see other users' VMs, including your own
Thanks for the advice, not relevant in this situation(I don't think), but I'll keep it in mind for the future.
Second, does your guest run a telnet server or an h.t.t.p server? If not, nobody is listening, therefore the connection will be refused. Nobody's home. In any event, if you're simply trying 'telnet' and 'curl' from within your Win7 guest, networking has absolutely nothing to do with it. You could remove all networking and it would work, if it was setup correctly.
Great question! When I enabled the telnet client I didn't enable the server, but I just tried(and rebooted) but getting the same error.

I managed to upload the log this time, though.
Attachments
log.zip
log
(15.13 KiB) Downloaded 10 times
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: cURL/telnet connections refused on guest

Post by socratis »

csmadden wrote:Not the case, trying from guest.
Then I'm afraid it is not a VirtualBox or networking question, it is simply a Windows installation and configuration question. You might have better luck if you point your queries to more Windows focused groups. I would simply search for "How to enable telnet server for Windows 7".
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
csmadden
Posts: 3
Joined: 24. May 2016, 17:59

Re: cURL/telnet connections refused on guest

Post by csmadden »

Bummer. At least that narrows my search a little. Thanks anyway.
Post Reply