Fiji Web Design
Welcome, Guest
Please Login or Register.    Lost Password?
Re:Unable to get this working (1 viewing) (1) Guest
Go to bottom Post Reply Favoured: 0
TOPIC: Re:Unable to get this working
#665
DJJester (User)
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
Re:Unable to get this working 1 Year, 1 Month ago Karma: 0  
It took a lot of screwing around with code but I was able to finally get things to work. The instructions were not correct for my server. Unfortunately, I lost my server not to recently due to my host shutting down without notice and I never backed up the config files. So I'm back to figuring it out again.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#666
schmutzler (User)
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
Re:Unable to get this working 1 Year, 1 Month ago Karma: 0  
WHY the hell did you do that?^^

You could have helped us out of this misery! Such a shame!
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#679
DJJester (User)
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
Re:Unable to get this working 1 Year ago Karma: 0  
Ok I've finally got mine working. FYI For any who wish to set this up, you must make the change not only in the openfire.xml file but in the ofproperty table in the openfire database. The database is often not entirely updated by the openfire.xml settings.

I'm including my config file with the database and password info removed. I'll also include my ofproperty table as an SQL statement.


Openfire.xml:
<?xml version="1.0" encoding="UTF-8"?>

<!--
    This file stores bootstrap properties needed by Openfire.
    Property names must be in the format: "prop.name.is.blah=value"
    That will be stored as:
        <prop>
            <name>
                <is>
                    <blah>value</blah>
                </is>
            </name>
        </prop>

    Most properties are stored in the Openfire database. A
    property viewer and editor is included in the admin console.
-->
<!-- root element, all properties must be under this element -->
<jive> 
  <adminConsole> 
    <!-- Disable either port by setting the value to -1 -->  
    <port>9090</port>  
    <securePort>9091</securePort> 
  </adminConsole>  
  <locale>en</locale>  
  <!-- Network settings. By default, Openfire will bind to all network interfaces.
      Alternatively, you can specify a specific network interfaces that the server
      will listen on. For example, 127.0.0.1. This setting is generally only useful
       on multi-homed servers. -->  
  <!--
    <network>
        <interface></interface>
    </network>
    -->  
  <connectionProvider> 
    <className>org.jivesoftware.database.DefaultConnectionProvider</className> 
  </connectionProvider>  
  <database> 
    <defaultProvider> 
      <driver>com.mysql.jdbc.Driver</driver>  
      <serverURL>jdbc:mysql://localhost:3306/databasename</serverURL>  
      <username>databaseuser</username>  
      <password>*******</password>  
      <testSQL>select 1</testSQL>  
      <testBeforeUse>true</testBeforeUse>  
      <testAfterUse>true</testAfterUse>  
      <minConnections>5</minConnections>  
      <maxConnections>25</maxConnections>  
      <connectionTimeout>1.0</connectionTimeout> 
    </defaultProvider> 
  </database>  
  <provider>
    <auth>
      <className>org.jivesoftware.openfire.auth.JDBCAuthProvider</className>
    </auth>
    <user>
      <className>org.jivesoftware.openfire.user.JDBCUserProvider</className>
    </user>
  </provider>
   <jdbcProvider>
    <driver>com.mysql.jdbc.Driver</driver>
    <connectionString>jdbc:mysql://localhost/databasename?user=databasename&amp;password=*******</connectionString>
  </jdbcProvider>
  <jdbcAuthProvider>
     <passwordSQL>SELECT password FROM jos_users WHERE username=?</passwordSQL>
     <passwordType>md5</passwordType>
  </jdbcAuthProvider>
  <jdbcUserProvider>
     <loadUserSQL>SELECT name,email FROM jos_users WHERE username=?</loadUserSQL>
     <userCountSQL>SELECT COUNT(*) FROM jos_users</userCountSQL>
     <allUsersSQL>SELECT username FROM jos_users</allUsersSQL>
     <searchSQL>SELECT username FROM jos_users WHERE</searchSQL>
     <usernameField>username</usernameField>
     <nameField>name</nameField>
     <emailField>email</emailField>
  </jdbcUserProvider>
  <admin>
    <authorizedUsernames>username, username, username</authorizedUsernames>
  </admin>
  <setup>true</setup>
</jive>
Important note: the admin section accepts a comma deliniated list of users that will be allowed to access the openfire backend. Make sure to put at least your main administrative user into this list so that you can access the backend. No admin list means you will not be able to login to the openfire backend AT ALL. The default admin info will not work with this configuration. ofProperty.sql:
--
-- Table structure for table `ofProperty`
--

CREATE TABLE IF NOT EXISTS `ofProperty` (
  `name` varchar(100) NOT NULL,
  `propValue` text NOT NULL,
  PRIMARY KEY  (`name`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1;

--
-- Dumping data for table `ofProperty`
--

INSERT INTO `ofProperty` (`name`, `propValue`) VALUES
('provider.user.className', 'org.jivesoftware.openfire.user.JDBCUserProvider'),
('jdbcUserProvider.loadUserSQL', 'SELECT name,email FROM jos_users WHERE username=?'),
('jdbcUserProvider.userCountSQL', 'SELECT COUNT(*) FROM jos_users'),
('jdbcUserProvider.allUsersSQL', 'SELECT username FROM jos_users'),
('jdbcUserProvider.searchSQL', 'SELECT username FROM jos_users WHERE'),
('jdbcUserProvider.usernameField', 'username'),
('jdbcUserProvider.nameField', 'name'),
('jdbcUserProvider.emailField', 'email'),
('xmpp.socket.ssl.active', 'true'),
('xmpp.domain', 'yourserver.com'),
('provider.admin.className', 'org.jivesoftware.openfire.admin.DefaultAdminProvider'),
('provider.lockout.className', 'org.jivesoftware.openfire.lockout.DefaultLockOutProvider'),
('provider.auth.className', 'org.jivesoftware.openfire.auth.JDBCAuthProvider'),
('xmpp.auth.anonymous', 'false'),
('provider.group.className', 'org.jivesoftware.openfire.group.DefaultGroupProvider'),
('provider.vcard.className', 'org.jivesoftware.openfire.vcard.DefaultVCardProvider'),
('provider.securityAudit.className', 'org.jivesoftware.openfire.security.DefaultSecurityAuditProvider'),
('admin.authorizedJIDs', 'username @yourserver.com,username @yourserver.com'),
('xmpp.session.conflict-limit', '0'),
('cache.GatewaySessionLocationCache.type', 'optimistic'),
('cache.GatewaySessionLocationCache.size', '-1'),
('cache.GatewaySessionLocationCache.maxLifetime', '-1'),
('cache.GatewaySessionLocationCache.min', '-1'),
('cache.GatewayRegistrationCache.type', 'optimistic'),
('cache.GatewayRegistrationCache.size', '-1'),
('cache.GatewayRegistrationCache.maxLifetime', '-1'),
('cache.GatewayRegistrationCache.min', '-1'),
('update.lastCheck', '1234626503582'),
('jdbcAuthProvider.passwordSQL', 'SELECT password FROM jos_openfire_users WHERE username=?'),
('jdbcAuthProvider.passwordType', 'sha1'),
('jdbcProvider.driver', 'com.mysql.jdbc.Driver'),
('jdbcProvider.connectionString', 'jdbc:mysql://localhost/databasename?user=databaseuser&password=databasepassword'),
('plugin.gateway.aim.enabled', 'true'),
('plugin.gateway.gadugadu.enabled', 'false'),
('plugin.gateway.icq.enabled', 'false'),
('plugin.gateway.irc.enabled', 'true'),
('plugin.gateway.msn.enabled', 'true'),
('plugin.gateway.yahoo.enabled', 'true'),
('plugin.gateway.gtalk.enabled', 'true'),
('mediaproxy.idleTimeout', '60000'),
('mediaproxy.lifetime', '9000'),
('mediaproxy.enabled', 'true'),
('mediaproxy.portMin', '10000'),
('mediaproxy.portMax', '20000'),
('mediaproxy.echoPort', '10020'),
('register.inband', 'false'),
('register.password', 'false'),
('passwordKey', 'CHANGED FOR SECURITY PURPOSES USE YOUR OWN');
 
Report to moderator   Logged Logged  
 
Last Edit: 2009/02/23 03:12 By admin. Reason: Double encoded the HTML entities since the code highliters seems to be converting them.
  The administrator has disabled public write access.
#691
schmutzler (User)
Fresh Boarder
Posts: 4
graphgraph
User Offline Click here to see the profile of this user
Re:Unable to get this working 1 Year ago Karma: 0  
YEAH, you're the man! Now its working.

But:

<connectionString>jdbc:mysql://localhost/databasename?user=databasename&password=*******</connectionString>

was not read correctly. I suggest to change the "&" to an "&amp;" (Ampersand), than everything is working as it should be.

Much Thanks! 8-)
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#700
admin (Admin)
Admin
Posts: 417
graph
User Offline Click here to see the profile of this user
Re:Unable to get this working 1 Year ago Karma: 9  
Yes, the correct config file would look like:

<?xml version="1.0" encoding="UTF-8"?>

<!--
    This file stores bootstrap properties needed by Openfire.
    Property names must be in the format: "prop.name.is.blah=value"
    That will be stored as:
        <prop>
            <name>
                <is>
                    <blah>value</blah>
                </is>
            </name>
        </prop>

    Most properties are stored in the Openfire database. A
    property viewer and editor is included in the admin console.
-->
<!-- root element, all properties must be under this element -->
<jive> 
  <adminConsole> 
    <!-- Disable either port by setting the value to -1 -->  
    <port>9090</port>  
    <securePort>9091</securePort> 
  </adminConsole>  
  <locale>en</locale>  
  <!-- Network settings. By default, Openfire will bind to all network interfaces.
      Alternatively, you can specify a specific network interfaces that the server
      will listen on. For example, 127.0.0.1. This setting is generally only useful
       on multi-homed servers. -->  
  <!--
    <network>
        <interface></interface>
    </network>
    -->  
  <connectionProvider> 
    <className>org.jivesoftware.database.DefaultConnectionProvider</className> 
  </connectionProvider>  
  <database> 
    <defaultProvider> 
      <driver>com.mysql.jdbc.Driver</driver>  
      <serverURL>jdbc:mysql://localhost:3306/databasename</serverURL>  
      <username>databaseuser</username>  
      <password>*******</password>  
      <testSQL>select 1</testSQL>  
      <testBeforeUse>true</testBeforeUse>  
      <testAfterUse>true</testAfterUse>  
      <minConnections>5</minConnections>  
      <maxConnections>25</maxConnections>  
      <connectionTimeout>1.0</connectionTimeout> 
    </defaultProvider> 
  </database>  
  <provider>
    <auth>
      <className>org.jivesoftware.openfire.auth.JDBCAuthProvider</className>
    </auth>
    <user>
      <className>org.jivesoftware.openfire.user.JDBCUserProvider</className>
    </user>
  </provider>
   <jdbcProvider>
    <driver>com.mysql.jdbc.Driver</driver>
    <connectionString>jdbc:mysql://localhost/databasename?user=databasename&amp;password=*******</connectionString>
  </jdbcProvider>
  <jdbcAuthProvider>
     <passwordSQL>SELECT password FROM jos_users WHERE username=?</passwordSQL>
     <passwordType>md5</passwordType>
  </jdbcAuthProvider>
  <jdbcUserProvider>
     <loadUserSQL>SELECT name,email FROM jos_users WHERE username=?</loadUserSQL>
     <userCountSQL>SELECT COUNT(*) FROM jos_users</userCountSQL>
     <allUsersSQL>SELECT username FROM jos_users</allUsersSQL>
     <searchSQL>SELECT username FROM jos_users WHERE</searchSQL>
     <usernameField>username</usernameField>
     <nameField>name</nameField>
     <emailField>email</emailField>
  </jdbcUserProvider>
  <admin>
    <authorizedUsernames>username, username, username</authorizedUsernames>
  </admin>
  <setup>true</setup>
</jive>
The bbcode parser for this forum component is converting the &amp; to &. Otherwise the XML won't be well-formed. DJJester, thanks for sharing this.
 
Report to moderator   Logged Logged  
 
Last Edit: 2009/02/23 03:10 By admin.
  The administrator has disabled public write access.
#788
ratzeputz (User)
Fresh Boarder
Posts: 1
graphgraph
User Offline Click here to see the profile of this user
Re:Unable to get this working 11 Months, 1 Week ago Karma: 0  
do i have to use a different database for openfire or must i use the same database as i am using for joomla?

if i change the openfire xml i cant login at the admin panel.
i changed the user in dies <admin></admin> section to my administrators name and i still cant login to admin panel
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
Go to top Post Reply
Powered by FireBoardget the latest posts directly to your desktop

Joomla Downloads

DownloadsDownload our free Joomla! Components, Modules and Plugins.