1

While building mariadb in Amazon linux 2 from a code repo (its not sudo yum install from mariadb external source), I am getting this error as below. Looks like the authentication setup/parameter/code issue. Can someone help?

I have found this link: https://fossies.org/linux/mariadb/plugin/auth_gssapi/README.md But not sure should I do all these or not, as I am pretty new in linux. Also the file(gssapi_server.cc) which error refers to is this : https://fossies.org/linux/mariadb/plugin/auth_gssapi/gssapi_server.cc

Also how to make sure even if the build is failed the Mariadb might work, how to check if the database got installed or not?

src/plugin/auth_gssapi/gssapi_server.cc:34:38: error: ‘krb5_xfree’ was not declared in this scope
 #define krb5_free_unparsed_name(a,b) krb5_xfree(b)
                                      ^
src/plugin/auth_gssapi/gssapi_server.cc:79:5: note: in expansion of macro ‘krb5_free_unparsed_name’
     krb5_free_unparsed_name(context, unparsed_name);
     ^~~~~~~~~~~~~~~~~~~~~~~
src/plugin/auth_gssapi/gssapi_server.cc:34:38: note: suggested alternative: ‘krb5_cred’
 #define krb5_free_unparsed_name(a,b) krb5_xfree(b)
                                      ^
src/plugin/auth_gssapi/gssapi_server.cc:79:5: note: in expansion of macro ‘krb5_free_unparsed_name’
     krb5_free_unparsed_name(context, unparsed_name);
     ^~~~~~~~~~~~~~~~~~~~~~~

Also another error is appearing multiple times in my build log as below:

    [42/1134] /usr/bin/g++  -DFORCE_INIT_OF_VARS -DGZ_SUPPORT -DHAVE_CONFIG_H -DHUGE_SUPPORT -DLIBXML2_SUPPORT -DLINUX -DMARIADB -DMYSQL_DYNAMIC_PLUGIN -DNOCRYPT -DUBUNTU -DUNIX -DVCT_SUPPORT -DXMAP -DZIP_SUPPORT -D_FILE_OFFSET_BITS=64 -Dconnect_EXPORTS -Isrc/wsrep-lib/include -Isrc/wsrep-lib/wsrep-API/v26 -Iinclude -Isrc/include -Isrc/sql -Ipcre -Isrc/pcre -Iextra/wolfssl -Isrc/extra/wolfssl/wolfssl -Isrc/extra/wolfssl/wolfssl/wolfssl -I/local/home/-pkg-cache/packages/Libxml2/Libxml2-2.9.x.312246.0/AL2_x86_64/DEV.STD.PTHREAD/build/include/libxml2 -I/local/home/-pkg-cache/packages/Zlib/Zlib-1.289527.0/AL2_x86_64/DEV.STD.PTHREAD/build/include -I/home/workplace/MariaDB/build/MariaDB/MariaDB-10.4.x/AL2_x86_64/DEV.STD.PTHREAD/build/private/tmp/-path/build.libfarm/include -L/home/workplace/MariaDB/build/MariaDB/MariaDB-10.4.x/AL2_x86_64/DEV.STD.PTHREAD/build/private/tmp/-path/build.libfarm/lib -pie -fPIC -Wl,-z,relro,-z,now -fstack-protector --param=ssp-buffer-size=4 -Wall -Wmissing-declarations -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=unused-value -Wno-error=parentheses -Wno-error=strict-aliasing -Wno-error=misleading-indentation -Wno-error=format-truncation -Wno-error=implicit-fallthrough -Wno-error=type-limits -fpermissive -fexceptions -fPIC  -O3 -DNDEBUG -D_FORTIFY_SOURCE=2 -DDBUG_OFF -fPIC   -std=gnu++11 -MD -MT storage/connect/CMakeFiles/connect.dir/maputil.cpp.o -MF storage/connect/CMakeFiles/connect.dir/maputil.cpp.o.d -o storage/connect/CMakeFiles/connect.dir/maputil.cpp.o -c src/storage/connect/maputil.cpp
src/storage/connect/maputil.cpp: In function ‘bool CloseMemMap(void*, size_t)’:
src/storage/connect/maputil.cpp:193:9: warning: unused variable ‘rc’ [-Wunused-variable]
     int rc = msync((char*)memory, dwSize, MS_SYNC);
         ^~
         
[44/1134] /usr/bin/g++  -DFORCE_INIT_OF_VARS -DGZ_SUPPORT -DHAVE_CONFIG_H -DHUGE_SUPPORT -DLIBXML2_SUPPORT -DLINUX -DMARIADB -DMYSQL_DYNAMIC_PLUGIN -DNOCRYPT -DUBUNTU -DUNIX -DVCT_SUPPORT -DXMAP -DZIP_SUPPORT -D_FILE_OFFSET_BITS=64 -Dconnect_EXPORTS -Isrc/wsrep-lib/include -Isrc/wsrep-lib/wsrep-API/v26 -Iinclude -Isrc/include -Isrc/sql -Ipcre -Isrc/pcre -Iextra/wolfssl -Isrc/extra/wolfssl/wolfssl -Isrc/extra/wolfssl/wolfssl/wolfssl -I/local/home/-pkg-cache/packages/Libxml2/Libxml2-2.9.x.312246.0/AL2_x86_64/DEV.STD.PTHREAD/build/include/libxml2 -I/local/home/-pkg-cache/packages/Zlib/Zlib-1.289527.0/AL2_x86_64/DEV.STD.PTHREAD/build/include -I/home/workplace/MariaDB/build/MariaDB/MariaDB-10.4.x/AL2_x86_64/DEV.STD.PTHREAD/build/private/tmp/-path/build.libfarm/include -L/home/workplace/MariaDB/build/MariaDB/MariaDB-10.4.x/AL2_x86_64/DEV.STD.PTHREAD/build/private/tmp/-path/build.libfarm/lib -pie -fPIC -Wl,-z,relro,-z,now -fstack-protector --param=ssp-buffer-size=4 -Wall -Wmissing-declarations -Wno-error=unused-function -Wno-error=unused-variable -Wno-error=unused-value -Wno-error=parentheses -Wno-error=strict-aliasing -Wno-error=misleading-indentation -Wno-error=format-truncation -Wno-error=implicit-fallthrough -Wno-error=type-limits -fpermissive -fexceptions -fPIC  -O3 -DNDEBUG -D_FORTIFY_SOURCE=2 -DDBUG_OFF -fPIC   -std=gnu++11 -MD -MT storage/connect/CMakeFiles/connect.dir/myutil.cpp.o -MF storage/connect/CMakeFiles/connect.dir/myutil.cpp.o.d -o storage/connect/CMakeFiles/connect.dir/myutil.cpp.o -c src/storage/connect/myutil.cpp        


     
John Rotenstein
  • 241,921
  • 22
  • 380
  • 470
dbNovice
  • 399
  • 2
  • 4
  • 18

1 Answers1

2

The database failed to compile so it won't be usable.

The mariadb source checks for krb5_xfree in the header krb5.h at configure time (plugin/auth_gssapi/CMakeLists.txt), so this is odd that is not there at compile time.

Most likely you won't need the gssapi. Its an optional authentication extension. Use the cmake configure option -DPLUGIN_AUTH_GSSAPI=NO to disable the building of this plugin

Yes, the storage engine connect has a few warnings to clean up.

danblack
  • 12,130
  • 2
  • 22
  • 41