Can not start the DB Console error

By W.ZH  Aug 21 2009

Issue: On windows, when u try to start the DB EM console, it can not be accessed. go the windows services, we found that only the console service can not start, DB and listener service all start OK. So you DB can only access from SQL plus, can not manage from Web UI.

Go the cmd of windows, start the service (OracleDBConsoleorcl) by command, such as  D:\product\DataBase_10.2.0\bin\nmesrvc.exe

you get error of  “StartServiceCtrlDispatcher failed with err 1063”

Solve: This is because the host name and network problem. go to your host file. define your IP address to map to your machine name.  This also can be the window virtual networking address (not 127.0.0.1). then you can try to start the service again. It works, and you can access EM from web UI again.

Advertisements

How to install the Webcenter 11G

1. You download the wencenter suite from

http://www.oracle.com/technology/products/webcenter/index.html

up to July 2 2009, we have the 11G R1 for linux just released. The suite have four parts inside.
WebCenter,
WebCenter Services,
WebLogic Portal, and
WebCenter Interaction.

2.  Before you install the WC, you should make your Jdev can build the wencenter project first.. Download the Jdev 11G, and go to the plugin update of Jdev, to find the Webcenter framework and runtime plugin and install it to your Jdev.

3. upload and unzip the WC install zip to your Linux server.

DB notice:

1 support  AL32UTF8

2. must have the  processes more than 300

Connect as SYSDBA to database.Issue SQL command: ALTER SYSTEM SET processes=300 SCOPE=SPFILE;Restart DB.

EM can not start 11g

By W.ZH

Issue: You can start the DB and DB listener, but can not start the EM console.

Try out: In windows, go to cmd and ,

set ORACLE_SID=ORCL


lsnrctl status

check your listener runs or not. If your listener is not running and you need to start it using the "lsnrctl start" command.

Then u can start the console by this :

emctl start dbconsole

 

if can not start, You can use this to recreate EM :

 

 

emca -config dbcontrol db -repos recreate

Or two steps:

emca -deconfig dbcontrol db -repos drop
emca -config dbcontrol db -repos create


Refer this link and oracle forum to help u:

http://oracle-base.com/articles/misc/BasicEnterpriseManagerTroubleshooting.php

http://onlineappsdba.com/index.php/2009/01/02/oem-dbconsole-startup-issues-on-10g-r2-database-for-11ir12/


 

JSF message bundle VS Resource Bundle

By W.ZH Aug 04 2009Message Bundle +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Message Bundle in fact is the way before JSF 1.2.

As for localization, JSF allows you to specify a resource bundle in your faces-config.xml file. This will allow JSF to load the appropriate message bundles defined by the users browser. You still have to include it with loadBundle if you want to access it via JSP. JSF also allows you to mess with these resource bundles programatically. Here’s an example of the entry in your faces-config.xml file.

<faces-config>
	<application>
		<locale-config>
			<default-locale>en</default-locale>
			<supported-locale>de</supported-locale>
		</locale-config>
		<message-bundle>
			com.facesite.resource.MessageResources
		</message-bundle>
	</application>
</faces-config>

This will tell JSF that MessageResources.properties is the en (English) locale and to load this by default but it also tells JSF that you have a MessageResources_de.properties file that supports the German language which would be specified by the browser.

Loading it into your JSP.

    <f:loadBundle basename="com.facesite.resource.MessageResources" var="msg"/>
The MessageResources.properties file is in the standard java.util.Properties format.  If you want to access the msg from the backing bean, use this code:

String bundleName = getFacesContext().getApplication().getMessageBundle();
Locale locale = facesContext.getApplication().getDefaultLocale();
ResourceBundle bundle = ResourceBundle.getBundle (bundleName, locale);
String msg = bundle.getString(“your key here”);

normally there is a function in the JSFUtil.java can do this kind of thing.

http://forum.java.sun.com/thread.jspa?threadID=677420&messageID=9483204

http://www.javabeat.net/tips/47-how-to-use-resource-bundle-in-jsf.html

Resource Bundle +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

But from JSF 1.2, you have simple way to access the msg. You just need to define the bundle in the resource-bundle tag, then you can directly access from JSF page.  Sth like this:

<resource-bundle>
    <var>res</var>
    <base-name>resources.CustomMessages</base-name>
</resource-bundle>

Of coz in the backing bean,
getFacesContext().getApplication().getMessageBundle() will get null if you only use resource-bundle tag.

And i guess in the backing bean, you can use the
getFacesContext().getApplication().getResourceBundle( xxx,xxx);  to access the msg.

Related link:

http://yourmitra.wordpress.com/2008/04/16/java-server-faces-jsf-12-tidbits/