Score:0

Unable to connect to Linux Ubuntu Azure VM using public IP address

dk flag

Unable to connect to Linux Ubuntu Azure VM using public IP address.

I have tried everything.

  1. have 'ufw' active and allowed port 80
username@LinuxLR:\~$ sudo ufw status

Status: active

​

To                         Action      From

\--                         ------      ----

80                         ALLOW       Anywhere

443                        ALLOW       Anywhere

Nginx HTTP                 ALLOW       Anywhere

80 (v6)                    ALLOW       Anywhere (v6)

443 (v6)                   ALLOW       Anywhere (v6)

Nginx HTTP (v6)            ALLOW       Anywhere (v6)

  1. done something I found about hard-enabling traffic on port 80

sudo iptables -I INPUT -p tcp -m tcp --dport 80 -j ACCEPT

  1. tested with local host. "curl localhost" grabs the html on the page. "curl public ip address" doesn't give a response. Literally nothing happens.

username@LinuxLR:\~$ curl http://127.0.0.1/


<html>

<head>

<title>Welcome to nginx!</title>

<style>

body {

width: 35em;

margin: 0 auto;

font-family: Tahoma, Verdana, Arial, sans-serif;

}

</style>

</head>

<body>

<h1>Welcome to nginx!</h1>

<p>If you see this page, the nginx web server is successfully installed and

working. Further configuration is required.</p>


<p>For online documentation and support please refer to

<a href="[http://nginx.org/](http://nginx.org/)">nginx.org</a>.<br/>

Commercial support is available at

<a href="[http://nginx.com/](http://nginx.com/)">nginx.com</a>.</p>


<p><em>Thank you for using nginx.</em></p>

</body>

</html>```


4. Similar thing with wget. "wget localhost" grabs the usual nginx html page. "wget public ip address" does:

```username@LinuxLR:\~$ wget "public ip address"

\--2022-10-19 19:40:43--  "public ip address"

Connecting to "public ip address"... failed: Connection timed out.

Retrying.
David avatar
cn flag
I see you allowed IP 6 but you are trying to use IP 4?
user9681173 avatar
dk flag
I don't understand the difference between them. In what way am I trying to use IP 4 instead of IP 6?
David avatar
cn flag
username@LinuxLR:\~$ curl http://127.0.0.1/ An IP 4 address. I suggest you do some research on what IP 4 and 6 are and the differences. You have specified IP 6 in the UFW rules without understanding what IP 6 is?
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.