Skip to content

BufferSizeKB parameter change in WLS WebServerLog (access.log) is not working with updateDomain.sh - WDT version 1.9.8 #817

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Michalski-Piotr opened this issue Jan 7, 2021 · 3 comments

Comments

@Michalski-Piotr
Copy link

Hello,
there is issue to use BufferSizeKB in WDT updateDomain.sh (online mode).
The remaining parameters like LogFileFormat,LogTimeInGMT, ELFFields are working fine

WDT version 1.9.8

Testing:

$ /u01/oracle/scripts/weblogic-deploy/bin/updateDomain.sh -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml/u01/oracle/scripts/weblogic-deploy/bin/updateDomain.sh -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml


Initializing WebLogic Scripting Tool (WLST) ...

Welcome to WebLogic Server Administration Scripting Shell

Type help() for help on available commands

####<Jan 7, 2021 9:16:27 AM> <INFO> <WebLogicDeployToolingVersion> <logVersionInfo> <WLSDPLY-01750> <The WebLogic Deploy Tooling updateDomain version is 1.9.8:master.10cd854:Dec 16, 2020 20:11 UTC>
Please enter the WebLogic administrator username: weblogic
Please enter the WebLogic administrator password:
####<Jan 7, 2021 9:16:33 AM> <SEVERE> <Validator> <__process_model_node> <WLSDPLY-05029> <BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/AdminServer/WebServer/WebServerLog>
####<Jan 7, 2021 9:16:33 AM> <SEVERE> <Validator> <__process_model_node> <WLSDPLY-05029> <BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/odi_server1/WebServer/WebServerLog>
####<Jan 7, 2021 9:16:34 AM> <SEVERE> <Validator> <__process_model_node> <WLSDPLY-05029> <BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/odi_server2/WebServer/WebServerLog>
####<Jan 7, 2021 9:16:34 AM> <SEVERE> <cla_helper> <validate_model> <WLSDPLY-20001> <updateDomain did not complete the operation because validation failed>

Issue Log for updateDomain version 1.9.8 running WebLogic version 12.2.1.4.0 online mode:

SEVERE Messages:

        1. WLSDPLY-05029: BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/AdminServer/WebServer/WebServerLog
        2. WLSDPLY-05029: BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/odi_server1/WebServer/WebServerLog
        3. WLSDPLY-05029: BufferSizeKB is not one of the attribute names allowed in model location topology:/Server/odi_server2/WebServer/WebServerLog
        4. WLSDPLY-20001: updateDomain did not complete the operation because validation failed

Total:       WARNING :     0    SEVERE :     4

updateDomain.sh failed (exit code = 2)

The model file:

logging.yaml:

topology:
  Server:
    AdminServer:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               BufferSizeKB: "2"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true

    odi_server1:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               BufferSizeKB: "2"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true
    odi_server2:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               BufferSizeKB: "2"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true

In WLST this parameter is available on the same level as other:

wls:/odi-domain/serverConfig/Servers/odi_server1/WebServer/odi_server1/WebServerLog/odi_server1> ls ()

-r--   BufferSizeKB                                 8
...
-r--   ELFFields                                    date time s-ip c-ip time-taken bytes cs-method cs-uri sc-status sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)
...
-r--   LogTimeInGMT                                 false

After removing BufferSizeKB from the model, it is working fine:

Changed model file logging.yaml:

topology:
  Server:
    AdminServer:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true

    odi_server1:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true
    odi_server2:
      WebServer:
          WebServerLog:
               LogFileFormat: "extended"
               ELFFields: "c-ip date time cs-method cs-uri sc-status bytes time-taken sc(X-ORACLE-DMS-ECID) cs(ECID-Context) cs(Proxy-Remote-User) cs(Proxy-Client-IP) cs(X-Forward-For)"
               LogTimeInGMT: true

Confirmation that changed model is accepted:

[oracle@odi-domain-as weblogic-deploy]$ /u01/oracle/scripts/weblogic-deploy/bin/updateDomain.sh -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml/u01/oracle/scripts/weblogic-deploy/bin/updateDomain.sh -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml
JDK version is 1.8.0_271-b25
JAVA_HOME = /usr/java/latest
WLST_EXT_CLASSPATH = /u01/oracle/scripts/weblogic-deploy/lib/weblogic-deploy-core.jar
CLASSPATH = /u01/oracle/scripts/weblogic-deploy/lib/weblogic-deploy-core.jar
WLST_PROPERTIES = -Dcom.oracle.cie.script.throwException=true -Djava.util.logging.config.class=oracle.weblogic.deploy.logging.WLSDeployCustomizeLoggingConfig
/u01/oracle/fmw/oracle_common/common/bin/wlst.sh /u01/oracle/scripts/weblogic-deploy/lib/python/update.py -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml/u01/oracle/scripts/weblogic-deploy/bin/updateDomain.sh -oracle_home /u01/oracle/fmw -domain_home /u01/oracle/domains/odi-domain -admin_url t3://10.100.4.189:7401 -model_file samples/logging.yaml

Initializing WebLogic Scripting Tool (WLST) ...

Welcome to WebLogic Server Administration Scripting Shell

Type help() for help on available commands

####<Jan 7, 2021 9:36:44 AM> <INFO> <WebLogicDeployToolingVersion> <logVersionInfo> <WLSDPLY-01750> <The WebLogic Deploy Tooling updateDomain version is 1.9.8:master.10cd854:Dec 16, 2020 20:11 UTC>
Please enter the WebLogic administrator username: weblogic
Please enter the WebLogic administrator password:
####<Jan 7, 2021 9:39:40 AM> <INFO> <filter_helper> <apply_filters> <WLSDPLY-20017> <No filter configuration file /u01/oracle/scripts/weblogic-deploy/lib/model_filters.json>
####<Jan 7, 2021 9:39:40 AM> <INFO> <filter_helper> <apply_filters> <WLSDPLY-20016> <No filters of type update found in filter configuration file /u01/oracle/scripts/weblogic-deploy/lib/model_filters.json>
####<Jan 7, 2021 9:39:40 AM> <INFO> <update> <__update_online> <WLSDPLY-09005> <Connecting to domain at t3://10.100.4.189:7401 with timeout value of 120000 ...>

####<Jan 7, 2021 9:39:43 AM> <INFO> <update> <__update_online> <WLSDPLY-09007> <Connected to domain at t3://10.100.4.189:7401>
####<Jan 7, 2021 9:39:43 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server AdminServer>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server AdminServer>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server odi_server1>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server odi_server1>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server odi_server2>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server odi_server2>
####<Jan 7, 2021 9:39:44 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server AdminServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server AdminServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server odi_server1>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server odi_server1>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_named_elements> <WLSDPLY-09608> <Updating Server odi_server2>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09604> <Updating WebServer for Server odi_server2>
####<Jan 7, 2021 9:39:45 AM> <INFO> <TopologyUpdater> <_add_model_elements> <WLSDPLY-09603> <Updating WebServerLog for WebServer>
####<Jan 7, 2021 9:39:45 AM> <INFO> <LibraryHelper> <install_domain_libraries> <WLSDPLY-12213> <The model did not specify any domain libraries to install>
####<Jan 7, 2021 9:39:45 AM> <INFO> <LibraryHelper> <extract_classpath_libraries> <WLSDPLY-12216> <The archive file was not provided so there are no classpath libraries to extract>
####<Jan 7, 2021 9:39:45 AM> <INFO> <LibraryHelper> <install_domain_scripts> <WLSDPLY-12241> <The model did not specify any domain scripts to install>
####<Jan 7, 2021 9:39:48 AM> <WARNING> <deployer_utils> <get_list_of_restarts> <WLSDPLY-09206> <Server AdminServer (standalone) requires a restart>
####<Jan 7, 2021 9:39:48 AM> <WARNING> <deployer_utils> <get_list_of_restarts> <WLSDPLY-09206> <Server odi_server1 (odi_cluster) requires a restart>
####<Jan 7, 2021 9:39:48 AM> <WARNING> <deployer_utils> <get_list_of_restarts> <WLSDPLY-09206> <Server odi_server2 (odi_cluster) requires a restart>

Issue Log for updateDomain version 1.9.8 running WebLogic version 12.2.1.4.0 online mode:

WARNING Messages:

        1. WLSDPLY-09206: Server AdminServer (standalone) requires a restart
        2. WLSDPLY-09206: Server odi_server1 (odi_cluster) requires a restart
        3. WLSDPLY-09206: Server odi_server2 (odi_cluster) requires a restart

Total:       WARNING :     3    SEVERE :     0

updateDomain.sh completed successfully but the domain requires a restart for the changes to take effect (exit code = 103)

Regards,
Piotr Michalski

@robertpatrick
Copy link
Member

The name of the parameter in the aliases file is BufferSizeKb--probably because this is the WLST offline name. It appears that the WLST online name is different (BuffferSizeKB).

@CarolynRountree
Copy link
Contributor

CarolynRountree commented Jan 7, 2021

Since online and offline attribute names often differ, we select one name to represent both the online and offline name. We have a tool that can assist you with finding the correct name: modelHelp.sh or modelHelp.cmd.

For example:
weblogic-deploy\bin\modelHelp.cmd -oracle_home c:\oracle\wls12214 topology:/Server/WebServer/WebServerLog

topology:
    Server:
        'Server-1':
            WebServer:
                WebServerLog:
                    BufferSizeKb:         # integer
                    DateFormatPattern:    # string
                    ELFFields:            # string
                    FileCount:            # integer
                    FileMinSize:          # integer
                    FileName:             # string
                    FileTimeSpan:         # integer
                    FileTimeSpanFactor:   # long
                    LogFileFormat:        # string
                    LogFileRotationDir:   # string
                    LogMilliSeconds:      # boolean
                    LogTimeInGMT:         # boolean
                    LoggingEnabled:       # boolean
                    Notes:                # string
                    NumberOfFilesLimited: # boolean
                    RotateLogOnStartup:   # boolean
                    RotationTime:         # string
                    RotationType:         # string

modelHelp.cmd completed successfully (exit code = 0)

@ddsharpe
Copy link
Member

ddsharpe commented Jan 7, 2021

Edited, should have read the previous post first. The model should use the offline name for the attribute. All model folder and attribute names use the offline names. The model posted above is using the online name, which is why the error occurs.

BufferSizeKB is only version of the name. BufferSizeKb is the offline version of the name. As Carolyn says, the modelHelp tool will show all the attributes for a given folder or tree.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants