Skip to content

Commit

Permalink
Support info added
Browse files Browse the repository at this point in the history
  • Loading branch information
pstorz committed Jan 25, 2019
1 parent 6d2b9a5 commit 3e0dcb9
Show file tree
Hide file tree
Showing 17 changed files with 97 additions and 34 deletions.
9 changes: 8 additions & 1 deletion core/CMakeLists.txt
Expand Up @@ -46,7 +46,10 @@ endif()

set(CMAKE_MODULE_PATH
${CMAKE_MODULE_PATH}
${PROJECT_SOURCE_DIR}/cmake)
${PROJECT_SOURCE_DIR}/../../SOURCES
${PROJECT_SOURCE_DIR}/../SOURCES
${PROJECT_SOURCE_DIR}/cmake
)

SET(host ${CMAKE_SYSTEM})

Expand All @@ -72,6 +75,7 @@ execute_process(
INCLUDE(BareosExtractVersionInfo)
add_definitions(-DVERSION="${BAREOS_FULL_VERSION}")

INCLUDE(BareosLocalBuildDefinitions RESULT_VARIABLE BareosLocalBuildDefinitionsFile)

INCLUDE(BareosFindAllLibraries)

Expand Down Expand Up @@ -185,6 +189,8 @@ IF (${CMAKE_SYSTEM_NAME} MATCHES "Windows")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -m${WINDOWS_BITS} -mwin32 -mthreads")
ENDIF()



# set INSTALL_LIB_DIR automatically to lib or lib64 automatically
# Taken from https://cmake.org/pipermail/cmake/2013-July/055374.html

Expand Down Expand Up @@ -712,6 +718,7 @@ message(" GAWK: ${GAWK}")
message(" RPCGEN: ${RPCGEN}")
message(" MTX: ${MTX}")
message(" DEVELOPER: ${developer}")
message(" LocalBuildDefinitionsFile ${BareosLocalBuildDefinitionsFile}")

IF(HAVE_WIN32)
message(" WINDOWS_VERSION: ${WINDOWS_VERSION}")
Expand Down
9 changes: 9 additions & 0 deletions core/cmake/BareosSetVariableDefaults.cmake
Expand Up @@ -553,6 +553,15 @@ SET(PACKAGE_VERSION "\"${BAREOS_NUMERIC_VERSION}\"")

set(ENABLE_NLS 1)

if(DEFINED ENV{BAREOS_VENDORSUPPORT_STATUS})
add_definitions(-DBAREOS_VENDORSUPPORT_STATUS="$ENV{BAREOS_VENDORSUPPORT_STATUS}")
endif()

if(DEFINED ENV{BAREOS_VENDORSUPPORT_MESSAGE})
add_definitions(-DBAREOS_VENDORSUPPORT_MESSAGE="$ENV{BAREOS_VENDORSUPPORT_MESSAGE}")
endif()


IF(HAVE_WIN32)

IF(NOT DEFINED WINDOWS_VERSION)
Expand Down
4 changes: 3 additions & 1 deletion core/src/dird/admin.cc
Expand Up @@ -2,7 +2,7 @@
BAREOS® - Backup Archiving REcovery Open Sourced
Copyright (C) 2003-2012 Free Software Foundation Europe e.V.
Copyright (C) 2016-2018 Bareos GmbH & Co. KG
Copyright (C) 2016-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -118,13 +118,15 @@ void AdminCleanup(JobControlRecord *jcr, int TermCode)
" Scheduled time: %s\n"
" Start time: %s\n"
" End time: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
edt,
jcr->jr.JobId,
jcr->jr.Job,
schedt,
sdt,
edt,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);

Dmsg0(debuglevel, "Leave AdminCleanup()\n");
Expand Down
4 changes: 3 additions & 1 deletion core/src/dird/archive.cc
@@ -1,7 +1,7 @@
/*
BAREOS® - Backup Archiving REcovery Open Sourced
Copyright (C) 2016-2016 Bareos GmbH & Co. KG
Copyright (C) 2016-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -117,13 +117,15 @@ void ArchiveCleanup(JobControlRecord *jcr, int TermCode)
" Scheduled time: %s\n"
" Start time: %s\n"
" End time: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
edt,
jcr->jr.JobId,
jcr->jr.Job,
schedt,
sdt,
edt,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);

Dmsg0(debuglevel, "Leave ArchiveCleanup()\n");
Expand Down
7 changes: 5 additions & 2 deletions core/src/dird/authenticate_console.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2001-2008 Free Software Foundation Europe e.V.
Copyright (C) 2011-2012 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -203,7 +203,10 @@ bool ConsoleAuthenticatorFrom_18_2::SendResponseMessage(uint32_t response_id, bo

bool ConsoleAuthenticatorFrom_18_2::SendInfoMessage()
{
std::string message {"You are "};
std::string message;
message += BAREOS_VENDORSUPPORT_MESSAGE;
message += "\n";
message += "You are ";
if (ua_->cons) {
message += "logged in as: ";
message += ua_->cons->name();
Expand Down
4 changes: 3 additions & 1 deletion core/src/dird/backup.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2000-2012 Free Software Foundation Europe e.V.
Copyright (C) 2011-2016 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -1216,6 +1216,7 @@ void GenerateBackupSummary(JobControlRecord *jcr, ClientDbRecord *cr, int msg_ty
" Last Volume Bytes: %s (%sB)\n"
"%s" /* Daemon status info */
"%s" /* SecureErase status */
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand Down Expand Up @@ -1243,6 +1244,7 @@ void GenerateBackupSummary(JobControlRecord *jcr, ClientDbRecord *cr, int msg_ty
edit_uint64_with_suffix(mr.VolBytes, ec8),
daemon_status.c_str(),
secure_erase_status.c_str(),
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);
}
} /* namespace directordaemon */
4 changes: 3 additions & 1 deletion core/src/dird/consolidate.cc
@@ -1,7 +1,7 @@
/*
BAREOS® - Backup Archiving REcovery Open Sourced
Copyright (C) 2016-2016 Bareos GmbH & Co. KG
Copyright (C) 2016-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -350,13 +350,15 @@ void ConsolidateCleanup(JobControlRecord *jcr, int TermCode)
" Scheduled time: %s\n"
" Start time: %s\n"
" End time: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
edt,
jcr->jr.JobId,
jcr->jr.Job,
schedt,
sdt,
edt,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);

Dmsg0(debuglevel, "Leave ConsolidateCleanup()\n");
Expand Down
6 changes: 5 additions & 1 deletion core/src/dird/migrate.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2004-2012 Free Software Foundation Europe e.V.
Copyright (C) 2011-2016 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -1714,6 +1714,7 @@ static inline void GenerateMigrateSummary(JobControlRecord *jcr, MediaDbRecord *
" Last Volume Bytes: %s (%sB)\n"
" SD Errors: %d\n"
" SD termination status: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand Down Expand Up @@ -1749,6 +1750,7 @@ static inline void GenerateMigrateSummary(JobControlRecord *jcr, MediaDbRecord *
edit_uint64_with_suffix(mr->VolBytes, ec5),
jcr->SDErrors,
sd_term_msg,
BAREOS_VENDORSUPPORT_STATUS,
term_code);
} else {
/*
Expand All @@ -1763,6 +1765,7 @@ static inline void GenerateMigrateSummary(JobControlRecord *jcr, MediaDbRecord *
" End time: %s\n"
" Elapsed time: %s\n"
" Priority: %d\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand All @@ -1773,6 +1776,7 @@ static inline void GenerateMigrateSummary(JobControlRecord *jcr, MediaDbRecord *
edt,
edit_utime(RunTime, elapsed, sizeof(elapsed)),
jcr->JobPriority,
BAREOS_VENDORSUPPORT_STATUS,
term_code);
}
}
Expand Down
6 changes: 5 additions & 1 deletion core/src/dird/restore.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2000-2011 Free Software Foundation Europe e.V.
Copyright (C) 2011-2016 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -583,6 +583,7 @@ void GenerateRestoreSummary(JobControlRecord *jcr, int msg_type, const char *Ter
" Bytes Restored: %s\n"
" Rate: %.1f KB/s\n"
" SD termination status: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand All @@ -597,6 +598,7 @@ void GenerateRestoreSummary(JobControlRecord *jcr, int msg_type, const char *Ter
edit_uint64_with_commas(jcr->jr.JobBytes, ec3),
(float)kbps,
sd_term_msg,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);
break;
default:
Expand Down Expand Up @@ -629,6 +631,7 @@ void GenerateRestoreSummary(JobControlRecord *jcr, int msg_type, const char *Ter
" FD termination status: %s\n"
" SD termination status: %s\n"
"%s"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand All @@ -646,6 +649,7 @@ void GenerateRestoreSummary(JobControlRecord *jcr, int msg_type, const char *Ter
fd_term_msg,
sd_term_msg,
secure_erase_status.c_str(),
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);
break;
}
Expand Down
6 changes: 3 additions & 3 deletions core/src/dird/ua_status.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2001-2012 Free Software Foundation Europe e.V.
Copyright (C) 2011-2016 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -370,8 +370,8 @@ void ListDirStatusHeader(UaContext *ua)
ua->SendMsg(_("%s Version: %s (%s) %s %s %s\n"), my_name, VERSION, BDATE,
HOST_OS, DISTNAME, DISTVER);
bstrftime_nc(dt, sizeof(dt), daemon_start_time);
ua->SendMsg(_("Daemon started %s. Jobs: run=%d, running=%d mode=%d db=%s\n"),
dt, num_jobs_run, JobCount(), (int)DEVELOPER_MODE, dbdrivers.c_str() );
ua->SendMsg(_("Daemon started %s. Jobs: run=%d, running=%d mode=%d db:%s support:%s\n"),
dt, num_jobs_run, JobCount(), (int)DEVELOPER_MODE, dbdrivers.c_str(), BAREOS_VENDORSUPPORT_STATUS );
ua->SendMsg(_(" Heap: heap=%s smbytes=%s max_bytes=%s bufs=%s max_bufs=%s\n"),
edit_uint64_with_commas((char *)sbrk(0)-(char *)start_heap, b1),
edit_uint64_with_commas(sm_bytes, b2),
Expand Down
6 changes: 5 additions & 1 deletion core/src/dird/verify.cc
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2000-2011 Free Software Foundation Europe e.V.
Copyright (C) 2011-2016 Planets Communications B.V.
Copyright (C) 2013-2018 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -569,6 +569,7 @@ void VerifyCleanup(JobControlRecord *jcr, int TermCode)
" Non-fatal FD errors: %d\n"
" FD termination status: %s\n"
" SD termination status: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand All @@ -586,6 +587,7 @@ void VerifyCleanup(JobControlRecord *jcr, int TermCode)
jcr->JobErrors,
fd_term_msg,
sd_term_msg,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);
break;
default:
Expand All @@ -603,6 +605,7 @@ void VerifyCleanup(JobControlRecord *jcr, int TermCode)
" Files Examined: %s\n"
" Non-fatal FD errors: %d\n"
" FD termination status: %s\n"
" Bareos vendor support: %s\n"
" Termination: %s\n\n"),
BAREOS, my_name, VERSION, LSMDATE,
HOST_OS, DISTNAME, DISTVER,
Expand All @@ -618,6 +621,7 @@ void VerifyCleanup(JobControlRecord *jcr, int TermCode)
edit_uint64_with_commas(jcr->JobFiles, ec1),
jcr->JobErrors,
fd_term_msg,
BAREOS_VENDORSUPPORT_STATUS,
TermMsg);
break;
}
Expand Down
7 changes: 4 additions & 3 deletions core/src/filed/status.cc
Expand Up @@ -3,7 +3,8 @@
Copyright (C) 2001-2011 Free Software Foundation Europe e.V.
Copyright (C) 2011-2012 Planets Communications B.V.
Copyright (C) 2013-2016 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -89,8 +90,8 @@ static void ListStatusHeader(StatusPacket *sp)
my_name, VERSION, BDATE, VSS, HOST_OS, DISTNAME, DISTVER);
sendit(msg, len, sp);
bstrftime_nc(dt, sizeof(dt), daemon_start_time);
len = Mmsg(msg, _("Daemon started %s. Jobs: run=%d running=%d.\n"),
dt, num_jobs_run, JobCount());
len = Mmsg(msg, _("Daemon started %s. Jobs: run=%d running=%d support:%s\n"),
dt, num_jobs_run, JobCount(), BAREOS_VENDORSUPPORT_STATUS);
sendit(msg, len, sp);

#if defined(HAVE_WIN32)
Expand Down
4 changes: 3 additions & 1 deletion core/src/include/baconfig.h
Expand Up @@ -3,7 +3,7 @@
Copyright (C) 2000-2010 Free Software Foundation Europe e.V.
Copyright (C) 2011-2012 Planets Communications B.V.
Copyright (C) 2013-2016 Bareos GmbH & Co. KG
Copyright (C) 2013-2019 Bareos GmbH & Co. KG
This program is Free Software; you can redistribute it and/or
modify it under the terms of version three of the GNU Affero General Public
Expand Down Expand Up @@ -445,6 +445,8 @@ p_msg(__FILE__, __LINE__, lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11
p_msg(__FILE__, __LINE__, lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13)
#define Pmsg14(lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14) \
p_msg(__FILE__, __LINE__, lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14)
#define Pmsg15(lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15) \
p_msg(__FILE__, __LINE__, lvl, msg, a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11, a12, a13, a14, a15)

/** Messages that are printed using fixed size buffers (uses p_msg_fb) */
#define FPmsg0(lvl, msg) \
Expand Down
25 changes: 19 additions & 6 deletions core/src/include/version.h
@@ -1,14 +1,27 @@
#ifndef VERSION
#define VERSION "18.2.4rc2"
#ifndef VERSION
#define VERSION "18.2.4"
#endif

#define BDATE "18 Dec 2018"
#define LSMDATE "18Dec18"
#define BDATE "10 January 2019"
#define LSMDATE "10Jan19"

#define PROG_COPYRIGHT "Copyright (C) 2013-2019 Bareos GmbH & Co. KG\n" \
#ifndef BAREOS_VENDORSUPPORT_STATUS
#define BAREOS_VENDORSUPPORT_STATUS "UNSUPPORTED by vendor."
#endif

#ifndef BAREOS_VENDORSUPPORT_MESSAGE
#define BAREOS_VENDORSUPPORT_MESSAGE "Status: " BAREOS_VENDORSUPPORT_STATUS " Visit www.bareos.com for support offerings."
#endif


#define PROG_COPYRIGHT "\n" \
BAREOS_VENDORSUPPORT_MESSAGE \
"\n" \
"Copyright (C) 2013-2019 Bareos GmbH & Co. KG\n" \
"Copyright (C) %d-2012 Free Software Foundation Europe e.V.\n" \
"Copyright (C) 2010-2017 Planets Communications B.V.\n"
#define BYEAR "2018" /* year for copyright messages in programs */
#define BYEAR "2019" /* year for copyright messages in programs */


/*
BAREOS® - Backup Archiving REcovery Open Sourced
Expand Down

0 comments on commit 3e0dcb9

Please sign in to comment.