From 01234720e7ce2ee117603964a66d68ab1ffc28dc Mon Sep 17 00:00:00 2001 From: Steven Li <88397429+sfc-gh-stli@users.noreply.github.com> Date: Fri, 8 Apr 2022 13:00:57 -0700 Subject: [PATCH] update prerelease package format (#6733) --- CMakeLists.txt | 5 +++ cmake/InstallLayout.cmake | 43 +++++++++++----------- packaging/multiversion/clients/postinst | 20 +++++----- packaging/multiversion/clients/prerm | 2 +- packaging/multiversion/server/postinst-deb | 8 ++-- packaging/multiversion/server/postinst-rpm | 8 ++-- packaging/multiversion/server/prerm | 2 +- 7 files changed, 47 insertions(+), 41 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e07a9c9ac3..d5ce5de14a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -91,6 +91,11 @@ if (FDB_RELEASE_CANDIDATE) else() set(FDB_VERSION ${PROJECT_VERSION}) endif() +if (NOT FDB_RELEASE) + string(TIMESTAMP FDB_BUILDTIME %Y%m%d%H%M%S) + set(FDB_BUILDTIME_STRING ".${FDB_BUILDTIME}") + set(PRERELEASE_TAG "prerelease") +endif() set(FDB_VERSION_PLAIN ${FDB_VERSION}) string(REPLACE "." ";" FDB_VERSION_LIST ${FDB_VERSION_PLAIN}) list(GET FDB_VERSION_LIST 0 FDB_MAJOR) diff --git a/cmake/InstallLayout.cmake b/cmake/InstallLayout.cmake index 9d8f5b9553..568b4c51fe 100644 --- a/cmake/InstallLayout.cmake +++ b/cmake/InstallLayout.cmake @@ -105,7 +105,7 @@ install_destinations(TGZ ETC etc/foundationdb LOG log/foundationdb DATA lib/foundationdb) -copy_install_destinations(TGZ VERSIONED PREFIX "usr/lib/foundationdb-${FDB_VERSION}/") +copy_install_destinations(TGZ VERSIONED PREFIX "usr/lib/foundationdb-${FDB_VERSION}${FDB_BUILDTIME_STRING}/") install_destinations(DEB BIN usr/bin SBIN usr/sbin @@ -207,12 +207,12 @@ set(CPACK_COMPONENT_SERVER-VERSIONED_DEPENDS clients-versioned) set(CPACK_COMPONENT_SERVER-EL7_DISPLAY_NAME "foundationdb-server") set(CPACK_COMPONENT_SERVER-DEB_DISPLAY_NAME "foundationdb-server") set(CPACK_COMPONENT_SERVER-TGZ_DISPLAY_NAME "foundationdb-server") -set(CPACK_COMPONENT_SERVER-VERSIONED_DISPLAY_NAME "foundationdb${FDB_VERSION}-server") +set(CPACK_COMPONENT_SERVER-VERSIONED_DISPLAY_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-server") set(CPACK_COMPONENT_CLIENTS-EL7_DISPLAY_NAME "foundationdb-clients") set(CPACK_COMPONENT_CLIENTS-DEB_DISPLAY_NAME "foundationdb-clients") set(CPACK_COMPONENT_CLIENTS-TGZ_DISPLAY_NAME "foundationdb-clients") -set(CPACK_COMPONENT_CLIENTS-VERSIONED_DISPLAY_NAME "foundationdb${FDB_VERSION}-clients") +set(CPACK_COMPONENT_CLIENTS-VERSIONED_DISPLAY_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-clients") # MacOS needs a file extension for the LICENSE file @@ -224,10 +224,11 @@ configure_file(${CMAKE_SOURCE_DIR}/LICENSE ${CMAKE_BINARY_DIR}/License.txt COPYO if(NOT FDB_RELEASE) if(CURRENT_GIT_VERSION) - set(git_string ".${CURRENT_GIT_VERSION}") + string(SUBSTRING ${CURRENT_GIT_VERSION} 0 9 git_hash) endif() set(CPACK_RPM_PACKAGE_RELEASE 0) - set(package_version_postfix "-0${git_string}.SNAPSHOT") + set(package_version_postfix "-0.${git_hash}.SNAPSHOT") + set(git_string ".${git_hash}") else() set(CPACK_RPM_PACKAGE_RELEASE 1) set(package_version_postfix "-1") @@ -258,16 +259,16 @@ set(CPACK_RPM_SERVER-EL7_USER_FILELIST "%config(noreplace) / "%attr(0700,foundationdb,foundationdb) /var/log/foundationdb" "%attr(0700,foundationdb,foundationdb) /var/lib/foundationdb") -set(CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME "${CPACK_RPM_PACKAGE_NAME}${FDB_PACKAGE_VERSION}-clients") -set(CPACK_RPM_CLIENTS-VERSIONED_FILE_NAME "${CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME}${package_version_postfix}.versioned.${CMAKE_SYSTEM_PROCESSOR}.rpm") -set(CPACK_RPM_CLIENTS-VERSIONED_DEBUGINFO_FILE_NAME "${CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME}${package_version_postfix}.versioned-debuginfo.${CMAKE_SYSTEM_PROCESSOR}.rpm") +set(CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME "${CPACK_RPM_PACKAGE_NAME}${FDB_PACKAGE_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-clients") +set(CPACK_RPM_CLIENTS-VERSIONED_FILE_NAME "${CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME}${git_string}.versioned.${CMAKE_SYSTEM_PROCESSOR}.rpm") +set(CPACK_RPM_CLIENTS-VERSIONED_DEBUGINFO_FILE_NAME "${CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME}${git_string}.versioned-debuginfo.${CMAKE_SYSTEM_PROCESSOR}.rpm") set(CPACK_RPM_CLIENTS-VERSIONED_POST_INSTALL_SCRIPT_FILE ${CMAKE_BINARY_DIR}/packaging/multiversion/clients/postinst-el7) set(CPACK_RPM_CLIENTS-VERSIONED_PRE_UNINSTALL_SCRIPT_FILE ${CMAKE_BINARY_DIR}/packaging/multiversion/clients/prerm) -set(CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME "${CPACK_RPM_PACKAGE_NAME}${FDB_PACKAGE_VERSION}-server") -set(CPACK_RPM_SERVER-VERSIONED_FILE_NAME "${CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME}${package_version_postfix}.versioned.${CMAKE_SYSTEM_PROCESSOR}.rpm") -set(CPACK_RPM_SERVER-VERSIONED_DEBUGINFO_FILE_NAME "${CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME}${package_version_postfix}.versioned-debuginfo.${CMAKE_SYSTEM_PROCESSOR}.rpm") -set(CPACK_RPM_SERVER-VERSIONED_PACKAGE_REQUIRES "${CPACK_RPM_CLIENTS-VERSIONED_PACKAGE_NAME}") +set(CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME "${CPACK_RPM_PACKAGE_NAME}${FDB_PACKAGE_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-server") +set(CPACK_RPM_SERVER-VERSIONED_FILE_NAME "${CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME}${git_string}.versioned.${CMAKE_SYSTEM_PROCESSOR}.rpm") +set(CPACK_RPM_SERVER-VERSIONED_DEBUGINFO_FILE_NAME "${CPACK_RPM_SERVER-VERSIONED_PACKAGE_NAME}${git_string}.versioned-debuginfo.${CMAKE_SYSTEM_PROCESSOR}.rpm") +set(CPACK_RPM_SERVER-VERSIONED_PACKAGE_REQUIRES "${CPACK_COMPONENT_CLIENTS-VERSIONED_DISPLAY_NAME}") set(CPACK_RPM_SERVER-VERSIONED_POST_INSTALL_SCRIPT_FILE ${CMAKE_BINARY_DIR}/packaging/multiversion/server/postinst-rpm) set(CPACK_RPM_SERVER-VERSIONED_PRE_UNINSTALL_SCRIPT_FILE ${CMAKE_BINARY_DIR}/packaging/multiversion/server/prerm) @@ -295,7 +296,7 @@ set(CPACK_RPM_EXCLUDE_FROM_AUTO_FILELIST_ADDITION "/usr/lib/pkgconfig" "/usr/lib/foundationdb" "/usr/lib/cmake" - "/usr/lib/foundationdb-${FDB_VERSION}/etc/foundationdb" + "/usr/lib/foundationdb-${FDB_VERSION}${FDB_BUILDTIME_STRING}/etc/foundationdb" ) set(CPACK_RPM_DEBUGINFO_PACKAGE ${GENERATE_DEBUG_PACKAGES}) #set(CPACK_RPM_BUILD_SOURCE_FDB_INSTALL_DIRS_PREFIX /usr/src) @@ -308,13 +309,13 @@ set(CPACK_RPM_COMPONENT_INSTALL ON) if (CMAKE_SYSTEM_PROCESSOR MATCHES "x86_64") set(CPACK_DEBIAN_CLIENTS-DEB_FILE_NAME "foundationdb-clients_${FDB_VERSION}${package_version_postfix}_amd64.deb") set(CPACK_DEBIAN_SERVER-DEB_FILE_NAME "foundationdb-server_${FDB_VERSION}${package_version_postfix}_amd64.deb") - set(CPACK_DEBIAN_CLIENTS-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}-clients${package_version_postfix}.versioned_amd64.deb") - set(CPACK_DEBIAN_SERVER-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}-server${package_version_postfix}.versioned_amd64.deb") + set(CPACK_DEBIAN_CLIENTS-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-clients${git_string}.versioned_amd64.deb") + set(CPACK_DEBIAN_SERVER-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-server${git_string}.versioned_amd64.deb") else() set(CPACK_DEBIAN_CLIENTS-DEB_FILE_NAME "foundationdb-clients_${FDB_VERSION}${package_version_postfix}_${CMAKE_SYSTEM_PROCESSOR}.deb") set(CPACK_DEBIAN_SERVER-DEB_FILE_NAME "foundationdb-server_${FDB_VERSION}${package_version_postfix}_${CMAKE_SYSTEM_PROCESSOR}.deb") - set(CPACK_DEBIAN_CLIENTS-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}-clients${package_version_postfix}.versioned_${CMAKE_SYSTEM_PROCESSOR}.deb") - set(CPACK_DEBIAN_SERVER-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}-server${package_version_postfix}.versioned_${CMAKE_SYSTEM_PROCESSOR}.deb") + set(CPACK_DEBIAN_CLIENTS-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-clients${git_string}.versioned_${CMAKE_SYSTEM_PROCESSOR}.deb") + set(CPACK_DEBIAN_SERVER-VERSIONED_FILE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-server${git_string}.versioned_${CMAKE_SYSTEM_PROCESSOR}.deb") endif() set(CPACK_DEB_COMPONENT_INSTALL ON) @@ -324,8 +325,8 @@ set(CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS ON) set(CPACK_DEBIAN_SERVER-DEB_PACKAGE_NAME "foundationdb-server") set(CPACK_DEBIAN_CLIENTS-DEB_PACKAGE_NAME "foundationdb-clients") -set(CPACK_DEBIAN_SERVER-VERSIONED_PACKAGE_NAME "foundationdb${FDB_VERSION}-server") -set(CPACK_DEBIAN_CLIENTS-VERSIONED_PACKAGE_NAME "foundationdb${FDB_VERSION}-clients") +set(CPACK_DEBIAN_SERVER-VERSIONED_PACKAGE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-server") +set(CPACK_DEBIAN_CLIENTS-VERSIONED_PACKAGE_NAME "foundationdb${FDB_VERSION}${FDB_BUILDTIME_STRING}${PRERELEASE_TAG}-clients") set(CPACK_DEBIAN_SERVER-DEB_PACKAGE_DEPENDS "adduser, libc6 (>= 2.12), foundationdb-clients (= ${FDB_VERSION})") set(CPACK_DEBIAN_SERVER-DEB_PACKAGE_RECOMMENDS "python (>= 2.6)") @@ -379,10 +380,10 @@ if(NOT WIN32) RENAME "foundationdb" COMPONENT server-deb) install(FILES ${CMAKE_SOURCE_DIR}/packaging/rpm/foundationdb.service - DESTINATION "usr/lib/foundationdb-${FDB_VERSION}/lib/systemd/system" + DESTINATION "usr/lib/foundationdb-${FDB_VERSION}${FDB_BUILDTIME_STRING}/lib/systemd/system" COMPONENT server-versioned) install(PROGRAMS ${CMAKE_SOURCE_DIR}/packaging/deb/foundationdb-init - DESTINATION "usr/lib/foundationdb-${FDB_VERSION}/etc/init.d" + DESTINATION "usr/lib/foundationdb-${FDB_VERSION}${FDB_BUILDTIME_STRING}/etc/init.d" RENAME "foundationdb" COMPONENT server-versioned) endif() diff --git a/packaging/multiversion/clients/postinst b/packaging/multiversion/clients/postinst index 149fdd2865..52e33d4b1c 100644 --- a/packaging/multiversion/clients/postinst +++ b/packaging/multiversion/clients/postinst @@ -14,13 +14,13 @@ fi mkdir -p /usr/lib/foundationdb/backup_agent -update-alternatives --install /usr/bin/fdbcli fdbclients /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbcli @ALTERNATIVES_PRIORITY@ \ - --slave /usr/bin/fdbbackup fdbbackup /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbbackup \ - --slave /usr/bin/fdbrestore fdbrestore /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbbackup \ - --slave /usr/bin/dr_agent dr_agent /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbbackup \ - --slave /usr/bin/fdbdr fdbdr /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbbackup \ - --slave /usr/lib/foundationdb/backup_agent/backup_agent backup_agent /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbbackup \ - --slave /usr/@LIB_DIR@/libfdb_c.so libfdb_c /usr/lib/foundationdb-@FDB_VERSION@/lib/libfdb_c.so \ - --slave /usr/@LIB_DIR@/pkgconfig/foundationdb-client.pc foundationdb-client.pc /usr/lib/foundationdb-@FDB_VERSION@/lib/pkgconfig/foundationdb-client.pc \ - --slave /usr/@LIB_DIR@/cmake/FoundationDB-Client FoundationDB-ClientConfig /usr/lib/foundationdb-@FDB_VERSION@/lib/cmake/FoundationDB-Client \ - --slave /usr/include/foundationdb fdb-client-headers /usr/lib/foundationdb-@FDB_VERSION@/include/foundationdb +update-alternatives --install /usr/bin/fdbcli fdbclients /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbcli @ALTERNATIVES_PRIORITY@ \ + --slave /usr/bin/fdbbackup fdbbackup /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbbackup \ + --slave /usr/bin/fdbrestore fdbrestore /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbbackup \ + --slave /usr/bin/dr_agent dr_agent /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbbackup \ + --slave /usr/bin/fdbdr fdbdr /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbbackup \ + --slave /usr/lib/foundationdb/backup_agent/backup_agent backup_agent /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbbackup \ + --slave /usr/@LIB_DIR@/libfdb_c.so libfdb_c /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/lib/libfdb_c.so \ + --slave /usr/@LIB_DIR@/pkgconfig/foundationdb-client.pc foundationdb-client.pc /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/lib/pkgconfig/foundationdb-client.pc \ + --slave /usr/@LIB_DIR@/cmake/FoundationDB-Client FoundationDB-ClientConfig /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/lib/cmake/FoundationDB-Client \ + --slave /usr/include/foundationdb fdb-client-headers /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/include/foundationdb diff --git a/packaging/multiversion/clients/prerm b/packaging/multiversion/clients/prerm index 3bdce848a5..0a87f23754 100644 --- a/packaging/multiversion/clients/prerm +++ b/packaging/multiversion/clients/prerm @@ -1,3 +1,3 @@ #!/usr/bin/env bash -update-alternatives --remove fdbclients /usr/lib/foundationdb-@FDB_VERSION@/bin/fdbcli +update-alternatives --remove fdbclients /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/bin/fdbcli diff --git a/packaging/multiversion/server/postinst-deb b/packaging/multiversion/server/postinst-deb index d4b3c57436..5a9ac5c642 100644 --- a/packaging/multiversion/server/postinst-deb +++ b/packaging/multiversion/server/postinst-deb @@ -7,16 +7,16 @@ mkdir -p /var/lib/foundationdb/data /var/log/foundationdb chown -R foundationdb:foundationdb /var/lib/foundationdb /var/log/foundationdb chmod -R 0750 /var/lib/foundationdb/data /var/log/foundationdb -update-alternatives --install /usr/sbin/fdbserver fdbserver /usr/lib/foundationdb-@FDB_VERSION@/sbin/fdbserver @ALTERNATIVES_PRIORITY@ \ - --slave /usr/lib/foundationdb/fdbmonitor fdbmonitor /usr/lib/foundationdb-@FDB_VERSION@/sbin/fdbmonitor \ - --slave /etc/init.d/foundationdb foundationdb.service /usr/lib/foundationdb-@FDB_VERSION@/etc/init.d/foundationdb +update-alternatives --install /usr/sbin/fdbserver fdbserver /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/sbin/fdbserver @ALTERNATIVES_PRIORITY@ \ + --slave /usr/lib/foundationdb/fdbmonitor fdbmonitor /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/sbin/fdbmonitor \ + --slave /etc/init.d/foundationdb foundationdb.service /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/etc/init.d/foundationdb if mkdir /etc/foundationdb then description=`LC_CTYPE=C tr -dc A-Za-z0-9 < /dev/urandom | head -c 8` random_str=`LC_CTYPE=C tr -dc A-Za-z0-9 < /dev/urandom | head -c 8` echo $description:$random_str@127.0.0.1:4500 > /etc/foundationdb/fdb.cluster - cp /usr/lib/foundationdb-@FDB_VERSION@/etc/foundationdb/foundationdb.conf /etc/foundationdb/foundationdb.conf + cp /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/etc/foundationdb/foundationdb.conf /etc/foundationdb/foundationdb.conf chown -R foundationdb:foundationdb /etc/foundationdb chmod 775 /etc/foundationdb chmod 0664 /etc/foundationdb/fdb.cluster diff --git a/packaging/multiversion/server/postinst-rpm b/packaging/multiversion/server/postinst-rpm index a6c0a77aec..797d716fd3 100644 --- a/packaging/multiversion/server/postinst-rpm +++ b/packaging/multiversion/server/postinst-rpm @@ -8,16 +8,16 @@ chown -R foundationdb:foundationdb /var/lib/foundationdb /var/log/foundationdb chmod -R 0750 /var/lib/foundationdb/data /var/log/foundationdb mkdir -p /usr/lib/foundationdb -update-alternatives --install /usr/sbin/fdbserver fdbserver /usr/lib/foundationdb-@FDB_VERSION@/sbin/fdbserver @ALTERNATIVES_PRIORITY@ \ - --slave /usr/lib/foundationdb/fdbmonitor fdbmonitor /usr/lib/foundationdb-@FDB_VERSION@/sbin/fdbmonitor \ - --slave /lib/systemd/system/foundationdb.service foundationdb.service /usr/lib/foundationdb-@FDB_VERSION@/lib/systemd/system/foundationdb.service +update-alternatives --install /usr/sbin/fdbserver fdbserver /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/sbin/fdbserver @ALTERNATIVES_PRIORITY@ \ + --slave /usr/lib/foundationdb/fdbmonitor fdbmonitor /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/sbin/fdbmonitor \ + --slave /lib/systemd/system/foundationdb.service foundationdb.service /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/lib/systemd/system/foundationdb.service if mkdir /etc/foundationdb then description=`LC_CTYPE=C tr -dc A-Za-z0-9 < /dev/urandom | head -c 8` random_str=`LC_CTYPE=C tr -dc A-Za-z0-9 < /dev/urandom | head -c 8` echo $description:$random_str@127.0.0.1:4500 > /etc/foundationdb/fdb.cluster - cp /usr/lib/foundationdb-@FDB_VERSION@/etc/foundationdb/foundationdb.conf /etc/foundationdb/foundationdb.conf + cp /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/etc/foundationdb/foundationdb.conf /etc/foundationdb/foundationdb.conf chown -R foundationdb:foundationdb /etc/foundationdb chmod 775 /etc/foundationdb chmod 0664 /etc/foundationdb/fdb.cluster diff --git a/packaging/multiversion/server/prerm b/packaging/multiversion/server/prerm index 3edd30a36d..1b6f66bb1e 100644 --- a/packaging/multiversion/server/prerm +++ b/packaging/multiversion/server/prerm @@ -1,3 +1,3 @@ #!/usr/bin/env bash -update-alternatives --remove fdbserver /usr/lib/foundationdb-@FDB_VERSION@/sbin/fdbserver +update-alternatives --remove fdbserver /usr/lib/foundationdb-@FDB_VERSION@@FDB_BUILDTIME_STRING@/sbin/fdbserver