[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1934
  • Last Modified:

SQL Server Connection Failure

Trying to create a new blank BESMgmt Database. This is for an installation of BES.
Just installed SQL 2005 Express, and see the SQLServer (SQLExpress) service running.

The command I'm executing is: CreateDB.exe BESMgmt.cfg
However, I get these error messages in the BES logs.

======================================================
[20000] (04/21 10:26:52.923):{0x134} SQL Error Message from CBESDBInstaller::Connect: SQLSTATE: 08001 Native error: 17 Message: [Microsoft][ODBC SQL Server Driver][Shared Memory]SQL Server does not exist or access denied.

[30000] (04/21 10:26:52.923):{0x134} SQL Informational Message from CBESDBInstaller::Connect:  [Microsoft][ODBC SQL Server Driver][Shared Memory]ConnectionOpen (Connect()).

[20000] (04/21 10:26:52.923):{0x134} Terminating because of connection failure.  Connect string: DRIVER={SQL Server};SERVER=(local);UID=;PWD*
======================================================


Below is the BESMgmt.cfg file.
; CreateDB.cfg - controls the database create scripts
; 
; Comment line start with ';'
; Property names must be upper case
; No spaces allowed (use double quotes to surround values that contain space)
;
 
 
DATABASE_NAME=BESMgmt
 
;
; Type of db action to perform
;
; Install - creates a new database
; Migrate - DEPRECATED - use Upgrade
; Restore - restores a previously backed up db using RESTORE_FILENAME below
; UpdateData - DEPRECATED - use Upgrade
; NotifyInstall - install the database notification service
; NotifyUnInstall - removes the database notification service
; Upgrade - updates the schema and data to latest level
; CatalogDatabase - used for DB2 only.  Catalogs remote db locally
; AddOn - used to install additional tables to existing db.  ADD_ON_NAME needs to be set.
CMD=Install
 
;
; The userid/password to use to create/update to the database.  If not set, then the userid will be
; the user executing this program
USERID=
PASSWORD=
 
;
; Everything is logged to DB_InstallV<timstamp>.log but you can also
; get info/error msgs dumped to console by setting this to true
;
VERBOSE=false
 
; 
; Database version to create/migrate to
; Format is 3.5, 3.6, 4.0 etc
; If left blank, most recent version will be used
VERSION=
 
; 
; Create the database - if true, a create database will be done.  Ignored for migration
;
CREATE=true
 
;
; Backup the current database
;
BACKUP=false
 
;
; Drop the existing database.    Ignored for migration
;
DROP=false
 
;
; Name of Server to install the db
; Local machine can be specified as local
; Applies only to SQLServer
;
SERVER=local
 
; These settings applies only to DB2 and are used only when creating a new database
;
; The local node name of the remote DB2 Server
; If database is created locally, leave node blank
; DB2 has 8 character limit on node name
DB2NODE=
;
; If the DB2NODE value doesn't exist, then the next two settings are needed in order to create the node
;
DB2SERVER=
DB2PORT=
 
; These are used by the CatalogDatabase command.  Leave DB2LOCAL_DB blank to create local alias name
; the same as remote database name
DB2REMOTE_DB=
DB2LOCAL_DB=
 
;
; Stop processing if an error is encountered
;
STOP=true
 
;
; Path to where DBInstallScripts directory lives
; No trailing \
;
SCRIPT_ROOT=.
 
;
; Load locale specific version of some strings.
;
LOCALE=
 
;
; The name of the add on app to install/upgrade into an existing database.  This is ignored if
; the above CMD is not AddOn
;
ADD_ON_NAME=
 
;
; Directory to put create database log file in
; The dir should exist and there is no trailing \
;
LOG_DIR=.
 
;
; If set, Developer creates a smaller db
; 
DEVELOPER=false
 
;
; DBMS
;
DBMS=SqlServer
 
;Owner of the DB2 Schema.  If DB2SCHEMA is not present, defaults to BESADMIN
;
DB2SCHEMA=BESADMIN
 
;
; The directory to put the db files into.  This directory must exist.
; For SqlServer, default is the same location as the tempdb
;
DB_FILE_DIR=
 
;
; The directory to put the backup file to.  This directory must exist.
; Default is the same location as the database file is
;
BACKUP_DIR=
 
;
; The file that is to be restored.  
; Only used by the Restore command
; Default backup filename is:
; "<database location>\DatabaseNameBKUP.dat"
;
; If more than one backup exists in the file, the most recent one is used for restoring
;
RESTORE_FILENAME=
 
 
;
; If false, the sql files will be generated but not executed
;
GENERATE_EXECUTE=true

Open in new window

0
pzozulka
Asked:
pzozulka
  • 7
  • 5
1 Solution
 
reb73Commented:
Have you enabled mixed mode authentication?

The connect string seems to hint that SQL Authentication is being used while SQL Server 2005 installs with Windows Authentication as default..
0
 
pzozulkaAuthor Commented:
I don't believe I enabled that feature during setup. How can I enable it now?
0
 
reb73Commented:
Also check if shared memory is enabled in SQL Server Configuration Manager under protocols.. If not you may have to enable it..
0
Free Backup Tool for VMware and Hyper-V

Restore full virtual machine or individual guest files from 19 common file systems directly from the backup file. Schedule VM backups with PowerShell scripts. Set desired time, lean back and let the script to notify you via email upon completion.  

 
reb73Commented:
"I don't believe I enabled that feature during setup. How can I enable it now?"

If you right-click on the local server in SQL Server Management Studio, it should be available under options.
0
 
pzozulkaAuthor Commented:
Share Memory is Enabled. SQL Server Properties > Security:

Under Server authentication I chose: SQL Server and Windows Authentication mode.

Still no joy.
0
 
pzozulkaAuthor Commented:
Maybe it can't connect to server. The SQL Server instance is on the local machine, but maybe something is not running. Anything I need to check to make sure everything is running. I know our other SQL servers are running "SQL Server Service Manager" in the bottom right corner, next to the clock. I don't see that on this machine.
0
 
pzozulkaAuthor Commented:
When I try to go to ODBC connections to create a new USER DSN, I get this error message. I tried using NT Authentication for this.
SQL-failure.bmp
0
 
reb73Commented:
See if the SQL Browser service is running (using SQL Configuration Manager)
0
 
pzozulkaAuthor Commented:
Initially it wasn't, but I did start it up after the initial setup.
0
 
reb73Commented:
I think the problem could be with the instance name. SQLExpress creates a named instance by default like (local)\SQLEXPRESS ..

Can you retest the ODBC DSN creation using this as the servername?
0
 
pzozulkaAuthor Commented:
That seemed to have worked. When creating the ODBC connection, instead of choosing the server from the dropdown, I manually typed in SERVERNAME\SQLEXPRESS.
0
 
pzozulkaAuthor Commented:
That seemed to have worked. When creating the ODBC connection, instead of choosing the server from the dropdown, I manually typed in SERVERNAME\SQLEXPRESS.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

  • 7
  • 5
Tackle projects and never again get stuck behind a technical roadblock.
Join Now