Fórumok
How to know whether portal-ext.properties is consumed properly?
Eason Chen, módosítva 9 év-val korábban
How to know whether portal-ext.properties is consumed properly?
New Member Bejegyzések: 4 Csatlakozás dátuma: 2015.01.22. Legújabb bejegyzések
Hi,
Recently, I installed the EE trial version to my local develop machine for evaluation. I need to test the SAML SP module, so I follow the following blog: http://www.liferay.com/web/armin.dahncke/blog/-/blogs/setting-up-liferay-portal-6-1-ee-as-a-sp, generate a file named: portal-ext.properties and the key file.
After I installed, launched and configured the portal successfully, I got the following file : portal-setup-wizard.properties in my Liferay Portal root folder C:\liferay-ee\. Then I renamed it to orig.portal-setup-wizard.properties.orig, kept it in the same place. The next step, I copied the content of the original file and pasted to the beginning of portal-ext file. Then I copied the portal-ext file to C:\liferay-ee\portal-ext.properties and C:\liferay-ee\tomcat-7.0.42\webapps\ROOT\WEB-INF\classes\portal-ext.properties, copied the key file to c:\liferay-ee\data folder.
I shutdown Tomcat and started-up again, however, the portal-ext files seemed not be consumed at all, I cannot get the SP metadata as it is supposed to be get. I cannot troubleshoot the problem whether is the files not consumed at all or there are some wrong configurations in the portal-ext file.
Could you please help me?
Thanks,
Eason
Recently, I installed the EE trial version to my local develop machine for evaluation. I need to test the SAML SP module, so I follow the following blog: http://www.liferay.com/web/armin.dahncke/blog/-/blogs/setting-up-liferay-portal-6-1-ee-as-a-sp, generate a file named: portal-ext.properties and the key file.
After I installed, launched and configured the portal successfully, I got the following file : portal-setup-wizard.properties in my Liferay Portal root folder C:\liferay-ee\. Then I renamed it to orig.portal-setup-wizard.properties.orig, kept it in the same place. The next step, I copied the content of the original file and pasted to the beginning of portal-ext file. Then I copied the portal-ext file to C:\liferay-ee\portal-ext.properties and C:\liferay-ee\tomcat-7.0.42\webapps\ROOT\WEB-INF\classes\portal-ext.properties, copied the key file to c:\liferay-ee\data folder.
I shutdown Tomcat and started-up again, however, the portal-ext files seemed not be consumed at all, I cannot get the SP metadata as it is supposed to be get. I cannot troubleshoot the problem whether is the files not consumed at all or there are some wrong configurations in the portal-ext file.
Could you please help me?
Thanks,
Eason
Mellékletek:
Olaf Kock, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
Liferay Legend Bejegyzések: 6403 Csatlakozás dátuma: 2008.09.23. Legújabb bejegyzések
The portal*.properties files that are used will be shown in the startup log - pay attention to that output.
It should be enough to have it in ${liferay-home}, in your case this seems to be C:\liferay-ee\ - having it in ..../tomcat/webapp/ROOT/WEB-INF/classes typically just obfuscates where the settings are, and makes you loose it on upgrades (as it's well hidden). Technically it can be in both places, but I consider it best practice to use only the first option.
As you're obviously on Windows: Make extra extra extra sure that you don't accidentally are dealing with a file called portal-ext.properties.txt - I've seen Windows hiding the actual extension more than once.
It should be enough to have it in ${liferay-home}, in your case this seems to be C:\liferay-ee\ - having it in ..../tomcat/webapp/ROOT/WEB-INF/classes typically just obfuscates where the settings are, and makes you loose it on upgrades (as it's well hidden). Technically it can be in both places, but I consider it best practice to use only the first option.
As you're obviously on Windows: Make extra extra extra sure that you don't accidentally are dealing with a file called portal-ext.properties.txt - I've seen Windows hiding the actual extension more than once.
Eason Chen, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
New Member Bejegyzések: 4 Csatlakozás dátuma: 2015.01.22. Legújabb bejegyzések
Hi Olaf,
Thanks for your reply. First of all, the extension name is correct. Then I did saw portal-ext.properties file is loaded in the startup log. There is no WARNING nor ERROR after loading. So I think the file is loaded correctly. However, When I went to the SP Metadata URL http://localhost:8080/c/portal/saml/metadata, it redirected back to portal index page. I just cannot tell whether the problem from either properties file loading or the configuration itself.
Thanks for your reply. First of all, the extension name is correct. Then I did saw portal-ext.properties file is loaded in the startup log. There is no WARNING nor ERROR after loading. So I think the file is loaded correctly. However, When I went to the SP Metadata URL http://localhost:8080/c/portal/saml/metadata, it redirected back to portal index page. I just cannot tell whether the problem from either properties file loading or the configuration itself.
Ravi Kumar Gupta, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
Liferay Legend Bejegyzések: 1302 Csatlakozás dátuma: 2009.06.24. Legújabb bejegyzések
There might be one more case when your properties file may not work.. that's when you change the property through UI. Because in that case the property is stored in Database and will always override the one in portal.properties or portal-ext.properties
Eason Chen, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
New Member Bejegyzések: 4 Csatlakozás dátuma: 2015.01.22. Legújabb bejegyzések
Hi Ravi,
If the properties are stored in Database and will override the ones in portal-ext.properties, then there should be some SAML configurations in database to override mine in the properties file. Yes?
In this case, how can I check and/or restore the properties (if I made any changes) in the database?
Moreover, can I insert records to database directly instead of using portal-ext.properties file
Thanks,
Eason
If the properties are stored in Database and will override the ones in portal-ext.properties, then there should be some SAML configurations in database to override mine in the properties file. Yes?
In this case, how can I check and/or restore the properties (if I made any changes) in the database?
Moreover, can I insert records to database directly instead of using portal-ext.properties file
Thanks,
Eason
Ravi Kumar Gupta, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
Liferay Legend Bejegyzések: 1302 Csatlakozás dátuma: 2009.06.24. Legújabb bejegyzések
Moreover, can I insert records to database directly instead of using portal-ext.properties file
Whether or not you can, you should never do that.
If the properties are stored in Database and will override the ones in portal-ext.properties, then there should be some SAML configurations in database to override mine in the properties file. Yes?
In this case, how can I check and/or restore the properties (if I made any changes) in the database?
Check your PortalPreferences table in database.
Thomas Berg, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
Regular Member Bejegyzések: 131 Csatlakozás dátuma: 2009.09.07. Legújabb bejegyzések
Hi Eason,
I guess you know this but anyway, also check which values are active by checking this location in your server:
This won't tell you explicitly if the value comes from portal-ext.properties or portal.properties but it will tell you what value a given property has and whether it was read from portal.properties (or one of its extensions) or set in the UI (and thus stored in the database).
Regards
Thomas
I guess you know this but anyway, also check which values are active by checking this location in your server:
http://localhost:8080/group/control_panel/manage/-/server/properties/portal-properties
This won't tell you explicitly if the value comes from portal-ext.properties or portal.properties but it will tell you what value a given property has and whether it was read from portal.properties (or one of its extensions) or set in the UI (and thus stored in the database).
Regards
Thomas
Ramalingaiah Dudidmetle, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
Expert Bejegyzések: 486 Csatlakozás dátuma: 2014.08.16. Legújabb bejegyzések
Hi Thomas Berg,
portal-ext.properties in Just JDBC Connection to DB coneting Tables in Default
i am using in DB Postgres ,
in my portal-ext.properties inside ,
jdbc.default.driverClassName=org.postgresql.Driver
jdbc.default.username=postgres
jdbc.default.password=postgres
jdbc.default.url=jdbc:postgresql://localhost:5432/ebs?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false
portal-ext.properties in Just JDBC Connection to DB coneting Tables in Default
i am using in DB Postgres ,
in my portal-ext.properties inside ,
jdbc.default.driverClassName=org.postgresql.Driver
jdbc.default.username=postgres
jdbc.default.password=postgres
jdbc.default.url=jdbc:postgresql://localhost:5432/ebs?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false
Eason Chen, módosítva 9 év-val korábban
RE: How to know whether portal-ext.properties is consumed properly?
New Member Bejegyzések: 4 Csatlakozás dátuma: 2015.01.22. Legújabb bejegyzésekThomas Berg:
Hi Eason,
I guess you know this but anyway, also check which values are active by checking this location in your server:http://localhost:8080/group/control_panel/manage/-/server/properties/portal-properties
This won't tell you explicitly if the value comes from portal-ext.properties or portal.properties but it will tell you what value a given property has and whether it was read from portal.properties (or one of its extensions) or set in the UI (and thus stored in the database).
Regards
Thomas
Hi Thomas,
Thanks for your advice. From the given URL, I can find my SAML settings, which are exactly what I had set from portal-ext.properties. Now I can try why I still cannot use SAML SP.