localhost resolve to old computer name - iis

I have recently changed my computer name.
Now when I want to access web server (IIS) on my computer https://127.0.0.1 resolves to new computer name, but if I write https://localhost resolves to my old computer name.
Web page does not work with old computer name.
What can I do so localhost will resolve to my new computer name?

#Lex Li pointed me to right direction.
I am using Siemens WinCC Unified runtime.
I removed the project and added it again. Now it resolves to my new computer name.

Related

Unable to host Blazor application

I am unable to get a Blazor app working while hosting the application as an IIS application on my local Windows 10 machine. The app is very simple, with just one page with minimal components - even simpler than the default Blazor app provided.
These are my steps:
Click on publish app
Select Folder, note it's going to ...\bin\Release\net5.0\browser-wasm\publish\
Open IIS, navigate to Default Web Site
Right-click Default Web Site and select Add Application
Select physical path as the path above, and host at www.NAME.com
Click Browse.. to view the app at www.NAME.com on *:80
Page displayed is the welcome page of IIS
Attempted Solution 1: Install URL Rewrite
Attempted Solution 2: Go to Hosts (in System32) and tried adding 127.0.0.1 or 127.0.0.1::80 followed by www.NAME.com
Attempted Solution 3: In index.html, edit the base element to include the link <base href="/NAME/" />
Attempted Solution 4: Instead of adding an application under Default Website in IIS, add it as a website instead
Attempted Solution 5: Gave IIS_IUSRS full permissions to web.config (Image)
None of the attempted solutions worked. I just started using Blazor yesterday and I am very new to this. Am I doing something wrong? Thank you!
Please refer to this tutorial, I think is one of the best tutorial to achieve your goals:
https://blog.medhat.ca/2020/08/deploy-client-side-blazor-web-api-to.html?m=1
Remember that the configuration of the hostname in your hosts file is related to your machine only
So, in order to allow the students to access your IIS published site you need:
Register a hostname in a DNS server that all the computer of the students will use to resolve your machine name. I.e. if your machine should be accessible with www.name.com you need your DNS server resolves this name with your local IP address
To use the https protocol you need a certificate on your local machine, loaded in your IIS configuration, but the same certificate has to be available to every computer of your students.
I think the better and simpler solution is to use your local machine name, probably using your full DNS name, and allows the students to access the site using this name on their browser.
In this case you can use your local development certificate to allow https connection
This certificate is already installed on your machine for development purpose.
Every concept I've described is well documented on the web and here on the SO.

ReInstall Sitecore IIS can't resolve host (with ERR_NAME_NOT_RESOLVED)

I decided to reinstall Sitecore 8 instance via wizard, I have removed instance and install a new one with the same name XYZ.
but after reinstall it I am getting an error in browser - ERR_NAME_NOT_RESOLVED
I checked IIS binding, I checked hosts file, reset DNS, restart PC and etc I still get this error in any browsers.
How I can fix it? What is the issue?
I have found solution https://support.microsoft.com/en-us/kb/2823477 but I can't understend how sitecore installer can change it.
Generally, the process of site resolution goes in the following consequence:
DNS - find ip address by the hostname (from request header)
Access IIS with that IP (and port if not default 80)
IIS checks bindings by hostname from header and serves corresponding website.
Website being resolved has (merged) web.config in root folder. It has node with all sites served by current Sitecore instance, being listed. Order does matter! First successful match (by hostname or port or default) works it out.
Site being found on previous step has startItem property which is your Sitecore item served by dafault.
Please go and carefully check all those steps to see where it breaks. Also I have previously write a blog post, you may find it helpful with more details on that:
http://blog.martinmiles.net/post/how-websites-are-resolved-with-sitecore
Do any sites work with a Local name configured in 'hosts'?
You may need to disable the Loopback Check in your tcpip stack. Windows uses this as a countermeasure for man in the middle attacks by default on many systems. A registry change is needed to allow a machine to refer to itself using a name that is not its own Hostname. Sorry, but I can't remember the actual key.

How would I use my domain on my windows server 2012?

I recently started a project of building a server at home and trying to host a website on it. I have almost everything setup and working correctly but only have one issue, I can't figure out how to use my domain with it. I've been searching the internet for a few days and everything I come across isn't very informative on how to do it. I'm very new to hosting my own servers and would love any help. Thanks in advanced.
I should also mention that I'm using Windows Server 2012 R2 and IIS 8. The computer has a static IP as well.
Not sure what you mean by use my domain but I am guessing if you go to the url it is not loading you site? If that is the case, have you registered you bomain with a provider (godaddy, namecheep, etc)? After that make sure your router is forwarding the ports needed to your computer. Lastly make sure that those ports are open on your firewall. Things to help debug issues is can you ping your domain and get your static IP, if not the issue is with your domain registration. If it tries to load the site and doesn't but the IP is good then the issue is between the provider and you computer more than likely.

404 not found on client website on Mac only - works on other computers, smartphones, tablets

I created a website based on wordpress with a custom theme setup. The live website renders fine on every computer, smartphone and tablet i've tried, except for my Mac, which I use as my local development machine. I have tried various browsers on my mac. The off-line development version renders fine.
When I visit the website http://www.redroselimos.com/ I get the following error:
Not Found
The requested URL / was not found on this server.
I suspect it is a DNS issue or perhaps a Mac configuration issue?
Mac OSX 10.7.4
Chrome 22.0.1229.79
MAMP PRO 2.0.5
DNS: 208.67.222.222/208.67.220.220 (openDNS)
If it shows up fine on every other machine then the site is validly there and it can only be a networking issue for your Mac. Most likely as it is your dev setup you have other settings in place. The 404 error means you are at least reaching a webserver, so you are getting out to the internet. There are a few things you can do:
You could check your /etc/hosts file to see if you send that domain to another IP - which would be my first suspicion.
Also check the httpd.conf on the server to see if you handle your dev machine's IP differently, or if it's rerouted in .htaccess.
You can also try tail -f /var/log/httpd/access_log or whatever your log file is and then try hitting it again from your Mac and see what comes through.
Try going through a proxy from your Mac to your site. proxify.com and hidemyass.com both work for this, that way you'll see if it's strictly an IP issue.
This should point out exactly what the error is.
I have Mac, Lion 10.7.5, Safari 6.0.1
no error. Surfed to the link you wrote, I can see the site (top left a form to login, center header a kind of gallery, some other stuff in the center)
I have no special configuration, only default. If you didn't change the configuration before that is not the problem. If you do, try to restore the default settings.
I think that is a problem with localhost, because you want to surf to your pc from the outside being inside. I don't see a valid reason to do that, if your mac is the host of the site you just need to surf to localhost.
By the way, there is an update to version 10.7.5 for Lion
What causes the Hosts File 404 Error in Mac OS X
The Hosts File is found on the user's computer machine. It is not found using the Search or Finder function. It is woven into the machine code.
The hosts file is used to map DOMAIN hostnames to IP NUMBER addresses. Example: MyDomain.com shown in browser is really a number on the internet 111.11.11.11
This map process is called "resolving" the browser alpha letter name into the numerical number address used by the internet.
Most hosts files do not have many entries because most browser name entries are resolved in DNS lookup tables provided to the user by the internet provider.
A hosts file can cause the local computer machine to present a 404 Cannot Find Page error. This is because a webpage domain entry is in the list that is wrong or it is out of date.
One day the domain entry was correctly shown to be 222.22.22.22 but really it has been changed to 333.33.33.33
Another computer machine will go to 333.33.33.33 without any problem because there is an up-to-date listing in the local machine's hosts file. Or there is not even an entry.
So, the local computer hosts file needs to correct the error. To stop the 404 error. This is done by editing the local machine's host file. The bad out-of-date entry needs to be is updated. Or the entry is needs to be completely removed from the hosts file.
If the entry is completely removed from the hosts file then the internet provider just sends the local computer machine to a internet DNS file to "resolve" the browser alpha letter entry into a numerical interet address
Instructions for editing the hosts file are here: How to Edit the Hosts File in Mac OS X with Terminal. Knowing how to use Terminal is required.

Setting the Hostname in IIS Bindings Breaks Website

I just got a Windows Server 2008 VPS and I'm having trouble getting IIS7 setup.
I created a new website in IIS with the path, ip address, and hostname (like 'www.nameofsite.com') and click OK. When I browse to the site it pulls up "http://www.nameofsite.com" in the browser and... nothing... IE cannot display this webpage.
If I blank out the hostname in the bindings and click [Browse] it works fine (it takes me to http://10.10.2.92 - the computer's ip). So entering the hostname breaks the website.
Any ideas on what I'm missing? Services I might not have running or roles I'm missing?
No server roles were initially installed on the VPS so I installed IIS, DHCP, DNS, and Application Server... overkill, but I wasn't sure what to install.
First it has to be in DNS or the client machines hosts file. To test this you can add the hostname to the servers hosts file.
Go to start -> run and type "drivers" change to the etc directory you want to edit the hosts file. The entries in it are like a local DNS. They only work on the local machine!
You must use EXTERNAL DNS not Internal DNS to make it visible across the internet. Change the DNS pointer at your registrar or whatever you are using for external DNS propagation.

Resources