Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Version published after converting to the new editor

...

Status
colourGreen
titleLAST TESTED ON CHECKMK 2.03.0P1


Panel
borderColorblack
bgColor#f8f8f8
titleTable of Contents

Table of Contents


Warning

We do not support any modification of our config files (e.g., apache, .profile, etc.). If you do that and the site is broken, you will run out of support, especially on the Checkmk Appliance.

We saw the bottom error several times, especially when dealing with check_sql.

Error Messages

Code Block
languagebash
themeRDark
Starting apache...apache2: Syntax error on line 236 of /omd/sites/mysite/etc/apache/apache.conf
libpython3.9.so.1.0: cannot open shared object file: No such file or directory

Problem

The default for LD_LIBARY_PATH should be:

...

Code Block
languagebash
themeRDark
Starting apache...apache2: Syntax error on line 236 of /omd/sites/mysite/etc/apache/apache.conf: Syntax error on line 2 of /omd/sites/mysite/etc/apache/conf.d/01_wsgi.conf: Cannot load /omd/sites/mysite/lib/apache/modules/mod_wsgi.so into server: libpython3.9.so.1.0: cannot open shared object file: No such file or directory
..........ERROR

Solution

  1. Check if the env is right

    Code Block
    languagebash
    themeRDark
    su - mysite  
    OMD[mysite]:~$ echo $LD_LIBRARY_PATH
    /omd/sites/mysite/opt/oracle/instantclient_21_4

    In that case, the env is not correct. The env is pointing only to the libraries of the Oracle instantclient

  2. Check if the library is available.

    Code Block
    languagebash
    themeRDark
    OMD[mysite]:~$ find -L -name "*libpython3.9.so.1.0*"
    ./version/lib/libpython3.9.so.1.0
    ./lib/libpython3.9.so.1.0

    In that case, the library is only available in the origin and default path of LD_LIBRARY_PATH

  3. Restore the default variable

    You will find the original files of .profile or .bashrc in "/omd/versions/2.1.0b7.cee/skel"

    Code Block
    languagebash
    themeRDark
    ➜ /omd/versions/2.1.0b7.cee/skel ls -altr
    insgesamt 36
    -rw-r--r-- 1 root root 2055 Apr 25 00:02 .profile
    -rw-r--r-- 1 root root 1091 Apr 25 00:02 .bashrc


    One way would be to copy the LD_LIBRARY_PATH value from .profile and put it directly to the .profile of the site user:

    Code Block
    languagebash
    themeRDark
    su - mysite
    OMD[mysite]:~$ vi .profile 


    To make the changes permanent, please enter:

    Code Block
    languagebash
    themeRDark
    OMD[mysite]:~$ source .profile 


  4. set the LD_LIBARY_PATH the right way

    extend the LD_LIBRARY_PATH like that ":path/to/oracle/instanclient"

    Code Block
    languagebash
    themeRDark
    OMD[mysite]:~$ vi .profile 
    OMD[mysite]:~$ source .profile


    In the end, it should look like this:

    Code Block
    languagebash
    themeRDark
    OMD[mysite]:~$ echo $LD_LIBRARY_PATH
    /omd/sites/mysite/local/lib:/omd/sites/mysite/lib:path/to/oracle/instanclient
    
    


  5. Now after a restart of the site Apache the error should be gone!

Filter by label (Content by label)
showLabelsfalse
max5
spacesCON
showSpacefalse
sortmodified
reversetrue
typepage
cqllabel in ( "apache" , "troubleshooting" ) and type = "page" and space = "KB"
labelsapache

...