Category Archives: How to Fix

Registry key Error: Java version has value ‘1.8‘, but ‘1.7‘ is required

Registry key Error: Java version has value ‘1.8’, but ‘1.7’ is required

Problem Description:

1. Jdk1.7.0 is installed first_ After 80, jdk1.8.0 was installed_ 181. The former is configured in the environment variable
2. The following error occurs when entering Java – version in CMD:

Error: Registry key 'Software\JavaSoft\Java Runtime Environment'\CurrentVersion'
has value '1.7', but '1.8' is required.
Error: could not find java.dll
Error: Could not find Java SE Runtime Environment.

Problem solving:

When upgrading from jdk1.7 to JDK1.8, there are three things to confirm:

1. System environment variables

2. Registry

Computer \ HKEY_ LOCAL_ MACHINE\SOFTWARE\JavaSoft\Java Runtime Environment

3. Update java.exe javaw.exe javaws.exe under C: \ windows \ system32

Error caused by too many versions of JDK installed on the computer

For example, there was no problem installing 1.7

After installing 1.8 and modifying the environment variables, the java.exe javaw.exe javaws.exe under C: \ windows \ system32 is still in the 1.7 installation package.

Just replace the java.exe of 1.7 with Java 1.8.

ERROR: Adobe Flashplayer or HTML5 Browser with WebGL or CSS3D support requ

Error appears on the pyqt5 qwebengine VR interface: Adobe flashplayer or HTML5 browser with webgl or css3d support requ

The following sentences can prevent the interface from flickering. If you add more, the image above will appear. As long as you leave other comments and the last sentence, you can solve the interface flickering and play VR video.

from PyQt5.QtCore import *
from PyQt5.QtGui import *   

# QCoreApplication.setAttribute(Qt.AA_UseSoftwareOpenGL,True)
# QCoreApplication.setAttribute(Qt.AA_UseSoftwareOpenGL, True)
# QGuiApplication.setAttribute(Qt.AA_UseSoftwareOpenGL, True)
# QApplication.setAttribute(Qt.AA_UseSoftwareOpenGL, True)

QCoreApplication.setAttribute(Qt.AA_UseOpenGLES, True)

AttributeError: ‘WebDriver‘ object has no attribute ‘w3c‘

Problems encountered in the process of automatic testing of mobile terminal with Python + appnium.

Reason: I reported an error in selenium 3.3.1. After uninstalling selenium, I reinstalled selenium 4.0.0 (installed by default and the latest version). I ran it again and the problem was solved. Only the positioning mode needs to be changed to the latest, otherwise there will be a warning.

The new positioning method of mobile terminal is as follows:

from appium.webdriver.common.mobileby import MobileBy

driver.find_element(MobileBy.ID, "com.tencent.mm:id/hej").click()

Exception occurred when Django created app: from exc ^ syntaxerror: invalid syntax

Execute command Python   manage.py   startapp   Myjango

  App reports an error: file “manage. Py”, line 16) from exc ^ syntax error: invalid syntax

reason:

Python 3 is installed, but Python is used for execution

solve:

Change Python to python3 and execute the above command

python3 manage.py   startapp   myjango

Mobaxterm connects to Ubuntu server through SSH network error: software caused connection abort

Recently, mobaxterm is used to connect to the remote Ubuntu server through SSH. After not operating for a period of time, the connection will be broken and a prompt “network error: software caused connection abort” will be displayed.

You can modify the SSH configuration item in mobaxterm and check SSH keepalive to solve the problem of disconnection.

In addition, you need to modify the configuration file on the Ubuntu server side.

sudo vi /etc/ssh/sshd_config

1. Find tcpkeepalive yes and # remove the previous one;

2. Find the clientaliveinterval parameter, remove the previous #, and change the following 0 to 60, indicating that the request is sent every minute to maintain the connection.


Digression. To maintain the connection, you can use commands such as top to refresh the command line in real time.

S32ds: error in services launch sequence when debugging with JLINK

S32ds uses JLINK debugging to report an error: error in services launch sequence

1、 Solution

    the operation is shown below

    2、 Scenario:

    Create a new example project and connect JLINK to SWD. Select XXX_ debug_ flash_ JLINK option for debugging. The error interface pops up, as shown in the figure below

    3、 Solving process

    Use JLINK to connect MCU. Segger’s SWD is connected to the MCU, the red light flashes, and the interface prompts that the connection is successful. Click the debugging button of s32ds, and the JLINK light does not flash. It is suspected that the correlation between s32ds and segger is abnormal, so the path is found and the solution is obtained

kernel: [ 3166.869181] EDAC MC2: 1 CE memory read error on CPU_SrcID#1_Ha#1_Chan#1_DIMM#0

Sysptom:
Sun Nov 14 19:08:17 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 19:08:17 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 19:15:08 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 19:15:08 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 19:29:45 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 19:29:45 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 19:49:17 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 19:49:17 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 20:02:59 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 20:02:59 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 20:05:35 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 20:05:35 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 20:09:00 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 20:09:01 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********
Sun Nov 14 20:17:57 2021 ID ffff P1 ECC CE /SYS/MB/P1/D3, 1 errors on MC1-CH1, dimm 0, rank 0.
Sun Nov 14 20:17:58 2021 ID ffff  ******** Home Agent(HA1) Shadow Errors ********

There are a lot of mce log we can check from the mcelog file. Indeed, this is a HW issue and some part is defective one, almost is memory. But a lot of vender don’t want to replace it for this is a correctable error. And we can also check this error at ilom (different vendor have different name but almost of them is built by polit 3,4 arch) as bellow.

2021-11-14/20:09:00  ereport.cpu.intel.quickpath.mem_ce@/SYS/MB/P1/D3
                        count                     = 0x1
                        system_component_firmware_versions = (ILOM)5.0.1.28 r140973,(BIOS)38340900

2021-11-14/20:17:57  ereport.cpu.intel.quickpath.mem_ce@/SYS/MB/P1/D3
                        count                     = 0x1
                        system_component_firmware_versions = (ILOM)5.0.1.28 r140973,(BIOS)38340900

If you want to disable them for some monitor policy pls check as bellow

Solution:

Machine Check Exception
   mce=off
        Disable machine check
   mce=no_cmci
        Disable CMCI(Corrected Machine Check Interrupt) that
        Intel processor supports.  Usually this disablement is
        not recommended, but it might be handy if your hardware
        is misbehaving.
        Note that you’ll get more problems without CMCI than with
        due to the shared banks, i.e. you might get duplicated
        error logs.
   mce=dont_log_ce
        Don’t make logs for corrected errors.  All events reported
        as corrected are silently cleared by OS.
        This option will be useful if you have no interest in any
        of corrected errors.
   mce=ignore_ce
        Disable features for corrected errors, e.g. polling timer
        and CMCI.  All events reported as corrected are not cleared
        by OS and remained in its error banks.
        Usually this disablement is not recommended, however if
        there is an agent checking/clearing corrected errors
        (e.g. BIOS or hardware monitoring applications), conflicting
        with OS’s error handling, and you cannot deactivate the agent,
        then this option will be a help.
   mce=bootlog
        Enable logging of machine checks left over from booting.
        Disabled by default on AMD because some BIOS leave bogus ones.
        If your BIOS doesn’t do that it’s a good idea to enable though
        to make sure you log even machine check events that result
        in a reboot. On Intel systems it is enabled by default.
   mce=nobootlog
        Disable boot machine check logging.
   mce=tolerancelevel[,monarchtimeout] (number,number)
        tolerance levels:
        0: always panic on uncorrected errors, log corrected errors
        1: panic or SIGBUS on uncorrected errors, log corrected errors
        2: SIGBUS or log uncorrected errors, log corrected errors
        3: never panic or SIGBUS, log all errors (for testing only)
        Default is 1
        Can be also set using sysfs which is preferable.
        monarchtimeout:
        Sets the time in us to wait for other CPUs on machine checks. 0
        to disable.

The mcelog is loging to message by default but you want to check this HW issue separately, audit the /etc/mcelog/mcelog.conf as bellow.
Before:
/usr/sbin/mcelog –ignorenodev –syslog –foreground

After:
/usr/sbin/mcelog –ignorenodev –syslog –foreground –logfile=/var/log/mcelog
Now restart the service
#service mcelog restart
You can find the /var/log/mcelog as expected.
 

[BUG-mybatis-plus] org.postgresql.util.PSQLException: ERROR: syntax error at or near “current_date“

Environmental Science:

         spring cloud   + Mybatis-plus + postgresql

Scenario:

  Prompt during table insertion

         org.postgresql.util.PSQLException: ERROR: syntax error at or near “current_date”

  Causes:

         current_ Date() is the method of SQL, current_ Date is the method name

resolvent:

         current_ Change date to create_ Date (optional here, not the method name)

Analysis process:

         The Error statement in XML file and navigator displays current_ Date is green (keyword color)