Repository: kmesh-net/kmesh
Pull request #1114 (2024-12-12 06:23:39)

Add kmesh-daemon version subcommand and fix `kmeshctl version`
**What type of PR is this?**

<!--
Add one of the following kinds:

/kind bug
/kind cleanup
/kind enhancement
/kind security
/kind documentation
/kind feature

-->

**What this PR does / why we need it**:

**Which issue(s) this PR fixes**:
Fixes https://github.com/kmesh-net/kmesh/issues/1112
Fix https://github.com/kmesh-net/kmesh/issues/1110

**Special notes for your reviewer**:

The output now 

```
$ kmeshctl version
client version: 1.0-dev-ce162fb7634b6122966da01fd45147e319b7625e
kmesh-daemon version: 1.0-dev-ab83d8ccffaca860a5a657d7873afddd5327a122 (2 daemons)
```

**Does this PR introduce a user-facing change?**:
<!--
If no, just write "NONE" in the release-note block below.
If yes, a release note is required.
-->
```release-note

```



Patch:
diff --git a/.github/ISSUE_TEMPLATE/bug-report.md b/.github/ISSUE_TEMPLATE/bug-report.md
index 12387130..cb2df1d3 100644
--- a/.github/ISSUE_TEMPLATE/bug-report.md
+++ b/.github/ISSUE_TEMPLATE/bug-report.md
@@ -17,9 +17,5 @@ labels: kind/bug
 **Anything else we need to know?**:
 
 **Environment**:
-
 - Kmesh version:
-- Kmesh mode(kmesh has `Kernel-Native Mode` and `Duel-Engine Mode`):
-- Istio version:
-- Kernel version:
 - Others:
diff --git a/.github/ISSUE_TEMPLATE/question.md b/.github/ISSUE_TEMPLATE/question.md
index 0e66cdcb..24cb850a 100644
--- a/.github/ISSUE_TEMPLATE/question.md
+++ b/.github/ISSUE_TEMPLATE/question.md
@@ -15,9 +15,5 @@ Please make sure you have read the FAQ and searched the issue list.
 **What do you think about this question?**:
 
 **Environment**:
-
 - Kmesh version:
-- Kmesh mode(kmesh has `Kernel-Native Mode` and `Duel-Engine Mode`):
-- Istio version:
-- Kernel version:
 - Others:
diff --git a/Makefile b/Makefile
index b09437b1..e968e0fb 100644
--- a/Makefile
+++ b/Makefile
@@ -34,7 +34,6 @@ CC=clang
 CXX=clang++
 GOFLAGS := $(EXTRA_GOFLAGS)
 GOGCFLAGS := ""
-GOLDFLAGS := ""
 EXTLDFLAGS := '-fPIE -pie -Wl,-z,relro -Wl,-z,now -Wl,-z,noexecstack'
 LDFLAGS := "-X google.golang.org/protobuf/reflect/protoregistry.conflictPolicy=warn \
 			-X kmesh.net/kmesh/pkg/version.gitVersion=$(VERSION) \
@@ -43,20 +42,19 @@ LDFLAGS := "-X google.golang.org/protobuf/reflect/protoregistry.conflictPolicy=w
 			-X kmesh.net/kmesh/pkg/version.buildDate=$(BUILD_DATE) \
 			-linkmode=external -extldflags $(EXTLDFLAGS)"
 
-GOLDFLAGS := "-X google.golang.org/protobuf/reflect/protoregistry.conflictPolicy=warn \
+GOLDFLAGS := "-extldflags -static -s -w \
+			-X google.golang.org/protobuf/reflect/protoregistry.conflictPolicy=warn \
 			-X kmesh.net/kmesh/pkg/version.gitVersion=$(VERSION) \
 			-X kmesh.net/kmesh/pkg/version.gitCommit=$(GIT_COMMIT_HASH) \
 			-X kmesh.net/kmesh/pkg/version.gitTreeState=$(GIT_TREESTATE) \
-			-X kmesh.net/kmesh/pkg/version.buildDate=$(BUILD_DATE) \
-			-extldflags '-static'"
+			-X kmesh.net/kmesh/pkg/version.buildDate=$(BUILD_DATE)"
 
 # Debug flags
 ifeq ($(DEBUG),1)
 	# Debugging - disable optimizations and inlining
 	GOGCFLAGS := "all=-N -l"
 else
-	# Release build - disable symbols and DWARF, trim embedded paths
-	GOLDFLAGS := '-s -w'
+	# Release build - trim embedded paths
 	GOFLAGS += -trimpath
 endif
 
@@ -122,12 +120,11 @@ all-binary:
 	$(QUIET) (export PKG_CONFIG_PATH=$(PKG_CONFIG_PATH):$(ROOT_DIR)mk; \
 		CGO_ENABLED=0 $(GO) build -ldflags $(GOLDFLAGS) -o $(APPS4) $(GOFLAGS) ./ctl/main.go)
 
-OUT ?= kmeshctl
 .PHONY: kmeshctl
 kmeshctl:
 	$(call printlog, BUILD, $(APPS4))
 	$(QUIET) (export PKG_CONFIG_PATH=$(PKG_CONFIG_PATH):$(ROOT_DIR)mk; \
-		CGO_ENABLED=0 $(GO) build -gcflags $(GOGCFLAGS) -ldflags $(GOLDFLAGS) -o $(OUT) $(GOFLAGS) ./ctl/main.go)
+		CGO_ENABLED=0 $(GO) build -gcflags $(GOGCFLAGS) -ldflags $(GOLDFLAGS) -o kmeshctl $(GOFLAGS) ./ctl/main.go)
 
 .PHONY: gen-proto
 gen-proto:
diff --git a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfeb.go b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfeb.go
index d71bd4b1..707e6b81 100644
--- a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfeb.go
+++ b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfeb.go
@@ -16,12 +16,10 @@ type KmeshSockopsBuf struct{ Data [40]int8 }
 
 type KmeshSockopsClusterSockData struct{ ClusterId uint32 }
 
-type KmeshSockopsKmeshConfig struct {
-	BpfLogLevel      uint32
-	NodeIp           [4]uint32
-	PodGateway       [4]uint32
-	AuthzOffload     uint32
-	EnableMonitoring uint32
+type KmeshSockopsLogEvent struct {
+	Ret uint32
+	Msg [255]int8
+	_   [1]byte
 }
 
 type KmeshSockopsManagerKey struct {
@@ -29,6 +27,23 @@ type KmeshSockopsManagerKey struct {
 	_           [8]byte
 }
 
+type KmeshSockopsRatelimitKey struct {
+	Key struct {
+		SkSkb struct {
+			Netns  uint64
+			Ipv4   uint32
+			Port   uint32
+			Family uint32
+			_      [4]byte
+		}
+	}
+}
+
+type KmeshSockopsRatelimitValue struct {
+	LastTopup uint64
+	Tokens    uint64
+}
+
 type KmeshSockopsSockStorageData struct {
 	ConnectNs      uint64
 	Direction      uint8
@@ -88,25 +103,25 @@ type KmeshSockopsProgramSpecs struct {
 //
 // It can be passed ebpf.CollectionSpec.Assign.
 type KmeshSockopsMapSpecs struct {
-	KmCluster      *ebpf.MapSpec `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.MapSpec `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.MapSpec `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.MapSpec `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.MapSpec `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.MapSpec `ebpf:"km_eps_data"`
-	KmListener     *ebpf.MapSpec `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.MapSpec `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.MapSpec `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.MapSpec `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.MapSpec `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.MapSpec `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.MapSpec `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.MapSpec `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.MapSpec `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.MapSpec `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.MapSpec `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.MapSpec `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.MapSpec `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.MapSpec `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.MapSpec `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.MapSpec `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.MapSpec `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.MapSpec `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.MapSpec `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.MapSpec `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.MapSpec `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.MapSpec `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.MapSpec `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.MapSpec `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.MapSpec `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.MapSpec `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.MapSpec `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.MapSpec `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.MapSpec `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.MapSpec `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.MapSpec `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.MapSpec `ebpf:"tmp_log_buf"`
 }
 
 // KmeshSockopsObjects contains all objects after they have been loaded into the kernel.
@@ -128,48 +143,48 @@ func (o *KmeshSockopsObjects) Close() error {
 //
 // It can be passed to LoadKmeshSockopsObjects or ebpf.CollectionSpec.LoadAndAssign.
 type KmeshSockopsMaps struct {
-	KmCluster      *ebpf.Map `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.Map `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.Map `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.Map `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.Map `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.Map `ebpf:"km_eps_data"`
-	KmListener     *ebpf.Map `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.Map `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.Map `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.Map `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.Map `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.Map `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.Map `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.Map `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.Map `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.Map `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.Map `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.Map `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.Map `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.Map `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.Map `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.Map `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.Map `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.Map `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.Map `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.Map `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.Map `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.Map `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.Map `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.Map `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.Map `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.Map `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.Map `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.Map `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.Map `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.Map `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.Map `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.Map `ebpf:"tmp_log_buf"`
 }
 
 func (m *KmeshSockopsMaps) Close() error {
 	return _KmeshSockopsClose(
-		m.KmCluster,
-		m.KmClusterEps,
-		m.KmClusterSock,
-		m.KmClusterstats,
-		m.KmConfigmap,
-		m.KmEpsData,
-		m.KmListener,
-		m.KmLogEvent,
-		m.KmMaglevOuter,
-		m.KmManage,
-		m.KmRouterconfig,
-		m.KmSockstorage,
-		m.KmTailcallCtx,
-		m.KmTailcallprog,
-		m.KmTmpbuf,
-		m.KmeshMap1600,
-		m.KmeshMap192,
-		m.KmeshMap296,
-		m.KmeshMap64,
+		m.InnerMap,
+		m.KmeshCluster,
+		m.KmeshClusterStats,
+		m.KmeshConfigMap,
+		m.KmeshEvents,
+		m.KmeshListener,
+		m.KmeshManage,
+		m.KmeshRatelimit,
+		m.KmeshTailCallCtx,
+		m.KmeshTailCallProg,
+		m.MapOfClusterEps,
+		m.MapOfClusterEpsData,
+		m.MapOfClusterSock,
+		m.MapOfRouterConfig,
+		m.MapOfSockStorage,
+		m.OuterMap,
+		m.OuterOfMaglev,
+		m.TmpBuf,
+		m.TmpLogBuf,
 	)
 }
 
diff --git a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfel.go b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfel.go
index be1b1684..17ae9717 100644
--- a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfel.go
+++ b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockops_bpfel.go
@@ -16,12 +16,10 @@ type KmeshSockopsBuf struct{ Data [40]int8 }
 
 type KmeshSockopsClusterSockData struct{ ClusterId uint32 }
 
-type KmeshSockopsKmeshConfig struct {
-	BpfLogLevel      uint32
-	NodeIp           [4]uint32
-	PodGateway       [4]uint32
-	AuthzOffload     uint32
-	EnableMonitoring uint32
+type KmeshSockopsLogEvent struct {
+	Ret uint32
+	Msg [255]int8
+	_   [1]byte
 }
 
 type KmeshSockopsManagerKey struct {
@@ -29,6 +27,23 @@ type KmeshSockopsManagerKey struct {
 	_           [8]byte
 }
 
+type KmeshSockopsRatelimitKey struct {
+	Key struct {
+		SkSkb struct {
+			Netns  uint64
+			Ipv4   uint32
+			Port   uint32
+			Family uint32
+			_      [4]byte
+		}
+	}
+}
+
+type KmeshSockopsRatelimitValue struct {
+	LastTopup uint64
+	Tokens    uint64
+}
+
 type KmeshSockopsSockStorageData struct {
 	ConnectNs      uint64
 	Direction      uint8
@@ -88,25 +103,25 @@ type KmeshSockopsProgramSpecs struct {
 //
 // It can be passed ebpf.CollectionSpec.Assign.
 type KmeshSockopsMapSpecs struct {
-	KmCluster      *ebpf.MapSpec `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.MapSpec `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.MapSpec `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.MapSpec `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.MapSpec `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.MapSpec `ebpf:"km_eps_data"`
-	KmListener     *ebpf.MapSpec `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.MapSpec `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.MapSpec `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.MapSpec `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.MapSpec `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.MapSpec `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.MapSpec `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.MapSpec `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.MapSpec `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.MapSpec `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.MapSpec `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.MapSpec `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.MapSpec `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.MapSpec `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.MapSpec `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.MapSpec `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.MapSpec `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.MapSpec `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.MapSpec `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.MapSpec `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.MapSpec `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.MapSpec `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.MapSpec `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.MapSpec `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.MapSpec `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.MapSpec `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.MapSpec `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.MapSpec `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.MapSpec `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.MapSpec `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.MapSpec `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.MapSpec `ebpf:"tmp_log_buf"`
 }
 
 // KmeshSockopsObjects contains all objects after they have been loaded into the kernel.
@@ -128,48 +143,48 @@ func (o *KmeshSockopsObjects) Close() error {
 //
 // It can be passed to LoadKmeshSockopsObjects or ebpf.CollectionSpec.LoadAndAssign.
 type KmeshSockopsMaps struct {
-	KmCluster      *ebpf.Map `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.Map `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.Map `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.Map `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.Map `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.Map `ebpf:"km_eps_data"`
-	KmListener     *ebpf.Map `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.Map `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.Map `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.Map `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.Map `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.Map `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.Map `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.Map `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.Map `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.Map `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.Map `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.Map `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.Map `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.Map `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.Map `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.Map `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.Map `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.Map `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.Map `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.Map `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.Map `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.Map `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.Map `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.Map `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.Map `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.Map `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.Map `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.Map `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.Map `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.Map `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.Map `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.Map `ebpf:"tmp_log_buf"`
 }
 
 func (m *KmeshSockopsMaps) Close() error {
 	return _KmeshSockopsClose(
-		m.KmCluster,
-		m.KmClusterEps,
-		m.KmClusterSock,
-		m.KmClusterstats,
-		m.KmConfigmap,
-		m.KmEpsData,
-		m.KmListener,
-		m.KmLogEvent,
-		m.KmMaglevOuter,
-		m.KmManage,
-		m.KmRouterconfig,
-		m.KmSockstorage,
-		m.KmTailcallCtx,
-		m.KmTailcallprog,
-		m.KmTmpbuf,
-		m.KmeshMap1600,
-		m.KmeshMap192,
-		m.KmeshMap296,
-		m.KmeshMap64,
+		m.InnerMap,
+		m.KmeshCluster,
+		m.KmeshClusterStats,
+		m.KmeshConfigMap,
+		m.KmeshEvents,
+		m.KmeshListener,
+		m.KmeshManage,
+		m.KmeshRatelimit,
+		m.KmeshTailCallCtx,
+		m.KmeshTailCallProg,
+		m.MapOfClusterEps,
+		m.MapOfClusterEpsData,
+		m.MapOfClusterSock,
+		m.MapOfRouterConfig,
+		m.MapOfSockStorage,
+		m.OuterMap,
+		m.OuterOfMaglev,
+		m.TmpBuf,
+		m.TmpLogBuf,
 	)
 }
 
diff --git a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfeb.go b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfeb.go
index 2ac2afe3..aae8eb08 100644
--- a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfeb.go
+++ b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfeb.go
@@ -16,12 +16,10 @@ type KmeshSockopsCompatBuf struct{ Data [40]int8 }
 
 type KmeshSockopsCompatClusterSockData struct{ ClusterId uint32 }
 
-type KmeshSockopsCompatKmeshConfig struct {
-	BpfLogLevel      uint32
-	NodeIp           [4]uint32
-	PodGateway       [4]uint32
-	AuthzOffload     uint32
-	EnableMonitoring uint32
+type KmeshSockopsCompatLogEvent struct {
+	Ret uint32
+	Msg [255]int8
+	_   [1]byte
 }
 
 type KmeshSockopsCompatManagerKey struct {
@@ -29,6 +27,23 @@ type KmeshSockopsCompatManagerKey struct {
 	_           [8]byte
 }
 
+type KmeshSockopsCompatRatelimitKey struct {
+	Key struct {
+		SkSkb struct {
+			Netns  uint64
+			Ipv4   uint32
+			Port   uint32
+			Family uint32
+			_      [4]byte
+		}
+	}
+}
+
+type KmeshSockopsCompatRatelimitValue struct {
+	LastTopup uint64
+	Tokens    uint64
+}
+
 type KmeshSockopsCompatSockStorageData struct {
 	ConnectNs      uint64
 	Direction      uint8
@@ -88,25 +103,25 @@ type KmeshSockopsCompatProgramSpecs struct {
 //
 // It can be passed ebpf.CollectionSpec.Assign.
 type KmeshSockopsCompatMapSpecs struct {
-	KmCluster      *ebpf.MapSpec `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.MapSpec `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.MapSpec `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.MapSpec `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.MapSpec `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.MapSpec `ebpf:"km_eps_data"`
-	KmListener     *ebpf.MapSpec `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.MapSpec `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.MapSpec `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.MapSpec `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.MapSpec `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.MapSpec `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.MapSpec `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.MapSpec `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.MapSpec `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.MapSpec `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.MapSpec `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.MapSpec `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.MapSpec `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.MapSpec `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.MapSpec `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.MapSpec `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.MapSpec `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.MapSpec `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.MapSpec `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.MapSpec `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.MapSpec `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.MapSpec `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.MapSpec `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.MapSpec `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.MapSpec `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.MapSpec `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.MapSpec `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.MapSpec `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.MapSpec `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.MapSpec `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.MapSpec `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.MapSpec `ebpf:"tmp_log_buf"`
 }
 
 // KmeshSockopsCompatObjects contains all objects after they have been loaded into the kernel.
@@ -128,48 +143,48 @@ func (o *KmeshSockopsCompatObjects) Close() error {
 //
 // It can be passed to LoadKmeshSockopsCompatObjects or ebpf.CollectionSpec.LoadAndAssign.
 type KmeshSockopsCompatMaps struct {
-	KmCluster      *ebpf.Map `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.Map `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.Map `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.Map `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.Map `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.Map `ebpf:"km_eps_data"`
-	KmListener     *ebpf.Map `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.Map `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.Map `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.Map `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.Map `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.Map `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.Map `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.Map `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.Map `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.Map `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.Map `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.Map `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.Map `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.Map `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.Map `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.Map `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.Map `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.Map `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.Map `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.Map `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.Map `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.Map `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.Map `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.Map `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.Map `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.Map `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.Map `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.Map `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.Map `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.Map `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.Map `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.Map `ebpf:"tmp_log_buf"`
 }
 
 func (m *KmeshSockopsCompatMaps) Close() error {
 	return _KmeshSockopsCompatClose(
-		m.KmCluster,
-		m.KmClusterEps,
-		m.KmClusterSock,
-		m.KmClusterstats,
-		m.KmConfigmap,
-		m.KmEpsData,
-		m.KmListener,
-		m.KmLogEvent,
-		m.KmMaglevOuter,
-		m.KmManage,
-		m.KmRouterconfig,
-		m.KmSockstorage,
-		m.KmTailcallCtx,
-		m.KmTailcallprog,
-		m.KmTmpbuf,
-		m.KmeshMap1600,
-		m.KmeshMap192,
-		m.KmeshMap296,
-		m.KmeshMap64,
+		m.InnerMap,
+		m.KmeshCluster,
+		m.KmeshClusterStats,
+		m.KmeshConfigMap,
+		m.KmeshEvents,
+		m.KmeshListener,
+		m.KmeshManage,
+		m.KmeshRatelimit,
+		m.KmeshTailCallCtx,
+		m.KmeshTailCallProg,
+		m.MapOfClusterEps,
+		m.MapOfClusterEpsData,
+		m.MapOfClusterSock,
+		m.MapOfRouterConfig,
+		m.MapOfSockStorage,
+		m.OuterMap,
+		m.OuterOfMaglev,
+		m.TmpBuf,
+		m.TmpLogBuf,
 	)
 }
 
diff --git a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfel.go b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfel.go
index 0456eb9b..4be52038 100644
--- a/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfel.go
+++ b/bpf/kmesh/bpf2go/kernelnative/enhanced/kmeshsockopscompat_bpfel.go
@@ -16,12 +16,10 @@ type KmeshSockopsCompatBuf struct{ Data [40]int8 }
 
 type KmeshSockopsCompatClusterSockData struct{ ClusterId uint32 }
 
-type KmeshSockopsCompatKmeshConfig struct {
-	BpfLogLevel      uint32
-	NodeIp           [4]uint32
-	PodGateway       [4]uint32
-	AuthzOffload     uint32
-	EnableMonitoring uint32
+type KmeshSockopsCompatLogEvent struct {
+	Ret uint32
+	Msg [255]int8
+	_   [1]byte
 }
 
 type KmeshSockopsCompatManagerKey struct {
@@ -29,6 +27,23 @@ type KmeshSockopsCompatManagerKey struct {
 	_           [8]byte
 }
 
+type KmeshSockopsCompatRatelimitKey struct {
+	Key struct {
+		SkSkb struct {
+			Netns  uint64
+			Ipv4   uint32
+			Port   uint32
+			Family uint32
+			_      [4]byte
+		}
+	}
+}
+
+type KmeshSockopsCompatRatelimitValue struct {
+	LastTopup uint64
+	Tokens    uint64
+}
+
 type KmeshSockopsCompatSockStorageData struct {
 	ConnectNs      uint64
 	Direction      uint8
@@ -88,25 +103,25 @@ type KmeshSockopsCompatProgramSpecs struct {
 //
 // It can be passed ebpf.CollectionSpec.Assign.
 type KmeshSockopsCompatMapSpecs struct {
-	KmCluster      *ebpf.MapSpec `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.MapSpec `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.MapSpec `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.MapSpec `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.MapSpec `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.MapSpec `ebpf:"km_eps_data"`
-	KmListener     *ebpf.MapSpec `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.MapSpec `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.MapSpec `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.MapSpec `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.MapSpec `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.MapSpec `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.MapSpec `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.MapSpec `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.MapSpec `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.MapSpec `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.MapSpec `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.MapSpec `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.MapSpec `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.MapSpec `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.MapSpec `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.MapSpec `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.MapSpec `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.MapSpec `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.MapSpec `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.MapSpec `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.MapSpec `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.MapSpec `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.MapSpec `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.MapSpec `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.MapSpec `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.MapSpec `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.MapSpec `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.MapSpec `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.MapSpec `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.MapSpec `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.MapSpec `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.MapSpec `ebpf:"tmp_log_buf"`
 }
 
 // KmeshSockopsCompatObjects contains all objects after they have been loaded into the kernel.
@@ -128,48 +143,48 @@ func (o *KmeshSockopsCompatObjects) Close() error {
 //
 // It can be passed to LoadKmeshSockopsCompatObjects or ebpf.CollectionSpec.LoadAndAssign.
 type KmeshSockopsCompatMaps struct {
-	KmCluster      *ebpf.Map `ebpf:"km_cluster"`
-	KmClusterEps   *ebpf.Map `ebpf:"km_cluster_eps"`
-	KmClusterSock  *ebpf.Map `ebpf:"km_cluster_sock"`
-	KmClusterstats *ebpf.Map `ebpf:"km_clusterstats"`
-	KmConfigmap    *ebpf.Map `ebpf:"km_configmap"`
-	KmEpsData      *ebpf.Map `ebpf:"km_eps_data"`
-	KmListener     *ebpf.Map `ebpf:"km_listener"`
-	KmLogEvent     *ebpf.Map `ebpf:"km_log_event"`
-	KmMaglevOuter  *ebpf.Map `ebpf:"km_maglev_outer"`
-	KmManage       *ebpf.Map `ebpf:"km_manage"`
-	KmRouterconfig *ebpf.Map `ebpf:"km_routerconfig"`
-	KmSockstorage  *ebpf.Map `ebpf:"km_sockstorage"`
-	KmTailcallCtx  *ebpf.Map `ebpf:"km_tailcall_ctx"`
-	KmTailcallprog *ebpf.Map `ebpf:"km_tailcallprog"`
-	KmTmpbuf       *ebpf.Map `ebpf:"km_tmpbuf"`
-	KmeshMap1600   *ebpf.Map `ebpf:"kmesh_map1600"`
-	KmeshMap192    *ebpf.Map `ebpf:"kmesh_map192"`
-	KmeshMap296    *ebpf.Map `ebpf:"kmesh_map296"`
-	KmeshMap64     *ebpf.Map `ebpf:"kmesh_map64"`
+	InnerMap            *ebpf.Map `ebpf:"inner_map"`
+	KmeshCluster        *ebpf.Map `ebpf:"kmesh_cluster"`
+	KmeshClusterStats   *ebpf.Map `ebpf:"kmesh_cluster_stats"`
+	KmeshConfigMap      *ebpf.Map `ebpf:"kmesh_config_map"`
+	KmeshEvents         *ebpf.Map `ebpf:"kmesh_events"`
+	KmeshListener       *ebpf.Map `ebpf:"kmesh_listener"`
+	KmeshManage         *ebpf.Map `ebpf:"kmesh_manage"`
+	KmeshRatelimit      *ebpf.Map `ebpf:"kmesh_ratelimit"`
+	KmeshTailCallCtx    *ebpf.Map `ebpf:"kmesh_tail_call_ctx"`
+	KmeshTailCallProg   *ebpf.Map `ebpf:"kmesh_tail_call_prog"`
+	MapOfClusterEps     *ebpf.Map `ebpf:"map_of_cluster_eps"`
+	MapOfClusterEpsData *ebpf.Map `ebpf:"map_of_cluster_eps_data"`
+	MapOfClusterSock    *ebpf.Map `ebpf:"map_of_cluster_sock"`
+	MapOfRouterConfig   *ebpf.Map `ebpf:"map_of_router_config"`
+	MapOfSockStorage    *ebpf.Map `ebpf:"map_of_sock_storage"`
+	OuterMap            *ebpf.Map `ebpf:"outer_map"`
+	OuterOfMaglev       *ebpf.Map `ebpf:"outer_of_maglev"`
+	TmpBuf              *ebpf.Map `ebpf:"tmp_buf"`
+	TmpLogBuf           *ebpf.Map `ebpf:"tmp_log_buf"`
 }
 
 func (m *KmeshSockopsCompatMaps) Close() error {
 	return _KmeshSockopsCompatClose(
-		m.KmCluster,
-		m.KmClusterEps,
-		m.KmClusterSock,
-		m.KmClusterstats,
-		m.KmConfigmap,
-		m.KmEpsData,
-		m.KmListener,
-		m.KmLogEvent,
-		m.KmMaglevOuter,
-		m.KmManage,
-		m.KmRouterconfig,
-		m.KmSockstorage,
-		m.KmTailcallCtx,
-		m.KmTailcallprog,
-		m.KmTmpbuf,
-		m.KmeshMap1600,
-		m.KmeshMap192,
-		m.KmeshMap296,
-		m.KmeshMap64,
+		m.InnerMap,
+		m.KmeshCluster,
+		m.KmeshClusterStats,
+		m.KmeshConfigMap,
+		m.KmeshEvents,
+		m.KmeshListener,
+		m.KmeshManage,
+		m.KmeshRatelimit,
+		m.KmeshTailCallCtx,
+		m.KmeshTailCallProg,
+		m.MapOfClusterEps,
+		m.MapOfClusterEpsData,
+		m.MapOfClusterSock,
+		m.MapOfRouterConfig,
+		m.MapOfSockStorage,
+		m.OuterMap,
+		m.OuterOfMaglev,
+		m.TmpBuf,
+		m.TmpLogBuf,
 	)
 }
 
diff --git a/bpf/kmesh/workload/include/backend.h b/bpf/kmesh/workload/include/backend.h
index 1e0750fc..fa6834db 100644
--- a/bpf/kmesh/workload/include/backend.h
+++ b/bpf/kmesh/workload/include/backend.h
@@ -89,9 +89,20 @@ backend_manager(struct kmesh_context *kmesh_ctx, backend_value *backend_v, __u32
         return ret;
     }
 
-    ret = update_dst_addr_with_service_port(kmesh_ctx, backend_v, service_v);
-    if (ret != 0)
-        BPF_LOG(ERR, BACKEND, "cannot find matched service port [%d:%d]\n", service_id, kmesh_ctx->ctx->user_port);
+#pragma unroll
+    for (i = 0; i < MAX_SERVICE_COUNT; i++) {
+        if (i >= backend_v->service_count)
+            break;
+
+        if (service_id != backend_v->service[i])
+            continue;
+
+        ret = update_dst_addr_with_service_port(kmesh_ctx, backend_v, service_v);
+        if (ret == 0)
+            break;
+    }
+
+    BPF_LOG(WARN, BACKEND, "backend_manager svc_id:%u i:%u ret:%d.\n", service_id, i, ret);
     return ret;
 }
 
diff --git a/ctl/monitoring/monitoring.go b/ctl/monitoring/monitoring.go
index 2fbd12b1..0280ddf0 100644
--- a/ctl/monitoring/monitoring.go
+++ b/ctl/monitoring/monitoring.go
@@ -33,9 +33,8 @@ import (
 )
 
 const (
-	patternAccesslog       = "/accesslog"
-	patternMonitoring      = "/monitoring"
-	patternWorkloadMetrics = "/workload_metrics"
+	patternAccesslog  = "/accesslog"
+	patternMonitoring = "/monitoring"
 )
 
 var log = logger.NewLoggerScope("kmeshctl/monitoring")
@@ -47,20 +46,11 @@ func NewCmd() *cobra.Command {
 		Example: `# Enable/Disable Kmesh's accesslog:
 kmeshctl monitoring <kmesh-daemon-pod> --accesslog enable/disable
 
-# Enable/Disable services' metrics and accesslog generated from bpf:
+# Enable/Disable Kmesh's metrics and accesslog:
 kmeshctl monitoring <kmesh-daemon-pod> --all enable/disable
 
-# Enable/Disable workload granularity metrics:
-kmeshctl monitoring <kmesh-daemon-pod> --workloadMetrics enable/disable
-
 # If you want to change the monitoring functionality of all kmesh daemons in the cluster
-# Enable/Disable Kmesh's accesslog in each node:
 kmeshctl monitoring --accesslog enable/disable
-
-# Enable/Disable workload granularity metrics in each node:
-kmeshctl monitoring --workloadMetrics enable/disable
-
-#Enable/Disable services' and workloads' metrics and accesslog generated from bpf in each node:
 kmeshctl monitoring --all enable/disable`,
 		Args: cobra.MaximumNArgs(1),
 		Run: func(cmd *cobra.Command, args []string) {
@@ -68,8 +58,7 @@ kmeshctl monitoring --all enable/disable`,
 		},
 	}
 	cmd.Flags().String("accesslog", "", "Control accesslog enable or disable")
-	cmd.Flags().String("all", "", "Control accesslog and services' and workloads' metrics enable or disable together")
-	cmd.Flags().String("workloadMetrics", "", "Control granularity metrics enable or disable")
+	cmd.Flags().String("all", "", "Control accesslog and metrics enable or disable together")
 	return cmd
 }
 
@@ -81,9 +70,8 @@ func ControlMonitoring(cmd *cobra.Command, args []string) {
 	}
 	accesslogFlag, _ := cmd.Flags().GetString("accesslog")
 	allFlag, _ := cmd.Flags().GetString("all")
-	workloadMetricsFlag, _ := cmd.Flags().GetString("workloadMetrics")
-	if accesslogFlag == "" && allFlag == "" && workloadMetricsFlag == "" {
-		log.Print("no parameters. Need --accesslog, --workloadMetric or --all")
+	if accesslogFlag == "" && allFlag == "" {
+		log.Print("no parameters. Need --accesslog or --all")
 		return
 	}
 
@@ -96,9 +84,6 @@ func ControlMonitoring(cmd *cobra.Command, args []string) {
 		if accesslogFlag != "" {
 			SetAccesslogPerKmeshDaemon(client, podName, accesslogFlag)
 		}
-		if workloadMetricsFlag != "" {
-			SetWorkloadMetricsPerKmeshDaemon(client, podName, workloadMetricsFlag)
-		}
 	} else {
 		// Perform operations on all kmesh daemons.
 		podList, err := client.PodsForSelector(context.TODO(), utils.KmeshNamespace, utils.KmeshLabel)
@@ -113,9 +98,6 @@ func ControlMonitoring(cmd *cobra.Command, args []string) {
 			if accesslogFlag != "" {
 				SetAccesslogPerKmeshDaemon(client, pod.GetName(), accesslogFlag)
 			}
-			if workloadMetricsFlag != "" {
-				SetWorkloadMetricsPerKmeshDaemon(client, pod.GetName(), workloadMetricsFlag)
-			}
 		}
 	}
 }
@@ -229,58 +211,3 @@ func SetMonitoringPerKmeshDaemon(cli kube.CLIClient, podName, info string) {
 		return
 	}
 }
-
-func SetWorkloadMetricsPerKmeshDaemon(cli kube.CLIClient, podName, workloadMetricsInfo string) {
-	var info string
-	if workloadMetricsInfo == "enable" {
-		info = "true"
-	} else if workloadMetricsInfo == "disable" {
-		info = "false"
-	} else {
-		log.Errorf("Error: Argument must be 'enable' or 'disable'")
-		os.Exit(1)
-	}
-
-	fw, err := utils.CreateKmeshPortForwarder(cli, podName)
-	if err != nil {
-		log.Errorf("failed to create port forwarder for Kmesh daemon pod %s: %v", podName, err)
-		os.Exit(1)
-	}
-	if err := fw.Start(); err != nil {
-		log.Errorf("failed to start port forwarder for Kmesh daemon pod %s: %v", podName, err)
-		os.Exit(1)
-	}
-	defer fw.Close()
-
-	url := fmt.Sprintf("http://%s%s?enable=%s", fw.Address(), patternWorkloadMetrics, info)
-
-	req, err := http.NewRequest(http.MethodPost, url, nil)
-	if err != nil {
-		log.Errorf("Error creating request: %v", err)
-		return
-	}
-
-	req.Header.Set("Content-Type", "application/json")
-	client := &http.Client{}
-	resp, err := client.Do(req)
-	if err != nil {
-		log.Errorf("failed to make HTTP request: %v", err)
-		return
-	}
-	defer resp.Body.Close()
-
-	if resp.StatusCode != http.StatusOK {
-		bodyBytes, readErr := io.ReadAll(resp.Body)
-		if readErr != nil {
-			log.Errorf("Error reading response body: %v", readErr)
-			return
-		}
-		bodyString := string(bodyBytes)
-		if resp.StatusCode == http.StatusBadRequest && bytes.Contains(bodyBytes, []byte("Kmesh monitoring is disable, cannot enable accesslog")) {
-			log.Errorf("failed to enable workload metrics: %v. Need to start Kmesh's Monitoring. Please run `kmeshctl monitoring -h` for more help.", bodyString)
-			return
-		}
-		log.Errorf("Error: received status code %d", resp.StatusCode)
-		return
-	}
-}
diff --git a/ctl/version/version.go b/ctl/version/version.go
index ee00549b..7ae1d981 100644
--- a/ctl/version/version.go
+++ b/ctl/version/version.go
@@ -17,14 +17,18 @@
 package version
 
 import (
+	"context"
+	"encoding/json"
 	"fmt"
 	"io"
 	"net/http"
 	"os"
+	"strings"
 
 	"github.com/spf13/cobra"
 
 	"kmesh.net/kmesh/ctl/utils"
+	"kmesh.net/kmesh/pkg/kube"
 	"kmesh.net/kmesh/pkg/logger"
 	"kmesh.net/kmesh/pkg/version"
 )
@@ -35,43 +39,72 @@ func NewCmd() *cobra.Command {
 	cmd := &cobra.Command{
 		Use:   "version",
 		Short: "Prints out build version info",
-		Example: `# Show version of kmeshctl
+		Example: `# Show version of all kmesh components
 kmeshctl version
 
-# Show version info of a specific Kmesh daemon
+# Show version info of a specific kmesh daemon
 kmeshctl version <kmesh-daemon-pod>`,
 		Run: func(cmd *cobra.Command, args []string) {
-			_ = RunVersion(cmd, args)
+			runVersion(cmd, args)
 		},
 	}
 	return cmd
 }
 
-// RunVersion provides the version info of kmeshctl or specific Kmesh daemon.
-func RunVersion(cmd *cobra.Command, args []string) error {
-	if len(args) == 0 {
-		v := version.Get()
-		cmd.Printf("%s\n", v.GitVersion)
-
-		return nil
-	}
-
+// runVersion output the version info of kmeshctl or kmesh-daemon.
+func runVersion(cmd *cobra.Command, args []string) {
 	cli, err := utils.CreateKubeClient()
 	if err != nil {
-		log.Errorf("failed to create cli client: %v", err)
+		log.Errorf("failed to create kube client: %v", err)
 		os.Exit(1)
 	}
 
+	if len(args) == 0 {
+		v := version.Get()
+		cmd.Printf("client version: %s-%s\n", v.GitVersion, v.GitCommit)
+		podList, err := cli.PodsForSelector(context.TODO(), utils.KmeshNamespace, utils.KmeshLabel)
+		if err != nil {
+			log.Errorf("failed to get kmesh daemon pods: %v", err)
+			os.Exit(1)
+		}
+
+		daemonVersions := map[string]int{}
+		for _, pod := range podList.Items {
+			v := getVersion(cli, pod.Name)
+			if v.GitVersion != "" {
+				daemonVersions[v.GitVersion+"-"+v.GitCommit] = daemonVersions[v.GitVersion+"-"+v.GitCommit] + 1
+			}
+		}
+		counts := []string{}
+		cmd.Printf("kmesh-daemon version: ")
+		for k, v := range daemonVersions {
+			counts = append(counts, fmt.Sprintf("%s (%d daemons)", k, v))
+		}
+		cmd.Printf("%s\n", strings.Join(counts, ", "))
+		return
+	}
+
 	podName := args[0]
+	v := getVersion(cli, podName)
+	if v.GitVersion != "" {
+		data, err := json.MarshalIndent(&v, "", "  ")
+		if err != nil {
+			log.Errorf("Failed to marshal version info: %v", err)
+			os.Exit(1)
+		}
+		cmd.Printf("%s\n", string(data))
+	}
+}
 
-	fw, err := utils.CreateKmeshPortForwarder(cli, podName)
+func getVersion(client kube.CLIClient, podName string) (version version.Info) {
+	fw, err := utils.CreateKmeshPortForwarder(client, podName)
 	if err != nil {
 		log.Errorf("failed to create port forwarder for Kmesh daemon pod %s: %v", podName, err)
-		os.Exit(1)
+		return
 	}
 	if err := fw.Start(); err != nil {
 		log.Errorf("failed to start port forwarder for Kmesh daemon pod %s: %v", podName, err)
-		os.Exit(1)
+		return
 	}
 	defer fw.Close()
 
@@ -79,17 +112,20 @@ func RunVersion(cmd *cobra.Command, args []string) error {
 	resp, err := http.Get(url)
 	if err != nil {
 		log.Errorf("failed to make HTTP request: %v", err)
-		os.Exit(1)
+		return
 	}
 	defer resp.Body.Close()
 
 	body, err := io.ReadAll(resp.Body)
 	if err != nil {
 		log.Errorf("failed to read HTTP response body: %v", err)
-		os.Exit(1)
+		return
 	}
 
-	cmd.Println(string(body))
+	if err := json.Unmarshal(body, &version); err != nil {
+		log.Errorf("failed to unmarshal version info: %v", err)
+		return
+	}
 
-	return nil
+	return
 }
diff --git a/daemon/manager/manager.go b/daemon/manager/manager.go
index f6deb4dd..59046c4f 100644
--- a/daemon/manager/manager.go
+++ b/daemon/manager/manager.go
@@ -28,6 +28,7 @@ import (
 	"github.com/spf13/pflag"
 
 	"kmesh.net/kmesh/daemon/manager/uninstall"
+	"kmesh.net/kmesh/daemon/manager/version"
 	"kmesh.net/kmesh/daemon/options"
 	"kmesh.net/kmesh/pkg/bpf"
 	"kmesh.net/kmesh/pkg/bpf/restart"
@@ -68,6 +69,7 @@ func NewCommand() *cobra.Command {
 
 	// add sub commands
 	cmd.AddCommand(uninstall.NewCmd())
+	cmd.AddCommand(version.NewCmd())
 
 	return cmd
 }
diff --git a/daemon/manager/version/version.go b/daemon/manager/version/version.go
new file mode 100644
index 00000000..26538f14
--- /dev/null
+++ b/daemon/manager/version/version.go
@@ -0,0 +1,42 @@
+/*
+ * Copyright The Kmesh Authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at:
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package version
+
+import (
+	"github.com/spf13/cobra"
+
+	"kmesh.net/kmesh/pkg/version"
+)
+
+func NewCmd() *cobra.Command {
+	cmd := &cobra.Command{
+		Use:   "version",
+		Short: "Prints out build version info",
+		Example: `# Show version of kmesh-daemon
+kmesh-daemon version`,
+		Run: func(cmd *cobra.Command, args []string) {
+			printVersion(cmd)
+		},
+	}
+	return cmd
+}
+
+// printVersion pritn out the version info of the kmesh daemon.
+func printVersion(cmd *cobra.Command) {
+	v := version.Get()
+	cmd.Printf("%s\n", v)
+}
diff --git a/docs/ctl/kmeshctl_monitoring.md b/docs/ctl/kmeshctl_monitoring.md
index 6a912376..b42ba32d 100644
--- a/docs/ctl/kmeshctl_monitoring.md
+++ b/docs/ctl/kmeshctl_monitoring.md
@@ -12,30 +12,20 @@ kmeshctl monitoring [flags]
 # Enable/Disable Kmesh's accesslog:
 kmeshctl monitoring <kmesh-daemon-pod> --accesslog enable/disable
 
-# Enable/Disable services' metrics and accesslog generated from bpf:
+# Enable/Disable Kmesh's metrics and accesslog:
 kmeshctl monitoring <kmesh-daemon-pod> --all enable/disable
 
-# Enable/Disable workload granularity metrics:
-kmeshctl monitoring <kmesh-daemon-pod> --workloadMetrics enable/disable
-
 # If you want to change the monitoring functionality of all kmesh daemons in the cluster
-# Enable/Disable Kmesh's accesslog in each node:
 kmeshctl monitoring --accesslog enable/disable
-
-# Enable/Disable workload granularity metrics in each node:
-kmeshctl monitoring --workloadMetrics enable/disable
-
-#Enable/Disable services' and workloads' metrics and accesslog generated from bpf in each node:
 kmeshctl monitoring --all enable/disable
 ```
 
 ### Options
 
 ```
-      --accesslog string         Control accesslog enable or disable
-      --all string               Control accesslog and services' and workloads' metrics enable or disable together
-  -h, --help                     help for monitoring
-      --workloadMetrics string   Control granularity metrics enable or disable
+      --accesslog string   Control accesslog enable or disable
+      --all string         Control accesslog and metrics enable or disable together
+  -h, --help               help for monitoring
 ```
 
 ### SEE ALSO
diff --git a/docs/ctl/kmeshctl_version.md b/docs/ctl/kmeshctl_version.md
index 00155c29..d1267877 100644
--- a/docs/ctl/kmeshctl_version.md
+++ b/docs/ctl/kmeshctl_version.md
@@ -9,10 +9,10 @@ kmeshctl version [flags]
 ### Examples
 
 ```
-# Show version of kmeshctl
+# Show version of all kmesh components
 kmeshctl version
 
-# Show version info of a specific Kmesh daemon
+# Show version info of a specific kmesh daemon
 kmeshctl version <kmesh-daemon-pod>
 ```
 
diff --git a/pkg/bpf/ads/loader_enhanced.go b/pkg/bpf/ads/loader_enhanced.go
index 1f9332ff..3944c537 100644
--- a/pkg/bpf/ads/loader_enhanced.go
+++ b/pkg/bpf/ads/loader_enhanced.go
@@ -92,7 +92,7 @@ func (sc *BpfAds) Stop() error {
 }
 
 func (sc *BpfAds) GetKmeshConfigMap() *ebpf.Map {
-	return sc.SockConn.KmConfigmap
+	return sc.SockConn.KmeshConfigMap
 }
 
 func (sc *BpfAds) Load() error {
@@ -114,15 +114,15 @@ func (sc *BpfAds) Load() error {
 func (sc *BpfAds) ApiEnvCfg() error {
 	var err error
 
-	if err = utils.SetEnvByBpfMapId(sc.SockOps.KmeshSockopsMaps.KmListener, "Listener"); err != nil {
+	if err = utils.SetEnvByBpfMapId(sc.SockOps.KmeshSockopsMaps.KmeshListener, "Listener"); err != nil {
 		return err
 	}
 
-	if err = utils.SetEnvByBpfMapId(sc.SockOps.KmRouterconfig, "RouteConfiguration"); err != nil {
+	if err = utils.SetEnvByBpfMapId(sc.SockOps.MapOfRouterConfig, "RouteConfiguration"); err != nil {
 		return err
 	}
 
-	if err = utils.SetEnvByBpfMapId(sc.SockOps.KmCluster, "Cluster"); err != nil {
+	if err = utils.SetEnvByBpfMapId(sc.SockOps.KmeshCluster, "Cluster"); err != nil {
 		return err
 	}
 
@@ -175,7 +175,7 @@ func (sc *BpfAds) Detach() error {
 }
 
 func (sc *BpfAds) GetClusterStatsMap() *ebpf.Map {
-	return sc.SockOps.KmeshSockopsMaps.KmClusterstats
+	return sc.SockOps.KmeshSockopsMaps.KmeshClusterStats
 }
 
 func AdsL7Enabled() bool {
diff --git a/pkg/bpf/ads/sock_ops.go b/pkg/bpf/ads/sock_ops.go
index b4a78c11..838ed4f2 100644
--- a/pkg/bpf/ads/sock_ops.go
+++ b/pkg/bpf/ads/sock_ops.go
@@ -95,7 +95,7 @@ func (sc *BpfSockOps) loadKmeshFilterObjects() (*ebpf.CollectionSpec, error) {
 	)
 
 	opts.Maps.PinPath = sc.Info.MapPath
-	err = sc.KmTailcallprog.Update(
+	err = sc.KmeshTailCallProg.Update(
 		uint32(KMESH_TAIL_CALL_FILTER_CHAIN),
 		uint32(sc.FilterChainManager.FD()),
 		ebpf.UpdateAny)
@@ -103,7 +103,7 @@ func (sc *BpfSockOps) loadKmeshFilterObjects() (*ebpf.CollectionSpec, error) {
 		return nil, err
 	}
 
-	err = sc.KmTailcallprog.Update(
+	err = sc.KmeshTailCallProg.Update(
 		uint32(KMESH_TAIL_CALL_FILTER),
 		uint32(sc.FilterManager.FD()),
 		ebpf.UpdateAny)
@@ -121,7 +121,7 @@ func (sc *BpfSockOps) loadRouteConfigObjects() (*ebpf.CollectionSpec, error) {
 		opts ebpf.CollectionOptions
 	)
 	opts.Maps.PinPath = sc.Info.MapPath
-	err = sc.KmTailcallprog.Update(
+	err = sc.KmeshTailCallProg.Update(
 		uint32(KMESH_TAIL_CALL_ROUTER_CONFIG),
 		uint32(sc.RouteConfigManager.FD()),
 		ebpf.UpdateAny)
@@ -139,7 +139,7 @@ func (sc *BpfSockOps) loadKmeshClusterObjects() (*ebpf.CollectionSpec, error) {
 		opts ebpf.CollectionOptions
 	)
 	opts.Maps.PinPath = sc.Info.MapPath
-	err = sc.KmTailcallprog.Update(
+	err = sc.KmeshTailCallProg.Update(
 		uint32(KMESH_TAIL_CALL_CLUSTER),
 		uint32(sc.ClusterManager.FD()),
 		ebpf.UpdateAny)
@@ -208,7 +208,7 @@ func (sc *BpfSockOps) Attach() error {
 			return err
 		}
 	}
-	if err = sc.KmeshSockopsMaps.KmTailcallprog.Pin(tailCallmapPinPath); err != nil {
+	if err = sc.KmeshSockopsMaps.KmeshTailCallProg.Pin(tailCallmapPinPath); err != nil {
 		return err
 	}
 	return nil
diff --git a/pkg/bpf/bpf.go b/pkg/bpf/bpf.go
index 7129eecc..ab843e9a 100644
--- a/pkg/bpf/bpf.go
+++ b/pkg/bpf/bpf.go
@@ -340,10 +340,6 @@ func getNodeIPAddress(node *corev1.Node) [16]byte {
 
 func getNodePodSubGateway(node *corev1.Node) [16]byte {
 	podCIDR := node.Spec.PodCIDR
-	if podCIDR == "" {
-		return [16]byte{0}
-	}
-
 	_, subNet, err := net.ParseCIDR(podCIDR)
 	if err != nil {
 		log.Errorf("failed to resolve ip from podCIDR: %v", err)
diff --git a/pkg/controller/telemetry/metric.go b/pkg/controller/telemetry/metric.go
index 91e6ee25..26b412c0 100644
--- a/pkg/controller/telemetry/metric.go
+++ b/pkg/controller/telemetry/metric.go
@@ -51,13 +51,12 @@ const (
 var osStartTime time.Time
 
 type MetricController struct {
-	EnableAccesslog      atomic.Bool
-	EnableMonitoring     atomic.Bool
-	EnableWorkloadMetric atomic.Bool
-	workloadCache        cache.WorkloadCache
-	workloadMetricCache  map[workloadMetricLabels]*workloadMetricInfo
-	serviceMetricCache   map[serviceMetricLabels]*serviceMetricInfo
-	mutex                sync.RWMutex
+	EnableAccesslog     atomic.Bool
+	EnableMonitoring    atomic.Bool
+	workloadCache       cache.WorkloadCache
+	workloadMetricCache map[workloadMetricLabels]*workloadMetricInfo
+	serviceMetricCache  map[serviceMetricLabels]*serviceMetricInfo
+	mutex               sync.RWMutex
 }
 
 type workloadMetricInfo struct {
@@ -184,8 +183,6 @@ func NewMetric(workloadCache cache.WorkloadCache, enableMonitoring bool) *Metric
 		serviceMetricCache:  map[serviceMetricLabels]*serviceMetricInfo{},
 	}
 	m.EnableMonitoring.Store(enableMonitoring)
-	m.EnableAccesslog.Store(false)
-	m.EnableWorkloadMetric.Store(false)
 	return m
 }
 
@@ -256,21 +253,27 @@ func (m *MetricController) Run(ctx context.Context, mapOfTcpInfo *ebpf.Map) {
 				log.Errorf("get connection info failed: %v", err)
 				continue
 			}
+			workloadLabels := m.buildWorkloadMetric(&data)
 
-			workloadLabels := workloadMetricLabels{}
 			serviceLabels, accesslog := m.buildServiceMetric(&data)
-			if m.EnableWorkloadMetric.Load() {
-				workloadLabels = m.buildWorkloadMetric(&data)
-			}
 
+			workloadLabels.reporter = "-"
+			serviceLabels.reporter = "-"
+			if data.direction == constants.INBOUND {
+				workloadLabels.reporter = "destination"
+				serviceLabels.reporter = "destination"
+				accesslog.direction = "INBOUND"
+			}
+			if data.direction == constants.OUTBOUND {
+				workloadLabels.reporter = "source"
+				serviceLabels.reporter = "source"
+				accesslog.direction = "OUTBOUND"
+			}
 			if data.state == TCP_CLOSTED && m.EnableAccesslog.Load() {
 				OutputAccesslog(data, accesslog)
 			}
-
 			m.mutex.Lock()
-			if m.EnableWorkloadMetric.Load() {
-				m.updateWorkloadMetricCache(data, workloadLabels)
-			}
+			m.updateWorkloadMetricCache(data, workloadLabels)
 			m.updateServiceMetricCache(data, serviceLabels)
 			m.mutex.Unlock()
 		}
@@ -337,15 +340,6 @@ func (m *MetricController) buildWorkloadMetric(data *requestMetric) workloadMetr
 	}
 
 	trafficLabels := buildWorkloadMetric(dstWorkload, srcWorkload)
-	trafficLabels.reporter = "-"
-
-	if data.direction == constants.INBOUND {
-		trafficLabels.reporter = "destination"
-	}
-	if data.direction == constants.OUTBOUND {
-		trafficLabels.reporter = "source"
-	}
-
 	trafficLabels.destinationPodAddress = dstIP
 	trafficLabels.requestProtocol = "tcp"
 	trafficLabels.responseFlags = "-"
@@ -363,18 +357,8 @@ func (m *MetricController) buildServiceMetric(data *requestMetric) (serviceMetri
 
 	dstWorkload, dstIp := m.getWorkloadByAddress(restoreIPv4(dstAddr))
 	srcWorkload, srcIp := m.getWorkloadByAddress(restoreIPv4(srcAddr))
-	trafficLabels, accesslog := buildServiceMetric(dstWorkload, srcWorkload, data.dstPort)
-	trafficLabels.reporter = "-"
-
-	if data.direction == constants.INBOUND {
-		trafficLabels.reporter = "destination"
-		accesslog.direction = "INBOUND"
-	}
-	if data.direction == constants.OUTBOUND {
-		trafficLabels.reporter = "source"
-		accesslog.direction = "OUTBOUND"
-	}
 
+	trafficLabels, accesslog := buildServiceMetric(dstWorkload, srcWorkload, data.dstPort)
 	trafficLabels.requestProtocol = "tcp"
 	trafficLabels.responseFlags = "-"
 	trafficLabels.connectionSecurityPolicy = "mutual_tls"
diff --git a/pkg/controller/workload/workload_controller.go b/pkg/controller/workload/workload_controller.go
index 311c8b8d..dbe42ec9 100644
--- a/pkg/controller/workload/workload_controller.go
+++ b/pkg/controller/workload/workload_controller.go
@@ -157,7 +157,3 @@ func (c *Controller) SetAccesslogTrigger(enabled bool) {
 func (c *Controller) GetAccesslogTrigger() bool {
 	return c.MetricController.EnableAccesslog.Load()
 }
-
-func (c *Controller) SetWorkloadMetricTrigger(enable bool) {
-	c.MetricController.EnableWorkloadMetric.Store(enable)
-}
diff --git a/pkg/kube/portforwarder.go b/pkg/kube/portforwarder.go
index 0c27a820..6375fd7b 100644
--- a/pkg/kube/portforwarder.go
+++ b/pkg/kube/portforwarder.go
@@ -19,6 +19,7 @@ package kube
 import (
 	"context"
 	"fmt"
+	"io"
 	"net"
 	"os"
 	"strconv"
@@ -75,7 +76,7 @@ func (p *portForwarder) Start() error {
 	}
 
 	ports := fmt.Sprintf("%d:%d", p.localPort, p.podPort)
-	ioStreams := genericiooptions.IOStreams{In: os.Stdin, Out: os.Stdout, ErrOut: os.Stderr}
+	ioStreams := genericiooptions.IOStreams{In: os.Stdin, Out: io.Discard, ErrOut: os.Stderr}
 	pfOptions := portforward.NewDefaultPortForwardOptions(ioStreams)
 	pfOptions.Address = address
 
diff --git a/pkg/status/status_server.go b/pkg/status/status_server.go
index 533d95f0..bdd5309f 100644
--- a/pkg/status/status_server.go
+++ b/pkg/status/status_server.go
@@ -49,6 +49,8 @@ var log = logger.NewLoggerScope("status")
 const (
 	adminAddr = "localhost:15200"
 
+	patternHelp               = "/help"
+	patternOptions            = "/options"
 	patternVersion            = "/version"
 	patternBpfAdsMaps         = "/debug/config_dump/bpf/kernel-native"
 	patternBpfWorkloadMaps    = "/debug/config_dump/bpf/dual-engine"
@@ -59,7 +61,6 @@ const (
 	patternLoggers            = "/debug/loggers"
 	patternAccesslog          = "/accesslog"
 	patternMonitoring         = "/monitoring"
-	patternWorkloadMetrics    = "/workload_metrics"
 	patternAuthz              = "/authz"
 
 	bpfLoggerName = "bpf"
@@ -91,6 +92,8 @@ func NewServer(c *controller.XdsClient, configs *options.BootstrapConfigs, confi
 		WriteTimeout: httpTimeout,
 	}
 
+	s.mux.HandleFunc(patternHelp, s.httpHelp)
+	s.mux.HandleFunc(patternOptions, s.httpOptions)
 	s.mux.HandleFunc(patternVersion, s.version)
 	s.mux.HandleFunc(patternBpfAdsMaps, s.bpfAdsMaps)
 	s.mux.HandleFunc(patternBpfWorkloadMaps, s.bpfWorkloadMaps)
@@ -99,7 +102,6 @@ func NewServer(c *controller.XdsClient, configs *options.BootstrapConfigs, confi
 	s.mux.HandleFunc(patternLoggers, s.loggersHandler)
 	s.mux.HandleFunc(patternAccesslog, s.accesslogHandler)
 	s.mux.HandleFunc(patternMonitoring, s.monitoringHandler)
-	s.mux.HandleFunc(patternWorkloadMetrics, s.workloadMetricHandler)
 	s.mux.HandleFunc(patternAuthz, s.authzHandler)
 
 	// TODO: add dump certificate, authorizationPolicies and services
@@ -114,6 +116,30 @@ func NewServer(c *controller.XdsClient, configs *options.BootstrapConfigs, confi
 	return s
 }
 
+func (s *Server) httpHelp(w http.ResponseWriter, r *http.Request) {
+	w.WriteHeader(http.StatusOK)
+
+	fmt.Fprintf(w, "\t%s: %s\n", patternHelp,
+		"print list of commands")
+	fmt.Fprintf(w, "\t%s: %s\n", patternOptions,
+		"print config options")
+	fmt.Fprintf(w, "\t%s: %s\n", patternBpfAdsMaps,
+		"print bpf kmesh maps of ads mode in kernel")
+	fmt.Fprintf(w, "\t%s: %s\n", patternBpfWorkloadMaps,
+		"print bpf kmesh maps of workload mode in kernel")
+	fmt.Fprintf(w, "\t%s: %s\n", patternConfigDumpAds,
+		"dump xDS[Listener, Route, Cluster] configurations")
+	fmt.Fprintf(w, "\t%s: %s\n", patternConfigDumpWorkload,
+		"dump workload configurations")
+	fmt.Fprintf(w, "\t%s: %s\n", patternLoggers,
+		"get or set logger level")
+}
+
+func (s *Server) httpOptions(w http.ResponseWriter, r *http.Request) {
+	w.WriteHeader(http.StatusOK)
+	fmt.Fprintln(w, s.config.String())
+}
+
 func (s *Server) version(w http.ResponseWriter, r *http.Request) {
 	v := version.Get()
 
@@ -285,35 +311,6 @@ func (s *Server) monitoringHandler(w http.ResponseWriter, r *http.Request) {
 
 	s.xdsClient.WorkloadController.SetMonitoringTrigger(enabled)
 	s.xdsClient.WorkloadController.SetAccesslogTrigger(enabled)
-	s.xdsClient.WorkloadController.SetWorkloadMetricTrigger(enabled)
-	w.WriteHeader(http.StatusOK)
-}
-
-func (s *Server) workloadMetricHandler(w http.ResponseWriter, r *http.Request) {
-	if r.Method != http.MethodPost {
-		http.Error(w, "Method Not Allowed", http.StatusMethodNotAllowed)
-		return
-	}
-
-	info := r.URL.Query().Get("enable")
-	enabled, err := strconv.ParseBool(info)
-	if err != nil {
-		w.WriteHeader(http.StatusBadRequest)
-		_, _ = w.Write([]byte(fmt.Sprintf("invalid accesslog enable=%s", info)))
-		return
-	}
-
-	configMap, err := bpf.GetKmeshConfigMap(s.kmeshConfigMap)
-	if err != nil {
-		http.Error(w, fmt.Sprintf("failed to get kmeshConfigMap: %v", err), http.StatusBadRequest)
-		return
-	}
-	if configMap.EnableMonitoring == constants.DISABLED && enabled {
-		http.Error(w, "Kmesh monitoring is disable, cannot enable workload metrics.", http.StatusBadRequest)
-		return
-	}
-
-	s.xdsClient.WorkloadController.SetWorkloadMetricTrigger(enabled)
 	w.WriteHeader(http.StatusOK)
 }
 
diff --git a/samples/addons/kiali.yaml b/samples/addons/kiali.yaml
deleted file mode 100644
index 4f26f976..00000000
--- a/samples/addons/kiali.yaml
+++ /dev/null
@@ -1,387 +0,0 @@
----
-# Source: kiali-server/templates/serviceaccount.yaml
-apiVersion: v1
-kind: ServiceAccount
-metadata:
-  name: kiali
-  namespace: "kmesh-system"
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-...
----
-# Source: kiali-server/templates/configmap.yaml
-apiVersion: v1
-kind: ConfigMap
-metadata:
-  name: kiali
-  namespace: "kmesh-system"
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-data:
-  config.yaml: |
-    additional_display_details:
-    - annotation: kiali.io/api-spec
-      icon_annotation: kiali.io/api-type
-      title: API Documentation
-    auth:
-      strategy: anonymous
-    clustering:
-      autodetect_secrets:
-        enabled: true
-        label: kiali.io/multiCluster=true
-    deployment:
-      cluster_wide_access: true
-      image_name: quay.io/kiali/kiali
-      image_pull_policy: IfNotPresent
-      image_version: v2.1
-      ingress_enabled: false
-      instance_name: kiali
-      logger:
-        log_format: text
-        log_level: info
-        sampler_rate: "1"
-        time_field_format: 2006-01-02T15:04:05Z07:00
-      namespace: kmesh-system
-      pod_labels:
-        sidecar.istio.io/inject: "false"
-      remote_cluster_resources_only: false
-      replicas: 1
-      resources:
-        limits:
-          memory: 1Gi
-        requests:
-          cpu: 10m
-          memory: 64Mi
-      secret_name: kiali
-      version_label: v2.1.0
-      view_only_mode: false
-    external_services:
-      prometheus:
-        url: http://prometheus.kmesh-system:9090
-      grafana:
-        internal_url: http://grafana.kmesh-system:3000
-      custom_dashboards:
-        enabled: true
-      istio:
-        root_namespace: istio-system
-        gateway_api_classes:
-        - class_name: istio-waypoint
-          name: waypoint
-      tracing:
-        enabled: false
-    istio_namespace: istio-system
-    kiali_feature_flags:
-      validations:
-        ignore:
-        - KIA1301
-    server:
-      observability:
-        metrics:
-          enabled: true
-          port: 9090
-      port: 20001
-      web_root: /kiali
-...
----
-# Source: kiali-server/templates/role.yaml
-apiVersion: rbac.authorization.k8s.io/v1
-kind: ClusterRole
-metadata:
-  name: kiali
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-rules:
-- apiGroups: [""]
-  resources:
-  - configmaps
-  - endpoints
-  - pods/log
-  verbs:
-  - get
-  - list
-  - watch
-- apiGroups: [""]
-  resources:
-  - namespaces
-  - pods
-  - replicationcontrollers
-  - services
-  verbs:
-  - get
-  - list
-  - watch
-  - patch
-- apiGroups: [""]
-  resources:
-  - pods/portforward
-  verbs:
-  - create
-  - post
-- apiGroups: ["extensions", "apps"]
-  resources:
-  - daemonsets
-  - deployments
-  - replicasets
-  - statefulsets
-  verbs:
-  - get
-  - list
-  - watch
-  - patch
-- apiGroups: ["batch"]
-  resources:
-  - cronjobs
-  - jobs
-  verbs:
-  - get
-  - list
-  - watch
-  - patch
-- apiGroups:
-  - networking.istio.io
-  - security.istio.io
-  - extensions.istio.io
-  - telemetry.istio.io
-  - gateway.networking.k8s.io
-  resources: ["*"]
-  verbs:
-  - get
-  - list
-  - watch
-  - create
-  - delete
-  - patch
-- apiGroups: ["apps.openshift.io"]
-  resources:
-  - deploymentconfigs
-  verbs:
-  - get
-  - list
-  - watch
-  - patch
-- apiGroups: ["project.openshift.io"]
-  resources:
-  - projects
-  verbs:
-  - get
-- apiGroups: ["route.openshift.io"]
-  resources:
-  - routes
-  verbs:
-  - get
-- apiGroups: ["authentication.k8s.io"]
-  resources:
-  - tokenreviews
-  verbs:
-  - create
-- apiGroups: ["oauth.openshift.io"]
-  resources:
-  - oauthclients
-  resourceNames:
-  - kiali-istio-system
-  verbs:
-  - get
-- apiGroups: ["admissionregistration.k8s.io"]
-  resources:
-  - mutatingwebhookconfigurations
-  verbs:
-  - get
-  - list
-  - watch
-...
----
-# Source: kiali-server/templates/rolebinding.yaml
-apiVersion: rbac.authorization.k8s.io/v1
-kind: ClusterRoleBinding
-metadata:
-  name: kiali
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-roleRef:
-  apiGroup: rbac.authorization.k8s.io
-  kind: ClusterRole
-  name: kiali
-subjects:
-- kind: ServiceAccount
-  name: kiali
-  namespace: "kmesh-system"
-...
----
-# Source: kiali-server/templates/service.yaml
-apiVersion: v1
-kind: Service
-metadata:
-  name: kiali
-  namespace: "kmesh-system"
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-  annotations:
-spec:
-  ports:
-  - name: http
-    appProtocol: http
-    protocol: TCP
-    port: 20001
-  - name: http-metrics
-    appProtocol: http
-    protocol: TCP
-    port: 9090
-  selector:
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-...
----
-# Source: kiali-server/templates/deployment.yaml
-apiVersion: apps/v1
-kind: Deployment
-metadata:
-  name: kiali
-  namespace: "kmesh-system"
-  labels:
-    helm.sh/chart: kiali-server-2.1.0
-    app: kiali
-    app.kubernetes.io/name: kiali
-    app.kubernetes.io/instance: kiali
-    version: "v2.1.0"
-    app.kubernetes.io/version: "v2.1.0"
-    app.kubernetes.io/part-of: "kiali"
-spec:
-  replicas: 1
-  selector:
-    matchLabels:
-      app.kubernetes.io/name: kiali
-      app.kubernetes.io/instance: kiali
-  strategy:
-    rollingUpdate:
-      maxSurge: 1
-      maxUnavailable: 1
-    type: RollingUpdate
-  template:
-    metadata:
-      name: kiali
-      labels:
-        helm.sh/chart: kiali-server-2.1.0
-        app: kiali
-        app.kubernetes.io/name: kiali
-        app.kubernetes.io/instance: kiali
-        version: "v2.1.0"
-        app.kubernetes.io/version: "v2.1.0"
-        app.kubernetes.io/part-of: "kiali"
-        sidecar.istio.io/inject: "false"
-      annotations:
-        checksum/config: b6f715c420df4b1ad451aff16d99961cff61f0016b250b5a4fa1d897252be282
-        prometheus.io/scrape: "true"
-        prometheus.io/port: "9090"
-        kiali.io/dashboards: go,kiali
-    spec:
-      serviceAccountName: kiali
-      containers:
-      - image: "quay.io/kiali/kiali:v2.1"
-        imagePullPolicy: IfNotPresent
-        name: kiali
-        command:
-        - "/opt/kiali/kiali"
-        - "-config"
-        - "/kiali-configuration/config.yaml"
-        securityContext:
-          allowPrivilegeEscalation: false
-          privileged: false
-          readOnlyRootFilesystem: true
-          runAsNonRoot: true
-          capabilities:
-            drop:
-            - ALL
-        ports:
-        - name: api-port
-          containerPort: 20001
-        - name: http-metrics
-          containerPort: 9090
-        readinessProbe:
-          httpGet:
-            path: /kiali/healthz
-            port: api-port
-            scheme: HTTP
-          initialDelaySeconds: 5
-          periodSeconds: 30
-        livenessProbe:
-          httpGet:
-            path: /kiali/healthz
-            port: api-port
-            scheme: HTTP
-          initialDelaySeconds: 5
-          periodSeconds: 30
-        env:
-        - name: ACTIVE_NAMESPACE
-          valueFrom:
-            fieldRef:
-              fieldPath: metadata.namespace
-        - name: LOG_LEVEL
-          value: "info"
-        - name: LOG_FORMAT
-          value: "text"
-        - name: LOG_TIME_FIELD_FORMAT
-          value: "2006-01-02T15:04:05Z07:00"
-        - name: LOG_SAMPLER_RATE
-          value: "1"
-        volumeMounts:
-        - name: kiali-configuration
-          mountPath: "/kiali-configuration"
-        - name: kiali-cert
-          mountPath: "/kiali-cert"
-        - name: kiali-secret
-          mountPath: "/kiali-secret"
-        - name: kiali-cabundle
-          mountPath: "/kiali-cabundle"
-        resources:
-          limits:
-            memory: 1Gi
-          requests:
-            cpu: 10m
-            memory: 64Mi
-      volumes:
-      - name: kiali-configuration
-        configMap:
-          name: kiali
-      - name: kiali-cert
-        secret:
-          secretName: istio.kiali-service-account
-          optional: true
-      - name: kiali-secret
-        secret:
-          secretName: kiali
-          optional: true
-      - name: kiali-cabundle
-        configMap:
-          name: kiali-cabundle
-          optional: true
-...
\ No newline at end of file
diff --git a/samples/addons/prometheus_recording_istio.yaml b/samples/addons/prometheus_recording_istio.yaml
index 916b5c4b..99858946 100644
--- a/samples/addons/prometheus_recording_istio.yaml
+++ b/samples/addons/prometheus_recording_istio.yaml
@@ -47,6 +47,19 @@ data:
     - /etc/config/rules
     - /etc/config/alerts
     scrape_configs:
+    - job_name: prometheus
+      metrics_path: /status/metric
+      kubernetes_sd_configs:
+      - role: pod
+      relabel_configs:
+      - action: keep
+        regex: kmesh
+        source_labels: [__meta_kubernetes_pod_label_app]
+      - action: replace
+        source_labels: [__meta_kubernetes_pod_ip]
+        target_label: __address__
+        replacement: $1:15020  
+
     - bearer_token_file: /var/run/secrets/kubernetes.io/serviceaccount/token
       job_name: kubernetes-apiservers
       kubernetes_sd_configs:
@@ -286,6 +299,7 @@ data:
         source_labels:
         - __meta_kubernetes_pod_node_name
         target_label: node
+      - action: replace
       metric_relabel_configs:
       - source_labels: [app]
         regex: 'kmesh'


Test patch:
diff --git a/pkg/controller/telemetry/metric_test.go b/pkg/controller/telemetry/metric_test.go
index dd597ccb..15ce18ba 100644
--- a/pkg/controller/telemetry/metric_test.go
+++ b/pkg/controller/telemetry/metric_test.go
@@ -489,7 +489,6 @@ func TestBuildworkloadMetric(t *testing.T) {
 				requestProtocol:              "tcp",
 				responseFlags:                "-",
 				connectionSecurityPolicy:     "mutual_tls",
-				reporter:                     "-",
 			},
 			wantErr: false,
 		},
@@ -627,11 +626,10 @@ func TestBuildServiceMetric(t *testing.T) {
 				requestProtocol:              "tcp",
 				responseFlags:                "-",
 				connectionSecurityPolicy:     "mutual_tls",
-				reporter:                     "source",
 			},
 			wantErr: false,
 			wantLogInfo: logInfo{
-				direction:            "OUTBOUND",
+				direction:            "-",
 				sourceAddress:        "10.19.25.31:8000",
 				sourceWorkload:       "kmesh",
 				sourceNamespace:      "kmesh-system",