Python build finished successfully! The necessary bits to build these optional modules were not found: _dbm _gdbm To find the necessary bits, look in setup.py in detect_modules() for the module's name. The following modules found by detect_modules() in setup.py, have been built by the Makefile instead, as configured by the Setup files: atexit pwd time running build_scripts creating build/scripts-3.6 copying and adjusting /root/Python-3.6.8/Tools/scripts/pydoc3 -> build/scripts-3.6 copying and adjusting /root/Python-3.6.8/Tools/scripts/idle3 -> build/scripts-3.6 copying and adjusting /root/Python-3.6.8/Tools/scripts/2to3 -> build/scripts-3.6 copying and adjusting /root/Python-3.6.8/Tools/scripts/pyvenv -> build/scripts-3.6 changing mode of build/scripts-3.6/pydoc3 from 644 to 755 changing mode of build/scripts-3.6/idle3 from 644 to 755 changing mode of build/scripts-3.6/2to3 from 644 to 755 changing mode of build/scripts-3.6/pyvenv from 644 to 755 renaming build/scripts-3.6/pydoc3 to build/scripts-3.6/pydoc3.6 renaming build/scripts-3.6/idle3 to build/scripts-3.6/idle3.6 renaming build/scripts-3.6/2to3 to build/scripts-3.6/2to3-3.6 renaming build/scripts-3.6/pyvenv to build/scripts-3.6/pyvenv-3.6 *** glibc detected *** ./python: double free or corruption (!prev): 0x0000000001aa9d30 *** ======= Backtrace: ========= /lib/x86_64-linux-gnu/libc.so.6(+0x75bb6)[0x2b6580971bb6] /lib/x86_64-linux-gnu/libc.so.6(cfree+0x6c)[0x2b658097695c] ./python[0x426039] ./python(PyMem_Free+0x56)[0x426686] ./python(PyArena_Free+0x61)[0x6106c1] ./python(PyRun_FileExFlags+0x19c)[0x433a9c] ./python(PyRun_SimpleFileExFlags+0x162)[0x434a72] ./python(PyRun_AnyFileExFlags+0xd9)[0x4353c9] ./python(Py_Main+0x14c2)[0x4500b2] ./python(main+0x215)[0x423035] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xfd)[0x2b658091aead] ./python[0x42406d] ======= Memory map: ======== 00400000-00744000 r-xp 00000000 b6:cf411 2234624 /root/Python-3.6.8/python 00943000-00a3f000 rw-p 00343000 b6:cf411 2234624 /root/Python-3.6.8/python 00a3f000-00b37000 rw-p 00000000 00:00 0 019cf000-01d1d000 rw-p 00000000 00:00 0 [heap] 2b657fc2b000-2b657fc4b000 r-xp 00000000 b6:cf411 4594294 /lib/x86_64-linux-gnu/ld-2.13.so 2b657fc4b000-2b657fd8d000 rw-p 00000000 00:00 0 2b657fdb2000-2b657fe32000 rw-p 00000000 00:00 0 2b657fe4a000-2b657fe4b000 r--p 0001f000 b6:cf411 4594294 /lib/x86_64-linux-gnu/ld-2.13.so 2b657fe4b000-2b657fe4c000 rw-p 00020000 b6:cf411 4594294 /lib/x86_64-linux-gnu/ld-2.13.so 2b657fe4c000-2b657fe4d000 rw-p 00000000 00:00 0 2b657fe4d000-2b657fe64000 r-xp 00000000 b6:cf411 4594293 /lib/x86_64-linux-gnu/libpthread-2.13.so 2b657fe64000-2b6580063000 ---p 00017000 b6:cf411 4594293 /lib/x86_64-linux-gnu/libpthread-2.13.so 2b6580063000-2b6580064000 r--p 00016000 b6:cf411 4594293 /lib/x86_64-linux-gnu/libpthread-2.13.so 2b6580064000-2b6580065000 rw-p 00017000 b6:cf411 4594293 /lib/x86_64-linux-gnu/libpthread-2.13.so 2b6580065000-2b6580069000 rw-p 00000000 00:00 0 2b6580069000-2b658006b000 r-xp 00000000 b6:cf411 4594300 /lib/x86_64-linux-gnu/libdl-2.13.so 2b658006b000-2b658026b000 ---p 00002000 b6:cf411 4594300 /lib/x86_64-linux-gnu/libdl-2.13.so 2b658026b000-2b658026c000 r--p 00002000 b6:cf411 4594300 /lib/x86_64-linux-gnu/libdl-2.13.so 2b658026c000-2b658026d000 rw-p 00003000 b6:cf411 4594300 /lib/x86_64-linux-gnu/libdl-2.13.so 2b658026d000-2b658026e000 rw-p 00000000 00:00 0 2b658026e000-2b6580270000 r-xp 00000000 b6:cf411 4594318 /lib/x86_64-linux-gnu/libutil-2.13.so 2b6580270000-2b658046f000 ---p 00002000 b6:cf411 4594318 /lib/x86_64-linux-gnu/libutil-2.13.so 2b658046f000-2b6580470000 r--p 00001000 b6:cf411 4594318 /lib/x86_64-linux-gnu/libutil-2.13.so 2b6580470000-2b6580471000 rw-p 00002000 b6:cf411 4594318 /lib/x86_64-linux-gnu/libutil-2.13.so 2b6580471000-2b6580478000 r-xp 00000000 b6:cf411 4594315 /lib/x86_64-linux-gnu/librt-2.13.so 2b6580478000-2b6580677000 ---p 00007000 b6:cf411 4594315 /lib/x86_64-linux-gnu/librt-2.13.so 2b6580677000-2b6580678000 r--p 00006000 b6:cf411 4594315 /lib/x86_64-linux-gnu/librt-2.13.so 2b6580678000-2b6580679000 rw-p 00007000 b6:cf411 4594315 /lib/x86_64-linux-gnu/librt-2.13.so 2b6580679000-2b65806fa000 r-xp 00000000 b6:cf411 4594301 /lib/x86_64-linux-gnu/libm-2.13.so 2b65806fa000-2b65808f9000 ---p 00081000 b6:cf411 4594301 /lib/x86_64-linux-gnu/libm-2.13.so 2b65808f9000-2b65808fa000 r--p 00080000 b6:cf411 4594301 /lib/x86_64-linux-gnu/libm-2.13.so 2b65808fa000-2b65808fb000 rw-p 00081000 b6:cf411 4594301 /lib/x86_64-linux-gnu/libm-2.13.so 2b65808fb000-2b65808fc000 rw-p 00000000 00:00 0 2b65808fc000-2b6580a80000 r-xp 00000000 b6:cf411 4594297 /lib/x86_64-linux-gnu/libc-2.13.so 2b6580a80000-2b6580c7f000 ---p 00184000 b6:cf411 4594297 /lib/x86_64-linux-gnu/libc-2.13.so 2b6580c7f000-2b6580c83000 r--p 00183000 b6:cf411 4594297 /lib/x86_64-linux-gnu/libc-2.13.so 2b6580c83000-2b6580c84000 rw-p 00187000 b6:cf411 4594297 /lib/x86_64-linux-gnu/libc-2.13.so 2b6580c84000-2b6580dcc000 rw-p 00000000 00:00 0 2b6580e0c000-2b6580ecc000 rw-p 00000000 00:00 0 2b6580ef5000-2b6580f75000 rw-p 00000000 00:00 0 2b6580f8c000-2b658120c000 rw-p 00000000 00:00 0 2b658120c000-2b658120d000 ---p 00000000 00:00 0 2b658120d000-2b658140d000 rw-p 00000000 00:00 0 2b658140d000-2b658140e000 ---p 00000000 00:00 0 2b658140e000-2b658160e000 rw-p 00000000 00:00 0 2b6581623000-2b6581638000 r-xp 00000000 b6:cf411 4603875 /lib/x86_64-linux-gnu/libgcc_s.so.1 2b6581638000-2b6581838000 ---p 00015000 b6:cf411 4603875 /lib/x86_64-linux-gnu/libgcc_s.so.1 2b6581838000-2b6581839000 rw-p 00015000 b6:cf411 4603875 /lib/x86_64-linux-gnu/libgcc_s.so.1 2b6581839000-2b658184a000 r-xp 00000000 b6:cf411 2235347 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_struct.cpython-36m-x86_64-linux-gnu.so 2b658184a000-2b6581a4a000 ---p 00011000 b6:cf411 2235347 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_struct.cpython-36m-x86_64-linux-gnu.so 2b6581a4a000-2b6581a50000 rw-p 00011000 b6:cf411 2235347 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_struct.cpython-36m-x86_64-linux-gnu.so 2b6581a50000-2b6581a53000 rw-p 00000000 00:00 0 2b6581a53000-2b6581a5e000 r-xp 00000000 b6:cf411 2235284 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_ctypes_test.cpython-36m-x86_64-linux-gnu.so 2b6581a5e000-2b6581c5e000 ---p 0000b000 b6:cf411 2235284 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_ctypes_test.cpython-36m-x86_64-linux-gnu.so 2b6581c5e000-2b6581c62000 rw-p 0000b000 b6:cf411 2235284 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/_ctypes_test.cpython-36m-x86_64-linux-gnu.so 2b6581c62000-2b6581c63000 rw-p 00000000 00:00 0 2b6581c63000-2b6581c77000 r-xp 00000000 b6:cf411 2235349 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/array.cpython-36m-x86_64-linux-gnu.so 2b6581c77000-2b6581e77000 ---p 00014000 b6:cf411 2235349 /root/Python-3.6.8/build/lib.linux-x86_64-3.6/array.cpython-36m-x86_64-linux-gnu.so/bin/sh: line 9: 9025 Aborted CC='gcc -pthread' LDSHARED='gcc -pthread -shared -fprofile-generate' OPT='-DNDEBUG -g -fwrapv -O3 -Wall' _TCLTK_INCLUDES='' _TCLTK_LIBS='' ./python -E ./setup.py $quiet build make[2]: *** [sharedmods] Error 134 make[2]: Leaving directory `/root/Python-3.6.8' make[1]: *** [build_all_generate_profile] Error 2 make[1]: Leaving directory `/root/Python-3.6.8' make: *** [profile-opt] Error 2