NGINX refused to connect localhost on CentOS VM












0















I am running Centos7 on a VM as a guesthost on a MAC. I have followed the following tutorial



https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-centos-7



I have two network adapters running one NAT and the other is the host only adapter which have the following settings:



NAT Adapter



TYPE=Ethernet
PROXY_METHOD=none
BROWSER_ONLY=no
BOOTPROTO=dhcp
DEFROUTE=yes
IPV4_FAILURE_FATAL=no
IPV6INIT=yes
IPV6_AUTOCONF=yes
IPV6_DEFROUTE=yes
IPV6_FAILURE_FATAL=no
IPV6_ADDR_GEN_MODE=stable-privacy
NAME=enp0s3
UUID=a81126f4-7714-442d-91e0-0f4032512efb
DEVICE=enp0s3
DNS1=8.8.8.8
DNS2=8.8.4.4
ONBOOT=yes


Host Only Adapter



TYPE=Ethernet
BOOTPROTO=static
DEVICE=enp0s8
IPADDR=192.168.56.2
NETMASK=255.255.255.0
ONBOOT=yes
USERCTL=no
NM_CONTROLLED=no
DNS1=8.8.8.8
DNS2=8.8.4.4


So when I try to connect to my NGINX webpage by going on http://192.168.63.2 on my main system it states connection is refused.










share|improve this question



























    0















    I am running Centos7 on a VM as a guesthost on a MAC. I have followed the following tutorial



    https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-centos-7



    I have two network adapters running one NAT and the other is the host only adapter which have the following settings:



    NAT Adapter



    TYPE=Ethernet
    PROXY_METHOD=none
    BROWSER_ONLY=no
    BOOTPROTO=dhcp
    DEFROUTE=yes
    IPV4_FAILURE_FATAL=no
    IPV6INIT=yes
    IPV6_AUTOCONF=yes
    IPV6_DEFROUTE=yes
    IPV6_FAILURE_FATAL=no
    IPV6_ADDR_GEN_MODE=stable-privacy
    NAME=enp0s3
    UUID=a81126f4-7714-442d-91e0-0f4032512efb
    DEVICE=enp0s3
    DNS1=8.8.8.8
    DNS2=8.8.4.4
    ONBOOT=yes


    Host Only Adapter



    TYPE=Ethernet
    BOOTPROTO=static
    DEVICE=enp0s8
    IPADDR=192.168.56.2
    NETMASK=255.255.255.0
    ONBOOT=yes
    USERCTL=no
    NM_CONTROLLED=no
    DNS1=8.8.8.8
    DNS2=8.8.4.4


    So when I try to connect to my NGINX webpage by going on http://192.168.63.2 on my main system it states connection is refused.










    share|improve this question

























      0












      0








      0








      I am running Centos7 on a VM as a guesthost on a MAC. I have followed the following tutorial



      https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-centos-7



      I have two network adapters running one NAT and the other is the host only adapter which have the following settings:



      NAT Adapter



      TYPE=Ethernet
      PROXY_METHOD=none
      BROWSER_ONLY=no
      BOOTPROTO=dhcp
      DEFROUTE=yes
      IPV4_FAILURE_FATAL=no
      IPV6INIT=yes
      IPV6_AUTOCONF=yes
      IPV6_DEFROUTE=yes
      IPV6_FAILURE_FATAL=no
      IPV6_ADDR_GEN_MODE=stable-privacy
      NAME=enp0s3
      UUID=a81126f4-7714-442d-91e0-0f4032512efb
      DEVICE=enp0s3
      DNS1=8.8.8.8
      DNS2=8.8.4.4
      ONBOOT=yes


      Host Only Adapter



      TYPE=Ethernet
      BOOTPROTO=static
      DEVICE=enp0s8
      IPADDR=192.168.56.2
      NETMASK=255.255.255.0
      ONBOOT=yes
      USERCTL=no
      NM_CONTROLLED=no
      DNS1=8.8.8.8
      DNS2=8.8.4.4


      So when I try to connect to my NGINX webpage by going on http://192.168.63.2 on my main system it states connection is refused.










      share|improve this question














      I am running Centos7 on a VM as a guesthost on a MAC. I have followed the following tutorial



      https://www.digitalocean.com/community/tutorials/how-to-install-nginx-on-centos-7



      I have two network adapters running one NAT and the other is the host only adapter which have the following settings:



      NAT Adapter



      TYPE=Ethernet
      PROXY_METHOD=none
      BROWSER_ONLY=no
      BOOTPROTO=dhcp
      DEFROUTE=yes
      IPV4_FAILURE_FATAL=no
      IPV6INIT=yes
      IPV6_AUTOCONF=yes
      IPV6_DEFROUTE=yes
      IPV6_FAILURE_FATAL=no
      IPV6_ADDR_GEN_MODE=stable-privacy
      NAME=enp0s3
      UUID=a81126f4-7714-442d-91e0-0f4032512efb
      DEVICE=enp0s3
      DNS1=8.8.8.8
      DNS2=8.8.4.4
      ONBOOT=yes


      Host Only Adapter



      TYPE=Ethernet
      BOOTPROTO=static
      DEVICE=enp0s8
      IPADDR=192.168.56.2
      NETMASK=255.255.255.0
      ONBOOT=yes
      USERCTL=no
      NM_CONTROLLED=no
      DNS1=8.8.8.8
      DNS2=8.8.4.4


      So when I try to connect to my NGINX webpage by going on http://192.168.63.2 on my main system it states connection is refused.







      linux networking virtualbox centos






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Feb 13 at 10:28









      Nabil AzizNabil Aziz

      31




      31






















          1 Answer
          1






          active

          oldest

          votes


















          0














          I am hoping that you followed proper document ! Kindly check firewall connection. Use below command to check



          # systemctl status firewalld


          If it is running



          Kindly check below command check if 80 port or http services listed or not



          # firewall-cmd --list-all





          share|improve this answer
























          • I went through the firewall commands and it worked. thanks.

            – Nabil Aziz
            Feb 22 at 14:29











          Your Answer








          StackExchange.ready(function() {
          var channelOptions = {
          tags: "".split(" "),
          id: "3"
          };
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function() {
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled) {
          StackExchange.using("snippets", function() {
          createEditor();
          });
          }
          else {
          createEditor();
          }
          });

          function createEditor() {
          StackExchange.prepareEditor({
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader: {
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          },
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          });


          }
          });














          draft saved

          draft discarded


















          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1405208%2fnginx-refused-to-connect-localhost-on-centos-vm%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          0














          I am hoping that you followed proper document ! Kindly check firewall connection. Use below command to check



          # systemctl status firewalld


          If it is running



          Kindly check below command check if 80 port or http services listed or not



          # firewall-cmd --list-all





          share|improve this answer
























          • I went through the firewall commands and it worked. thanks.

            – Nabil Aziz
            Feb 22 at 14:29
















          0














          I am hoping that you followed proper document ! Kindly check firewall connection. Use below command to check



          # systemctl status firewalld


          If it is running



          Kindly check below command check if 80 port or http services listed or not



          # firewall-cmd --list-all





          share|improve this answer
























          • I went through the firewall commands and it worked. thanks.

            – Nabil Aziz
            Feb 22 at 14:29














          0












          0








          0







          I am hoping that you followed proper document ! Kindly check firewall connection. Use below command to check



          # systemctl status firewalld


          If it is running



          Kindly check below command check if 80 port or http services listed or not



          # firewall-cmd --list-all





          share|improve this answer













          I am hoping that you followed proper document ! Kindly check firewall connection. Use below command to check



          # systemctl status firewalld


          If it is running



          Kindly check below command check if 80 port or http services listed or not



          # firewall-cmd --list-all






          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered Feb 13 at 18:08









          bhupender singhbhupender singh

          242




          242













          • I went through the firewall commands and it worked. thanks.

            – Nabil Aziz
            Feb 22 at 14:29



















          • I went through the firewall commands and it worked. thanks.

            – Nabil Aziz
            Feb 22 at 14:29

















          I went through the firewall commands and it worked. thanks.

          – Nabil Aziz
          Feb 22 at 14:29





          I went through the firewall commands and it worked. thanks.

          – Nabil Aziz
          Feb 22 at 14:29


















          draft saved

          draft discarded




















































          Thanks for contributing an answer to Super User!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid



          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.


          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function () {
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fsuperuser.com%2fquestions%2f1405208%2fnginx-refused-to-connect-localhost-on-centos-vm%23new-answer', 'question_page');
          }
          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Probability when a professor distributes a quiz and homework assignment to a class of n students.

          Aardman Animations

          Are they similar matrix