Jump to content
Sign in to follow this  
support

How to troubleshoot Passwordstate website not loading

Recommended Posts

Purpose:

Passwordstate is a self hosted website and if everything is not set correctly then your website can become unavailable.  This forum post describes a few things you can check to get your website back up and running again.

 

Things to note:

This forum post assumes you are not using the High Availability module for Passwordstate, and you only have a single website to troubleshoot.

 

Passwordstate structure:

Passwordstate is a self hosted website that can be installed on any Windows machine, and it uses IIS (Internet Information Services) web server software to  host the website.  The website sends and receives data to a SQL database.  This database can be installed on the same server, or on a separate server if required.

 

In your installation directory, which by default is c:\inetpub\passwordstate, you will find a file called web.config. In this file, is a "Connection String" and an "Application Settings" section, both are important to have set correctly for your website to work.  An explanation of these web.config file components is below:

 

Connection String:

This section of the web.config file tells your website what server your database is installed on, and which credentials to connect to the database to.

 

1. Data Source is your web sever name, and if applicable, your SQL instance.  In the screenshot below we use the default instance so we omit it in the connection string.  If you did have a custom SQL Instance, this section should be in the format of <SQL database server name>\<SQL instance name>

2. This is the name of your database

3. The SQL username which has db_owner permissions to your Passwordstate database

4. The password for this SQL user

 

2019-09-23_11-20-01.png

 

Application Settings:

The application settings section has a few different components with explanations of these below:

 

1. SetupStage: After installing Passwordstate this value will change to "Setup Complete".  This setting should never change unless you are in the process of installing the Passordstate software

2. PassiveNode: This value determines hos your website will behave, either in read/write mode or just read mode.  This is only used if you have the High Availability module and are running 2 Passwordstate websites.  This value should always be "False"

3. Secret 1 and Secret 2: Passwordstate has built in encryption keys which protect your data.  Half of these keys reside in the AppSettings section of your web.cconfig file, the second half are located inside your database.  When you log into your Passwordstate website, the code behind the scenes will join these encryption keys, which in turn decrypts any information in the database which only you can see. If these keys do not match, then your website will not load.

4. GUID1: This value stores your authorized web server name which can be found under Administration -> Authorized Web Servers.  This is a security feature of Passwordstate and if the value in this field does not match the DNS name of the server where you have Passwordstate installed, then you will be prompted for your Emergency Password.

 

2019-09-23_11-20-01a.png

 

How to find your URL and Port Number:

Open IIS on your Passwordstate web server by going to start button -> Run and typing in inetmgr.exe.  Click on your Passwordstate website and then select Bindings.  Your URL will consist of three things:

 

1. A protocol, which is either http or https

2. A Host Name which can be anything you like.  By default it will be set as the name of your Passwordstate server

3. A Port number

 

In the example below, my binding is https://webserver02:9119

 

2019-09-23_12-58-01.png

 

 

Web Site Errors:

When browsing to Passwordstate, there are many types of errors that you could potentially get, all depending on which information is not set correctly.  Below are the most common errors and how to troubleshoot them.  The website URL we'll be testing these on is https://webserver02:9119

 

Error #1: "This site cannot be reached" (ERR_CONNECTION_REFUSED)

2019-09-23_12-08-33.png

 

Steps to Troubleshoot:

1. Ensure you are typing in the correct URL including having the port number appended to the URL.  example is https://webserver02:9119.  Port 443 is the only port that does not need to be appended to the URL as IIS treats this port as as the default for all HTTPS traffic.

2. Open IIS on your web server, and make sure your Passwordstate website is started. If it is stopped you will see a black stop button on the website in IIS. See screenshot below to start the website again:

2019-09-23_13-18-32.png

3. Ensure there is no firewall blocking access to the website by performing a port test from your desktop computer to the passwordstate URL.  Below is an example test you can run in Powershell:

 

test-netconnection webserver02 -port 9119

 

You should get a successful result like this if nothing is blocking access:

2019-09-23_13-04-28.png

 

 

Error #2: "Database Connectivity Error"

2019-09-23_13-23-51.png

 

Steps to Troubleshoot:

This error means that your website settings in IIS are ok, but for some reason the website cannot communicate to the database.  Some suggestions to troubleshoot this are:

 

1. In the c:\inetpub\passworddstate\web.config file, check that the Database server and SQL instance are set correctly in the connection string

2. Take note of the database server and SQL instance, and the username and in the connection string in the web.config.  Use those credentials to try to establish a connect to the database server using SQL management Studio Tools.  If everything is correct you will be able to establish a connection.  Possibly you will need to reset the password for the account in SQL on your database server to match what you have in your web.config file

 

 

 

Error #3: "Secret Key Issue":

2019-09-23_14-03-23.png

 

Steps to Troubleshoot:

You will generally see this error if you have done something wrong during an upgrade or a move of your Passwordstate website.  The secrets in the web.config file must match the keys in the database, and sometimes these can get out of sync if you copy the wrong keys across or restore an older version of the database etc.. Try to locate a different web.config file with another set of keys in them, possibly in a backup or on another server where you have previously had Passwordstate installed.  Insert the new keys into the AppSettings section of the web.config file and if they match, the website will display as per normal.

2019-09-23_11-20-01a.png

 

 

Error #4: "This Site can't be reached" (DNS_PROBE_FINISHED_NXDOMAIN)

2019-09-23_14-15-50.png

 

Steps to Troubleshoot:

 

1. Perform an nslookup on your URL, by opening a command prompt and entering the following command, assuming your URL is https://webserver02:9119.  There's no need to enter the https protocol nor the port number when doing this test:

 

nslookup webserver02

 

If this nslookup fails you should:

  • Check you are typing in the correct URL with no spelling mistakes
  • Check your DNS entry for your site is correct, and directing all traffic to your Paswordstate web server
  • Make sure are not using a hosts file for your DNS entry.  If you haven't already, create a new DNS entry in DNS Manager, which is a tool located on your DNS server, usually the domain controller. Example of DNS entry can be found in this forum post:  https://www.clickstudios.com.au/community/index.php?/topic/1465-changing-the-passwordstate-url/
  • If you are using Load Balancers or proxy servers, try to bypass these altogether as a test. To test this, create a new binding in IIS called "localhost", and assign port 443 to it for ease of use, and select your certificate.  Then log directly into your Passwordstate server and browse to https://localhost  and if your website displays then there is an issue with external systems that are not handling your URL and DNS properly.
    2019-09-23_14-38-54.png

 

 

Error 5:  HTTP Error 404. Page cannot be found

2019-10-09_8-18-38.png

 

Steps to Troubleshoot:

Ensure your binding in IIS is correct and is the exact text that you are entering into your browser to access the site.

 

Error 6: ERR_HTTP2_PROTOCOL_ERROR

2019-10-09_8-13-03.png

 

Steps to Troubleshoot:

This error can be caused by the Windows Process Activation Service (WAS) not being started.  Restart that service or reboot your web server and this should fix the issue.

 

 

We'll try to add more errors and fixes to this page as we find them.  If none of these suggestions help please log a support call with support@clickstudios.com.au

 

Regards,

Support.

 

 

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...