Skip to content

SeaweedFS is a distributed storage system for object storage (S3), file systems, Iceberg table buckets, and Lance vector buckets, designed to handle billions of files with O(1) disk access and effortless horizontal scaling.

adjust log level

Chris Lue83bfd0a35a0
diff --git a/weed/security/tls.go b/weed/security/tls.go
index f4f525ede3..1832e6e073 100644
--- a/weed/security/tls.go
+++ b/weed/security/tls.go
@@ -3,12 +3,14 @@ package security
import (
"crypto/tls"
"crypto/x509"
- "github.com/spf13/viper"
"io/ioutil"
- "github.com/chrislusf/seaweedfs/weed/glog"
+ "github.com/spf13/viper"
+
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
+
+ "github.com/chrislusf/seaweedfs/weed/glog"
)
func LoadServerTLS(config *viper.Viper, component string) grpc.ServerOption {
@@ -19,12 +21,12 @@ func LoadServerTLS(config *viper.Viper, component string) grpc.ServerOption {
// load cert/key, ca cert
cert, err := tls.LoadX509KeyPair(config.GetString(component+".cert"), config.GetString(component+".key"))
if err != nil {
- glog.Errorf("load cert/key error: %v", err)
+ glog.V(1).Infof("load cert/key error: %v", err)
return nil
}
caCert, err := ioutil.ReadFile(config.GetString(component + ".ca"))
if err != nil {
- glog.Errorf("read ca cert file error: %v", err)
+ glog.V(1).Infof("read ca cert file error: %v", err)
return nil
}
caCertPool := x509.NewCertPool()
@@ -46,12 +48,12 @@ func LoadClientTLS(config *viper.Viper, component string) grpc.DialOption {
// load cert/key, cacert
cert, err := tls.LoadX509KeyPair(config.GetString(component+".cert"), config.GetString(component+".key"))
if err != nil {
- glog.Errorf("load cert/key error: %v", err)
+ glog.V(1).Infof("load cert/key error: %v", err)
return grpc.WithInsecure()
}
caCert, err := ioutil.ReadFile(config.GetString(component + ".ca"))
if err != nil {
- glog.Errorf("read ca cert file error: %v", err)
+ glog.V(1).Infof("read ca cert file error: %v", err)
return grpc.WithInsecure()
}
caCertPool := x509.NewCertPool()