13 June 2018

tzupdater Mac OS X (offline)

wget https://www.iana.org/time-zones/repository/tzdata-latest.tar.gz

gsha512sum /Users/German/bin/tzupdater-2.1.2/tzdata-latest.tar.gz |awk '{print $1}' > /Users/German/bin/tzupdater-2.1.2/tzdata-latest.tar.gz.sha512

sudo java -jar tzupdater.jar -f -v -l file:///Users/German/bin/tzupdater-2.1.2/tzdata-latest.tar.gz 


Note: gsha512sum from brew coreutils

Password:
Using file:///Users/German/Downloads/tzupdater-2.1.2/tzdata-latest.tar.gz as source for tzdata bundle.
java.home: /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre
java.vendor: Oracle Corporation
java.version: 1.7.0_80
tzupdater version 2.1.2-b01
JRE tzdata version: tzdata2018e
Downloaded file to /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp/tzdata.tar.gz
javazic: warning: found last rules for Eire inconsistent.
tzupdater tool would update with tzdata version: tzdata2018e
Downloaded file to /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp/sha512hash
Extracting files... done.
Renaming /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre/lib/zi to /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre/lib/zi.tzdata2018e_2
Renaming /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre/lib/zi.tzdata2018e to /Library/Java/JavaVirtualMachines/jdk1.7.0_80.jdk/Contents/Home/jre/lib/zi
Validating for : tzdata2018e
Validation complete
JRE updated to version : tzdata2018e


just in case,for online:

$ sudo java -jar tzupdater.jar -f -v

UPDATE:

There is a known bug with new format:

Using file:///Users/German/bin/tzupdater-2.1.2/tzdata-latest.tar.gz as source for tzdata bundle.
java.home: /Library/Java/JavaVirtualMachines/jdk1.8.0_191.jdk/Contents/Home/jre
java.vendor: Oracle Corporation
java.version: 1.8.0_191
tzupdater version 2.2.0-b01
JRE tzdata version: tzdata2018e
Downloaded file to /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/tzdata.tar.gz
tzupdater tool would update with tzdata version: tzdata2019b
Compiling TZDB version 2019b
Parsing file: /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/africa
Parsing file: /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/antarctica
Parsing file: /var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/asia
Failed: java.lang.Exception: Failed while parsing file '/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/asia' on line 1865 'Rule    Japan    1948    1951    -    Sep    Sat>=8    25:00    0    S'
java.lang.Exception: Failed while parsing file '/var/folders/zz/zyxvpxvq6csfxvn_n0000000000000/T/tz.tmp_2/asia' on line 1865 'Rule    Japan    1948    1951    -    Sep    Sat>=8    25:00    0    S'
    at tools.tzdb.TzdbZoneRulesCompiler.parseFile(TzdbZoneRulesCompiler.java:377)
    at tools.tzdb.TzdbZoneRulesCompiler.compile(TzdbZoneRulesCompiler.java:191)
    at tools.tzdb.TzdbZoneRulesCompiler.(TzdbZoneRulesCompiler.java:307)
    at com.sun.tools.tzupdater.ExternalModule.compileToJSRBinary(ExternalModule.java:153)
    at com.sun.tools.tzupdater.TimezoneUpdater.run(TimezoneUpdater.java:230)
    at com.sun.tools.tzupdater.TimezoneUpdater.main(TimezoneUpdater.java:634)
Caused by: tools.tzdb.DateTimeException: Invalid value for SecondOfDay value: 90000
    at tools.tzdb.ChronoField.checkValidValue(ChronoField.java:173)
    at tools.tzdb.LocalTime.ofSecondOfDay(LocalTime.java:210)
    at tools.tzdb.TzdbZoneRulesCompiler.parseMonthDayTime(TzdbZoneRulesCompiler.java:475)
    at tools.tzdb.TzdbZoneRulesCompiler.parseRuleLine(TzdbZoneRulesCompiler.java:399)
    at tools.tzdb.TzdbZoneRulesCompiler.parseFile(TzdbZoneRulesCompiler.java:354)
    ... 5 more


This is solved by using:

sudo java -jar tzupdater.jar -l https://web.cs.ucla.edu/~eggert/tz/release/2019a/tzdata2019a-rearguard.tar.gz

https://bugs.openjdk.java.net/browse/JDK-8213085

Remote Weblogic Deployer

When deploying to a remote WLS, use -remote -upload or the following BEA error will be triggered:


[Deployer:149003]Unable to access application source information in "/Users/German/Documents/tmp/zz_test_web.war" for application "zz_test_web". The specific error is: No application files exist.


Correct command line:

java weblogic.Deployer -adminurl t3://10.10.10.125:10000 -username weblogic -password welcome1 -deploy -targets wls_cluster -name zz_test_web /Users/German/Documents/tmp/zz_test_web.war -verbose -upload -remote

Cookies WLS Admin Console

Whenever you cannot login into WLS Admin Console thru FireFox, try first removing Cookies for that specific IP, instead of cleaning cache/cookies, etc.

12 June 2018

BEA-290015

When the message :

<BEA-290015> <Domain wide secret mismatch>

Appears, then probably the issue is not synchronized servers among AdminServer and Managed Server(s).

This could be resolved using nptd.

-Djava.awt.headless=true

There is a common issue when creating PDF in WebLogic Server:


<[ServletContext@26791009[app:foo-rest module:foo-rest.war path:null spec-version:3.0]] Root cause of ServletException.
java.lang.NoClassDefFoundError: Could not initialize class net.sf.jasperreports.engine.util.JRStyledTextParser
                at net.sf.jasperreports.engine.fill.JRBaseFiller.(JRBaseFiller.java:108)
                at net.sf.jasperreports.engine.fill.JRVerticalFiller.(JRVerticalFiller.java:69)
                at net.sf.jasperreports.engine.fill.JRVerticalFiller.(JRVerticalFiller.java:57)
                at net.sf.jasperreports.engine.fill.JRFiller.createBandReportFiller(JRFiller.java:200)
                at net.sf.jasperreports.engine.fill.JRFiller.createReportFiller(JRFiller.java:215)
                Truncated. see log file for complete stacktrace

...
...
<[ServletContext@1852380706[app:bar module:bar.war path:null spec-version:3.0]] Root cause of ServletException.
java.lang.NoClassDefFoundError: Could not initialize class sun.awt.X11GraphicsEnvironment
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:195)
        at java.awt.GraphicsEnvironment.createGE(GraphicsEnvironment.java:102)
        at java.awt.GraphicsEnvironment.getLocalGraphicsEnvironment(GraphicsEnvironment.java:81)
        at net.sf.jasperreports.engine.util.JRStyledTextParser.(JRStyledTextParser.java:94)
        at net.sf.jasperreports.engine.fill.JRBaseFiller.(JRBaseFiller.java:108)
        at net.sf.jasperreports.engine.fill.JRVerticalFiller.(JRVerticalFiller.java:69)
        at net.sf.jasperreports.engine.fill.JRVerticalFiller.(JRVerticalFiller.java:57)
        at net.sf.jasperreports.engine.fill.JRFiller.createBandReportFiller(JRFiller.java:200)
        at net.sf.jasperreports.engine.fill.JRFiller.createReportFiller(JRFiller.java:215)
        at net.sf.jasperreports.engine.fill.JRFiller.fill(JRFiller.java:115)
        at net.sf.jasperreports.engine.JasperFillManager.fill(JasperFillManager.java:667)
        at cl.ejemplo.common.reporteria.service.impl.ReporteriaServiceJasperImpl.construirBarFooReporte(ReporteriaServiceJasperImpl.java:306)
        at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)


This is solved by adding the following argument to WLS script:

 -Djava.awt.headless=true

OPTIMIZER_FEATURES_ENABLE

Sometimes it's necessary to downgrade features for Oracle DB:
NOTE: Modifying the OPTIMIZER_FEATURES_ENABLE parameter generally is strongly discouraged and should only be used as a short term measure at the suggestion of Oracle Global Support.

The parameter can be set from the system or session level:

alter system set optimizer_features_enable='10.2.0.4' scope=spfile;

alter session set optimizer_features_enable='10.2.0.4';


It can also be set by adding a hint:

SELECT /*+ optimizer_features_enable('10.2.0.4') */ ENAME FROM EMP;

When setting this parameter, remember that all optimizer parameter settings will revert back to the older version. Thus, any 'new' optimizer features will not be used and other queries may be detrimentally affected





_WL_TEMP_APP_DOWNLOADS

When using plan.xml to update an application, if the config-root element is erroneously set to wrong value or empty then the directory is recursively updated with the content :

$DOMAIN_HOME/servers/adminServer /tmp/_WL_TEMP_APP_DOWNLOADS/[APP_NAME]

The server may run out of space. There is a patch to avoid it.

11 June 2018

Dominosa

Reading an old version of Knuth Dancing Links draft. I thought I found an error, but it was already found and solved.

# Knuth Dancing Links. Wrong original
0 0 5 2 1 4 1 2
1 4 5 3 5 3 5 6
1 1 5 6 0 0 4 4
4 4 5 6 2 2 2 3
0 0 5 6 1 3 3 6
6 6 2 0 3 2 5 1
1 5 0 4 4 0 3 2


# Knuth Dancing Links. Correct version :P
0 6 5 2 1 4 1 2
1 4 5 3 5 3 3 6
1 1 5 6 0 0 4 4
4 4 5 6 2 2 2 3
0 0 5 6 1 3 3 6
6 6 2 0 3 2 5 1
1 5 0 4 4 0 3 2


Anyway, I was able to learn who invented the Dominio game called Dominos, which I knew from Gardner article and has appeared in several magazines/online sites.
Dominosa was developed by O. S. Adler in 1874. It was patented by Richard Osa (pseudonym for O. S. Adler) in Germany in 1893 as German Reichs Patent No. 71539 and published in 1894 under the name of “Dominosa” , combining ‘Domino’ with Adler’s initials. It later appeared in 1912 in a domino puzzle book , co-authored by Fritz 2 Jahn [4].
Source: https://www.researchgate.net/publication/282626601_Reconstruction_of_domino_tilings-Combinatorial_and_probabilistic_questions?_sg=PPGfibelUd_bhFkR01XbmeYluzhKQhBCWWhYB6NsPIVoBAESijOVXxcnXFi8Af5Blm7G0y-xww

http://libridigiochi.blogspot.com/2015/01/domino-pubblicazioni-in-lingua-tedesca.html


Besides, it is announced the new Fascicle of TAOCP: The Art of Computer Programming, Volume 4B, Fascicle 5: The: Mathematical Preliminaries Redux; Backtracking; Dancing Links

Blog Archive

Disclaimer

The views expressed on this blog are my own and do not necessarily reflect the views of Oracle.