Error:ERR_NAME_NOT_RESOLVED


  • | 343 points

    HI, i'm working on a Laravel project with laragon, before i could access by typing "myapp.test" in URL bar. I made some modifications on hosts file which is inside the system32 folder, so i can't access "myapp.test" anymore. I deleted the changes that i had added, but i still do not have access. Even the line 127.0.0.1 "myapp.test" is still on hosts file.


  • | 343 points

    @Alberto said in Error:ERR_NAME_NOT_RESOLVED:

    HI, i'm working on a Laravel project with laragon, before i could access by typing "myapp.test" in URL bar. I made some modifications on hosts file which is inside the system32 folder, so i can't access "myapp.test" anymore. I deleted the changes that i had added, but i still do not have access. Even the line 127.0.0.1 "myapp.test" is still on hosts file. Thank you very much!!!


  • administrators
    | 111240 points

    @Alberto : Can you check if your hosts file is not corrupted by typing?:

    ping myapp.test
    

  • | 343 points

    @leokhoa said in Error:ERR_NAME_NOT_RESOLVED:

    @Alberto : Can you check if your hosts file is not corrupted by typing?:

    ping myapp.test
    

    I just tried it, the ping request didn't find myapp.test host.


  • administrators
    | 111240 points

    @Alberto : So you hosts file is corrupted. Please try:

    1. Backup your hosts file
    2. Clean all the content
    3. Click "Start All/Stop" so Laragon will generate new hosts entries
    4. Test ping again

  • | 343 points

    @leokhoa said in Error:ERR_NAME_NOT_RESOLVED:

    @Alberto : So you hosts file is corrupted. Please try:

    1. Backup your hosts file
    2. Clean all the content
    3. Click "Start All/Stop" so Laragon will generate new hosts entries
    4. Test ping again
      I followed the indications, Laragon generated hosts entries but it didn´t work.

  • | 1336 points

    I experienced the same issue and realized that I also needed to delete the auto config file for the domain I was having issues with in the apache2 folder.

    This is what I did to resolve the issue:

    1. Go to C:\laragon\etc\apache2\sites-enabled

    2. Delete the auto.your-domain-name.test.conf file.

    3. Restart Laragon or click the Stop / Start button twice.

    4. Go back to C:\laragon\www and create a new folder with the same domain name.

    5. CD into the folder, create an index.php file, and write a simple echo statement like so:

      <?php echo 'Hello world!';

    6. Restart Laragon again and try visiting your test domain once more.


Log in to reply
 

Looks like your connection to Laragon was lost, please wait while we try to reconnect.