Have an idea?

Visit Sawtooth Software Feedback to share your ideas on how we can improve our products.

Sawtooth Error # 199

What is error 199 trying to tell me?

I get this error when I try to login to the survey with the URL.  For example, mycompany.com/survey1/login.html

When I try to use the admin login via the URL, I get invalid user name or password try again message.   For example, mycompany.com/survey1/admin.html

I get the invalid user name or password right away if I try to use the admin module within Sawtooth.
I checked and checked again the password set on the Admin Module tab under Web Server Management.

I'm using version 8.3.10 connecting to a MS SQL server 2014 Express database
I have the following installed:
SSI Web version 8_3_10
Perl version 5.020001
Perl Module - DBI version 1.633
Perl Module - DBD::ODBC version 1.52
Perl Module - DBD::SQLite version 1.42
asked Apr 30, 2015 by Greg Bronze (910 points)
retagged Apr 30, 2015 by Walter Williams

2 Answers

+1 vote
Greg, error #199 means that the admin module and survey aren't able to communicate with the database. The settings are wrong either in the survey's configuration (database connection settings) or something is wrong with the database, like it's unreachable or the user hasn't been configured, or the database doesn't exist.

I would recommend changing the admin module passwords to something that you can easily type in and try again through the website.

If you are using Linux, you need to make sure that your permissions are correct when you first upload. (Though using our Self Hosting upload section in SSI Web should be taking care of that for you)

Are you using your own hosting system, or are you hosting with us?
answered May 1, 2015 by Jonathan Huff Bronze (1,575 points)
Hi Jonathan, thanks for replying back.  We are doing our own hosting for now.  The University will not allow us to store PHI and other types of data outside the University at this time.

I changed the passwords on the admin module to an easy password and I’m still getting the error (Invalid user name or password).  I do have a database and user created in the MS SQL.  I am wondering if I have the correct security privileges set for the user in MS SQL.  I’ll check on this again.

We are using Windows 2012 server and IIS 8.5 for the web site.

Do you know when the tables in the database get created?  After I login to the admin module and set the survey?

The tables are not getting created which tells me the same thing you are telling me and that is there is a connection problem to the database. Reading through the setup notes and the forum, I wonder if the problem is with the Perl drivers for connecting to the database.  I was trying to find a way to test the connection with the Perl drivers until I got your reply.  

Under the Advanced Server Configuration, I have the IP address in the Database Server Host Name, the port number listed, but I didn't add a custom database driver.  Do I need to add the Perl driver in there?
The survey setup is completed by the Admin module when you first successfully authenticate to the admin module with read/write permissions. If you can't authenticate, then your survey won't get set up!

Once you've been able to get in to the admin module, the admin module will give you a report on whether it was successful or not, and could give you some solid clues as to what went wrong, if anything did, like if the Perl version is correct, if it can find the database libraries it needs or not, or if the DB credentials it has are working. Otherwise it will let you know that everything worked.

Since you're having trouble authenticating, I'd look there first. It sounds like the perl scripts might not be able to read and write in the /admin directory, which is where the admin config files are (including database settings) stored.

You can confirm this:
  - try accessing the survey (using the login.html page). You should get an error.
  - Check to see if there is an error_log.txt file in the /admin directory detailing the error.
  - If you see the error log file, it probably isn't the permissions(not sure what it would be then). If you don't see the error log file, then the problem isn't that your credentials are wrong, it's probably that the Admin module Perl script can't read/write in the directory it needs to.
  - Consult the documentation here to help get the permissions straight:
      - http://www.sawtoothsoftware.com/serversetup
          --> Server Side Documentation for SSI Web version 8.X.X
             --> Microsoft Windows IIS Server Setup Documentation
               --> Configuring IIS

If you're using MySQL, as long as you select that in the setup, it should be attempting to use the correct database driver.  It might be that it *can* connect to the database, but the user doesn't have the permissions it needs. I'd wait to look at that, because getting the admin module to work will really help diagnose where to start if there is a problem with the database location/name/password/whatever.
I get an error when I try to login with the login.html page and I didn’t see the error_log.txt file in the /admin directory.  This tells me that my permissions on the survey folder are not correct.

I checked the permissions on the folder and it looks right to me but I must have missed something.  I’m going back through the documents you listed to see if I can find what I missed in the setup process.  

Little by little it is making sense to me.
I want to thank Jonathan for helping me get the survey setup with MS SQL.  The problem was a permission setting on the directory where the survey files are saved (/admin, etc).  Once that was fixed, everything worked.  

Thanks again Jonathan for helping me out and pointing me in the right direction for the fix.

0 votes
I'd like to add, that I run into the same problem and a different cause.

Sometime this year, Sawtooth Hosting changed the Server Settings requirements and introduced a new parameter "Database Host (Advanced)" (to be found in your Sawtooth hosting project under "Server Settings").

In SSI Web 8.4 this parameter needs to be changed in "Web Server Management" and "Self Hosting" under the "Advanced" Button. There it has the name "Database Server Host Name" and the default is

The point is, that in the past I never had to change this parameter, so it took me some time to double check for many other possible errors :( I hope this will save your time :)
answered Jun 23, 2015 by Samuel Reuther
Thanks Samuel.  This is a very good point that you bring up.