@@ -771,6 +771,7 @@ void Reboot_cluster_from_complete_outage::reboot_seed() {
771
771
// - The recovery credentials have the required Grants
772
772
//
773
773
// For those reasons, we must simply re-create the recovery account
774
+ bool requires_certificates{false };
774
775
if (m_options.gr_options .communication_stack .value_or (" " ) ==
775
776
kCommunicationStackMySQL ) {
776
777
// If it's a Replica cluster, we must disable the binary logging and
@@ -849,6 +850,35 @@ void Reboot_cluster_from_complete_outage::reboot_seed() {
849
850
options.auto_failover = false ;
850
851
options.mysql_comm_stack_supported = true ;
851
852
853
+ auto auth_type = m_cluster->impl ()->query_cluster_auth_type ();
854
+ switch (auth_type) {
855
+ case Replication_auth_type::PASSWORD:
856
+ case Replication_auth_type::CERT_ISSUER_PASSWORD:
857
+ case Replication_auth_type::CERT_SUBJECT_PASSWORD:
858
+ options.requires_password = true ;
859
+ break ;
860
+ default :
861
+ options.requires_password = false ;
862
+ break ;
863
+ }
864
+
865
+ switch (auth_type) {
866
+ case Replication_auth_type::CERT_SUBJECT:
867
+ case Replication_auth_type::CERT_SUBJECT_PASSWORD:
868
+ options.cert_subject =
869
+ m_cluster->impl ()->query_cluster_instance_auth_cert_subject (
870
+ *m_target_instance);
871
+ [[fallthrough]];
872
+ case Replication_auth_type::CERT_ISSUER:
873
+ case Replication_auth_type::CERT_ISSUER_PASSWORD:
874
+ options.cert_issuer =
875
+ m_cluster->impl ()->query_cluster_auth_cert_issuer ();
876
+ requires_certificates = true ;
877
+ break ;
878
+ default :
879
+ break ;
880
+ }
881
+
852
882
repl_account = mysqlshdk::gr::create_recovery_user (
853
883
repl_account.user , *m_target_instance, hosts, options);
854
884
}
@@ -934,25 +964,18 @@ void Reboot_cluster_from_complete_outage::reboot_seed() {
934
964
}
935
965
}
936
966
937
- log_info (" Starting cluster with '%s' using account %s" ,
967
+ resolve_ssl_mode_option (" memberSslMode" , " Cluster" , *m_target_instance,
968
+ &m_options.gr_options .ssl_mode );
969
+
970
+ log_info (" Starting cluster with '%s' (%s) using account %s" ,
938
971
m_target_instance->descr ().c_str (),
972
+ to_string (m_options.gr_options .ssl_mode ).c_str (),
939
973
m_target_instance->get_connection_options ().get_user ().c_str ());
940
974
941
975
// Determine the topology mode to use.
942
976
auto multi_primary = m_cluster->impl ()->get_cluster_topology_type () ==
943
977
mysqlshdk::gr::Topology_mode::MULTI_PRIMARY;
944
978
945
- bool requires_certificates{false };
946
- switch (m_cluster->impl ()->query_cluster_auth_type ()) {
947
- case mysqlsh::dba::Replication_auth_type::CERT_ISSUER:
948
- case mysqlsh::dba::Replication_auth_type::CERT_SUBJECT:
949
- case mysqlsh::dba::Replication_auth_type::CERT_ISSUER_PASSWORD:
950
- case mysqlsh::dba::Replication_auth_type::CERT_SUBJECT_PASSWORD:
951
- requires_certificates = true ;
952
- default :
953
- break ;
954
- }
955
-
956
979
// Start the cluster to bootstrap Group Replication.
957
980
mysqlsh::dba::start_cluster (*m_target_instance, m_options.gr_options ,
958
981
requires_certificates, multi_primary,
0 commit comments