Setting up openfire server - mysql

I am having a problem setting up OpenFire on my localhost.
After setting the localhost database I seem to get this error.
The error appears after i select this option in the setup process:
"Store users and groups in the server database. This is the best option for simple deployments."
The web browser shows the following error:
"Problem accessing /setup/setup-profile-settings.jsp. Reason:
Server Error
Caused by:
java.lang.NullPointerException"
My database has been set up but there are no tables in it.
Could it be that I need to create a table with two rows: Users and Groups?
Where is the file setup-profile-settings.jsp? What type of file is this?
Could it be on my localhost server?
Thanks for any advice

If your database has no tables, then you are missing the Setup the Database step.
You have to import the schema file into your MySQL database from resources/database directory of the installation folder.
Guide for setting up database for MySQL (and other database) can be found here: http://www.igniterealtime.org/builds/openfire/docs/latest/documentation/database.html
Full installation guide http://www.igniterealtime.org/builds/openfire/docs/latest/documentation/install-guide.html

Related

Xampp-Mysql-Eclipse connection error

I have installed eclipse and xampp in my mac and tried to connect with mysql server from eclipse using mysql-5.7.9-osx10.10-x86_64 connector.
I have the user "root#localhost" granted with all privileges to all databases.
1) I'm able to connect only mysql database in phpmyadmin server.
Unable to connect any other database. Am getting an error :
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Unknown
database 'test'
2)After connecting with mysql database using
Class.forName("com.mysql.jdbc.Driver");
con=DriverManager.getConnection("jdbc:mysql://localhost:3306/mysql","root","1234");
I created a table adminlogins in mysql database, and used command
"select * from mysql.adminlogins"
but I am getting an error
com.mysql.jdbc.exceptions.jdbc4.MySQLSyntaxErrorException: Table
'mysql.adminlogins' doesn't exist.
I have tried all possible ways creating new user and granting all permissions. I am unable to figure out where am going wrong please some help me with this.
mysql database is reserved for system use. It is not recommended to create your own tables there. That said, the cause of your error is that the table was not created where you think it was if it was created at all.
Regardless, try creating the table in another database. If it does not work, post the exact commands that you used to create it with the messages that were returned.

Hmailserver database version could not be detected

Okay so I'm trying to install HMailServer on my Windows 7 PC with XAMPP, and connect it to the MySQL database in XAMPP. I've been Googling for hours and only finding either ineffective or invalid answers.
I went through the installation to the database set up and selected:
Select a new Hmail server default database
MySQL
Database Server address: E6400, port 3306, Database name: Douglas (All correct I checked it out in PHPmyadmin) Then I typed in my Username and password for a user that I granted all privileges too on the database...
Left service dependency blank
Then on the finish screen it returned
Starting task...
Please wait while updating database settings...
Settings updated.
Restarting server...
Database version could not be detected.
I did place a libmysql.dll file in the hmail server bin (not one from XAMPP because I couldn't find one in there).
Here's my error logs:
"ERROR" 5460 "2015-06-26 21:34:37.341" "Severity: 2 (High), Code: HM5033, Source: DALRecordset::Open, Description: MySQL: Table 'email.hm_dbversion' doesn't exist (Additional info: select * from hm_dbversion)"
"ERROR" 5460 "2015-06-26 21:34:37.341" "Severity: 1 (Critical), Code: HM5010, Source: Application::OnDatabaseConnected, Description: Database version could not be detected."
Do I need to manually create the table .hm_dbversion or something? Let me know if I need to include more information. Thanks everyone!
Just ran into this same issue. This is how I resolved it. There may be a better method to do this but this is what worked for me:
Run the installer and tell it you want to use a different database (MySQL).
Once the installer gets to the step where you setup the database, just cancel the database setup.
Open you hMail folder (C:\Program Files (x86)\hMailServer\DBScripts)
Locate the 'CreateTablesMYSQL.sql' file.
Use a MySQL database editor to create a new schema and execute the above sql file into that new schema.
Next, open the hMail database setup app. (C:\Program Files (x86)\hMailServer\Bin\DBSetup.exe)
Go through the steps to setup your MySQL database using the new schema you just created as the database.
If all was done well, you should fly thr

When run "sonar-runer" throw exception :"Caused by: Unknown database status: FRESH_INSTALL"

I need help
First , it throw exception
cannot load class 'com.mysql.xxx.JDBC'",so I copy the
sonarqube-4.0/extensions/jdbc-driver/mysql/mysql-connector-java-5.1.26.jar
to the /usr/lib/jvm/java-7-sun/jre/lib/ext/
Then I run sonar-runner again, it throws this exception:
Unknown database status: FRESH_INSTALL
My heart is broken , plz help me
I saw this error when the database is empty (no tables are created). Usually tables are created during first start of sonar.
Can you reach sonar by web interface?
Make sure that settings in your conf/sonar.properties file in Sonar directory are correct, these lines should be uncommented.
sonar.jdbc.url: jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8&rewriteBatchedStatements=true
sonar.jdbc.username: mysqlusername
sonar.jdbc.password: mysqlpassword
Then check if your conf/sonar-runner.properties file in sonar-runer directory has the same settings.
#----- MySQL
sonar.jdbc.url=jdbc:mysql://localhost:3306/sonar?useUnicode=true&characterEncoding=utf8
#----- Global database settings
sonar.jdbc.username=mysqlusername
sonar.jdbc.password=mysqlpassword
Also make sure that the line for default embeded database is commented.
#sonar.jdbc.url: jdbc:h2:tcp://localhost:9092/sonar
Sonar stopped supporting the property "sonar.jdbc.schema" from 4.2 version. Please refer link http://jira.codehaus.org/browse/SONAR-5000. To fix the issue on PostgreSQL based sonar deployment, execute the following SQL command on the database:
ALTER USER $dbUser$ SET search_path to $soanrQubeSchema$
I just encountered the same problem, and I solved it by restarting sonar server after creating proper user and database in mysql.
In fact, sonar server will fill the empty mysql database with many tables after restarting, and that removed the "FRESH_INSTALL" problem.

Error in setting up icinga_web. Table doesn't exist

I'm trying to setup icinga-web interface for monitoring servers. I have it installed and done with all troubleshooting mentioned here -
https://wiki.icinga.org/display/testing/Icinga+Web+Testing
But, I'm getting this error while accessing icinga-web interface -
Uncaught Doctrine_Connection_Mysql_Exception thrown:
SQLSTATE[42S02]: Base table or view not found: 1146 Table 'icinga_web.nsm_session' doesn't exist
Looking into databases, nsm_session table is present in "icinga" database and not "icinga_web". Is there any configuration that I am missing? Thanks in advance for help!
Likely you mixed your database setup.
'icinga' is the default database for the idoutils database backend, letting icinga config/status/historical write into it
'icinga_web' is a seperate database (and schema) which is only for icinga web's session, internal auth, etc information
It seems that the icinga_web db schema was imported into the 'icinga' database, and now the default settings of your icinga web installation point to the incorrect location.
There's two possibilities here:
clean the 'icinga' database from the faulty tables (look into icinga-web-src/etc/schema/mysql.sql to see which tables are created) and create the database 'icinga_web' and import the schema (see the docs on how to achieve that)
or work with the existing 'icinga' database, but update your icinga web databases.xml configuration - the dsn part for the icinga_web parts must bei changed to select the correct database 'icinga' then. http://docs.icinga.org/latest/en/icinga-web-config.html#configweb-databases
I would go with the clean and seperate way, makes debugging and resolving errors easier, so 1)
note: if you did install via package manager, i.e. apt, run "dpkg-reconfigure " for invoke the database configuration assistant.

Can't connect to database

Actually I'm having more than one problem...but all of it has to do with connecting or working with the MySQL database...First you can see one of the errors on my website and no matter what you choose it seems to just say it can't connect to the database...I've configured a configure.php file to allow files to connect to the MySQL database...see the website here:
http://netsurfer123.byethost11.com/index.php
Then when I try to log-in to the Admin area of my MySQL database it just says:
phpMyAdmin - Error
Cannot start session without errors, please check errors given in your PHP and/or webserver log file and configure your PHP installation properly.
Please let me know what I can do to correct these errors...and thanks very much in advanced for any helpful response/s.
First you need to check if the MySQL server is actually running. Use a command such as
/etc/rc.d/init.d/mysqld status
Or similar for your system if possible.
Did you check the web server log file? Does it contain errors as indicated by phpMyAdmin?
Your site is simply unable to connect to the database to which it's trying to connect. This could be for any number of potential reasons:
Is the database running?
Is the database accessible by that machine? (Maybe there's a firewall in between the two servers, if they're separated?)
If the database is on that same machine, are you connecting to it properly? (Maybe it allows only certain connection methods, such as a socket vs. the loopback address?)
Is your connection string correct? Maybe the login is failing?
Check your PHP logs, your Apache logs, your MySQL logs. One of them is complaining about something and it's probably trying to tell you what.