MobileFirst install - cannot connect to database appcntr after it was created - db2

Trying to install MobileFirst 6.3 (Using DB2 v 10.5, Windows Server 2012 R2 std) - and during the creation of the DB2 APPCNTR database stage, I get the error:
Creating database APPCNTR (this may take 5 minutes) ...failed:
Cannot connect to database 'APPCNTR' with user 'db2admin' after it was created: com.ibm.db2.jcc.am.SqlException: DB2 SQL Error: SQLCODE=-1035, SQLSTATE=57019, SQLERRMC=null, DRIVER=4.17.29
This is a clean installation of DB2, with no other programs using it (that I know of). The db2admin user is a member of my windows security group 'DB2ADMS' as well as 'DB2USERS' just in case
If I go back in the installer, then press next again, it says the database is already created (not sure if it's fully successful or partial)....

I believe that the database has been created successfully but for some reason, it is not possible to connect to the database via JDBC.
The explanation for the error message can be found here -- it can be many reasons: http://www-01.ibm.com/support/knowledgecenter/SSEPGG_9.5.0/com.ibm.db2.luw.messages.sql.doc/doc/msql01035n.html
When that happens to me the issue is often resolved by waiting a bit and retarting Installation Manager. Restarting the DB2 instance helps also. (If you don't restart Installation Manager, it believes it needs to create the database and fails because the database was created).
If the problem is not resolved by waiting a bit, you can also create the database manually prior running install Manager using that procedure (use a different database name than the one that is considered busy):
https://www-01.ibm.com/support/knowledgecenter/SSHS8R_6.3.0/com.ibm.worklight.installconfig.doc/admin/t_creating_the_db2_database_for_App_Center.html
Then use that database name when running Installation Manager,

Related

Impossible to connect to a PostgreSQL server after a new installation

I have installed postgresql on my new laptop (on Windows).
I see the service postgresql-x64-11 - PostgreSQL Server 11 is running and is automatic. Perfect.
I have installed "dbeaver" (21.21). I would like to create my first database via dbeaver. I always get this message:
Database postgres does not exist
Is it possible to create a database with dbeaver ? Or not ? Or must I do the creation with some command lines ?

After restarting DB2 service, the application server gets ERRORCODE=-4499, SQLSTATE=58009 in database connections

We have an application on IBM WebSphere Application Server 7.x and it connects to a remote database on z/os DB2 10.x. For annual operation, DB2 shut down and restarted. After starting the database, we first get
com.ibm.websphere.ce.cm.StaleConnectionException
and then we get
The database manager is not able to accept new requests, has terminated all requests in progress, or has terminated this particular request due to unexpected error conditions detected at the target system. ERRORCODE=-4499, SQLSTATE=58009
The connection between WebSphere and DB2 tested by 'test Connection' in WAS datasource. Both systems are up and running but there is no correct connection between them! There was no change in DB2, WAS, and JDBC driver.
Update: The JDBC driver version is 4.15.134, connection properties is IBM WebSphere default setting and the connection is direct to DB2. Another problem later showed that while the connection still has the problem, executing the query directly on z/OS's DB2 gets the same the error. The query consist of a select with a join on two different tables, selecting on each table is ok, but the final query does not work and gets ERRORCODE=-4499, SQLSTATE=58009.
Update 2
The detail of environment is: IBM WebSphere Application Server 7.0.0.45, DB2 10.1, Java version 1.6 SR16 and z/OS 1.13.
This specific query gets the error in all environments, on all application server, z/os SPUFI, database viewer, such as DBeaver.
Any help is greatly appreciated.
Finally, we found the solution, ran REORG and RUNSTATS on both tables and on all their partitions, and the error vanished both on the application and SPUFI. I guess something went wrong during restart and tables corrupted. Now everything is ok.
If I got you correctly, you complain on inability of the driver to reestablish the database connections after the DB2 for Z/OS restart.
If yes, then have you tried to set the corresponding connection properties described at the following link?
Configuration of Sysplex workload balancing and automatic client reroute for Java clients

db2fs shows exception TypeError: netscape.security.PrivilegeManager is undefined

After successfully installing IBM DB2 Express V10.5_01 on an Ubuntu 14.04 LTS machine I tried to follow the next step and start
db2fs
in an X-Windows session. I am asked to create a profile for firefox and a browser window comes up with an error message dialog showing
exception TypeError: netscape.security.PrivilegeManager is undefined
When pressing ok for a few times the "create sample database" button disappears and instead a warning appears:
First Steps was unable to connect to the online DB2 Information Center and could not find an instance of a locally installed DB2 Information Center for this version of the product. To access product information, one of the following types of connections to a DB2 Information Center is required:
Internet access to the online DB2 Information Center
A locally installed version of the DB2 Information Center
Access to a remotely configured DB2 Information Center
As a workaround I tried to use
db2sampl
after adding my user to the groups dasadm1 db2iadm1 and db2fadm1 that had been created by the installation procedure.
db2sampl -force
Creating database "SAMPLE"...
Existing "SAMPLE" database found...
Dropping and recreating database "SAMPLE"...
Attempt to drop existing database "SAMPLE" failed.
Attempt to create the database "SAMPLE" failed.
SQL1013N The database alias name or database name "SAMPLE " could not be
found. SQLSTATE=42705
db2 list db directory
shows:
Database alias = SAMPLE
Database name = SAMPLE
Local database directory = <path>/db2inst1
Database release level = 10.00
Comment =
Directory entry type = Indirect
Catalog database partition number = -1
Alternate server hostname =
Alternate server port number =
unfortunately
db2cc
is not available anymore as an admin tool in V10.5 see DB2 Express V10.1 and db2cc binary and before downloading
IBM Data Studio I'd first like to check the basic integrity of my installation.
db2help
e.g. gives the errormessage
/bin/sh: 0: Illegal option -p
In all I have the feeling that Ubuntu 14.04 LTS is not a properyly supported platform for IBM DB2 Express V10.5_01.
How feasible is it to get IBM DB2 Express V10.5_01 running in this environment?

Error installing Moodle 3.0

I am unable to complete Moodle installation. I am hosting the site on NearlyFreeSpeech and using PHP 5.6. Moodle doesnt seem to be able to connect to the database and write any tables.
I created the moodledata folder in /protected/moodledata and moodle is in /public/moodle
I receive this error after accepting the terms and conditions.
Error reading from database
More information about this error
It is usually not possible to recover from errors triggered during installation, you may need to create a new database or use a different database prefix if you want to retry the installation.
Normally my first instinct would point to the config.php file but if it's getting as far as telling you that a connection is established with the database but there's a read error ("Error reading from database"), then that generally means your config.php file is probably healthy, but your database is not.
Firstly, check that you're using one of the following database servers that Moodle is compatible with (minimum version)
PostgreSQL 9.1
MySQL 5.5.31
MariaDB 5.5.31
Microsoft SQL Server 2008
Oracle Database 10.2
source.
Secondly, ensure that the user assigned to access your database in config.php has ALL PRIVILEGES set on that database.
Moving on... If this is a fresh install and you have no data to lose, your best bet is to start with a clean database.
You can either delete your existing database and set up a new one, or you can drop all tables from your existing database.
Option 1. Delete your existing database.
Delete your config.php file
Jump to phpMyAdmin (from the 'actions' tab on the MySQL process page)
Click on "Databases"
Delete your existing database
Hit "Create database" to generate a fresh, empty database
Go to http://your.url/install.php and follow the instructions for a fresh install.
Option 2. Clear your existing database
Jump to phpMyAdmin and run the following query:
DECLARE #sql NVARCHAR(max)=''
SELECT #sql += ' Drop table '+TABLE_SCHEMA+'.'+ TABLE_NAME
FROM INFORMATION_SCHEMA.TABLES
WHERE TABLE_TYPE = 'BASE TABLE'
Exec Sp_executesql #sql
source.
Then go to http://your.url/install.php and follow the instructions for a fresh install.
If you managed to start with a fresh database and you get the same error, please ensure that you have all the prerequisites available from your host. You can find a list of Moodle PHP requirements here.
The only time I've seen that error is when using the wrong MySQL version. Eg currently MySQL 5.5 is supported but if you have 5.1 you would get that error.
Source: http://realtechtalk.com/moodle_install_error_Error_reading_from_database_-2072-articles

SQL22223N creating database with DB2 Express C for Windows

I am having problems trying to create a database with DB2 Express C (v9.7).
I already have a another version of DB2 installed on my system:
Product: DB2 Connect Enterprise Edition
Version: 8.2
Copy: DB2COPY1
Instance: DB2
I understand that it is possible to have coexistence.
Express C has seemingly installed OK on my laptop, and I am able to use the Sample Database without a problem. I created new copy DB2COPY2, and new instance DB2_01.
I've installed it as a DB2ADMN.
When I try and create a database I get the error:
SQL22223N The Instance "DB2_01" does not exist on host "host name".
It is saying that the instance does not exist on the host. Which is strange because I installed it locally as a DB2ADMN.
Coexistence is supported. You have to open correct CLP version, and
set db2instance=db2_01
db2cc
and then it should work. If it doesn't you have to probably uncatalog and re-catalog your node and databases.