Bringing PRINCE2™ to Life . . .  

PO Box 3664
Buckinghamshire
MK16 9WT, United Kingdom

+44 (0)8707 605636
enquiries@i-methods.co.uk

Bringing PRINCE2™ to life

Troubleshooting

i-method is dependent on the set up of SQL Server which itself depends on the host environment. In nearly all cases i-method installs and runs without problem, however the following errors may occur:

1. Cannot find SQL Server:

Error while executing / parsing the ASP page
The script reported following error: [Microsoft][ODBC SQL Server Driver][DBNETLIB]SQL Server does not exist or access denied. (error number 0x80004005 hex)

Cause:
a. Server not running - See Managing MSDE.
b. .dsn file not pointing at right server - see Establish Data Connection.

2. Cannot find database:

Error while executing / parsing the ASP page
The script reported following error: [Microsoft][ODBC SQL Server Driver][SQL Server]Cannot open database requested in login 'imethod_compiledSQL_1xx'. Login fails. (error number 0x80004005 hex)

Cause:
a. Database file not attached - see Attach the Database.
b. .dsn file file pointing to wrong database - see Establish Data Connection.

3. Cannot log in to database:

Error while executing / parsing the ASP page
The script reported following error: [Microsoft][ODBC SQL Server Driver][SQL Server]Login failed for user 'xxx'. (error number 0x80040E4D hex)

Cause:
a. Wrong UserID/Password combination or PWD line missing in the .dsn file - see Establish Data Connection.

 


Managing MSDE

The SQL Server must be running for i-method to work. The status of the server is shown by the icon in the systems tray.

You can manage the SQL Server using the Microsoft SQL Service Manager. Run the file “C:\Program Files\Microsoft SQL Server\80\Tools\Binn\sqlmangr.exe", or go to ‘Start’,’Run’ and type in sqlmangr.exe.

After installation you should ensure the server is running.

 

Attach the Database

The database file provided with i-method must be attached to the SQL Server. Each time i-method runs it executes a batch file (attachDB.bat) to check that the database file is attached to the SQL Server. If the database file is not attached then the batch file attaches it.

You may mauually attach the database to the Server using either a database utility (e.g. Enterprise Manager) or by using tSQL. The file “attachDB.bat” in the i-method root directory uses tSQL and may be used as the basis for attaching the database.

The default file is:

@echo IF NOT EXISTS (SELECT name FROM master.dbo.sysdatabases WHERE name = N'imethod_compiledSQL_1xx') >attachdb.sql
@echo BEGIN >>attachdb.sql
@echo EXEC sp_attach_db @dbname = N'imethod_compiledSQL_1xx', >>attachdb.sql
@echo @filename1 = N'%CD%\Data\imethod_compiledSQL_1xx.mdf' >>attachdb.sql
@echo END >>attachdb.sql
@echo GO >>attachdb.sql

oSQL -S 127.0.0.1\IMETHOD -U sa -P password -i attachdb.sql

If you use this file it should be edited as follows:

Line 4:

@echo @filename1 = N'%CD%\Data\imethod_compiledSQL_1xx.mdf', >>attachdb.sql

Replace %CD% with the absolute path to the respective files. For example if the database files are in y:\it\shared\i-method\Data the amended line will read:

@echo @filename1 = N' y:\it\shared\i-method \Data\imethod_compiledSQL_1xx.mdf' >>attachdb.sql

Line 8:

oSQL -S 127.0.0.1\IMETHOD -U sa -P password -i attachdb.sql

The value after the -S switch is the SERVERNAME/INSTANCE of the SQL Server. 127.0.0.1 refers to the localhost and IMETHOD is the default instance. You can replace this entry with the name and instance of the SQL Server or MSDE you are using. So if you have installed the instance ‘IMETHOD’ on a server called BVCPD2 then the line will read:

oSQL -S BVCPD2\IMETHOD -U sa -P password -i attachdb.sql

You can check the servername and instance of the SQL Server using the Microsoft SQL Service Manager.

The valuse of the -U and -P swirtches are the UserID and Password of the SQL Server's sa log-in. These shoild be set as follows:

UID=
  • sa for all installations where you have not established a new SQL user
  • whatever user name you have given to the dedicated i-method log-in for an existing SQL Server
PWD=
  • password if you have used the “setupMSDE.bat” file and not changed the SAPWD parameter.
  • Whatever you set the SAPWD parameter in the “setupMSDE.bat” file
  • Whatever the SAPWD is of the existing SQL server
  • whatever password you have given to the dedicated i-method log-in for an existing SQL Server

By default i-method uses the sa log-in with the password ‘password’ to access the MSDE database named instance IMETHOD. As it is highly unlikely that any other application will access this instance the use of the sa log-in is not considered a security issue. Where the i-method database is attached to an existing SQL server a new server user should be set up to allow the i-method application to access the database without using the sa log-in thus maintaining security of other SQL server areas. In this case or if you have changed the SAPWD parameter when you installed the server or if you are using the sa log-in of an existing SQL server you should also change the log-in name after the -U switch and/or the password value after the -P switch as appropriate.

Once you have edited this file, if you haven’t already done so, run it to attach the database. (You may like to add ‘Pause’ as a last line to the file before running - this will let you see the outcome. Don’t forget to remove the ‘pause’ before executing i-method as this file executes ‘hidden’ each i-method run time and the added pause will prevent i-method running.)

 

Establish Data Connection

i-method must be able to access it's database on the SQL Server. Connection is done through a .dsn file (imethod_compiledSQL_1xx.dsn) in the i-method root directory. This file may be edited with notepad.

You need to ensure:

  • the .dsn file has the line: SERVER=myserver\myinstance (see above)
  • the .dsn file has the line: DATABASE=imethod_compiledSQL_1xx
  • the correct UserID/Password combination is set.

The default file is:

[ODBC]
DRIVER=SQL Server
UID=sa
PWD=password
DATABASE=imethod_compiledSQL_1xx
APP=Microsoft Data Access Components
SERVER=127.0.0.1\IMETHOD

This may be edited as follows:

UID=
  • sa for all installations where you have not established a new SQL user
  • whatever user name you have given to the dedicated i-method log-in for an existing SQL Server
PWD=
  • password if you have used the “setupMSDE.bat” file and not changed the SAPWD parameter.
  • Whatever you set the SAPWD parameter in the “setupMSDE.bat” file
  • Whatever the SAPWD is of the existing SQL server
  • whatever password you have given to the dedicated i-method log-in for an existing SQL Server
SERVER=
  • should be set to the name and instance of the SQL Server or MSDE you are using, for example: SERVER=BVCPD2\IMETHOD or SERVER=LIVESQL

[In certain instances where you have installed MSDE on a network with an existing version of SQL Server the SAPWD of the IMETHOD instance can revert to the SAPWD of the existing server despite setting the parameter on install. In this case use the SAPWD of the existing server.]

You can test the connection by opening Data Sources (ODBC) from the Administrative Tools menu or clicking ‘Start’,’Run’ and typing in odbcad32.exe. Click on the File DSN tab and then browse to the “imethod_compiledSQL_1xx.dsn” in the i-method root directory. Select this file and click ‘Configure’.

Ensure the following settings:

  • Server: the name and instance of the SQL Server or MSDE you are using
  • Verification: select “With SQL Server authentication using a login ID and password entered by the user”
  • Login ID: sa (or as appropriate)
  • Password: password (set as above)
  • Default Database: select “ Change the default database to” and then select ‘imethod_compiledSQL_1xx’

Once you click ‘Finish’ you have the opportunity to Test the Data Source.

Note: After testing you must re-edit the .dsn file and ensure the PWD line is included as the Microsoft Data Sources administrator removes this line on completion.

 

©2006-2007 Interactive Methodologies Ltd