diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index 7fe2c256c..bec4b78e6 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -23,10 +23,12 @@ A clear and concise description of what you expected to happen. **Screenshots** If applicable, add screenshots to help explain your problem. -**Linux Server/Desktop (please complete the following information):** - - OS: [e.g. iOS] - - Kernel Version [e.g. 5.10] - - Version [e.g. 0.1.3-20220313-69c1e0] +**Linux Server/Android (please complete the following information):** + +- OS: [e.g. Ubuntu 21.04] +- Arch: [e.g. arm_aarch64] +- Kernel Version: [e.g. 5.10] +- Version: [e.g. 0.1.3-20220313-69c1e0] **Additional context** Add any other context about the problem here. diff --git a/main.go b/main.go index 25e5c9cc0..84fb670fe 100644 --- a/main.go +++ b/main.go @@ -4,9 +4,14 @@ import ( "ecapture/cli" "ecapture/pkg/util/ebpf" "ecapture/pkg/util/kernel" + "fmt" "log" ) +const ( + BTF_NOT_SUPPORT = "You can compile a no BTF version by youeself with command `make nocore`,Please read Makefile for more info." +) + var ( enableCORE = "true" ) @@ -28,11 +33,11 @@ func main() { // BTF支持情况检测 enable, e := ebpf.IsEnableBTF() if e != nil { - log.Fatal(err) + log.Fatal(fmt.Sprintf("Can't found BTF config with error:%v.\n"+BTF_NOT_SUPPORT, e)) } if !enable { log.Fatal("BTF not support, please check it. shell: cat /boot/config-`uname -r` | grep CONFIG_DEBUG_INFO_BTF \n " + - "Or you can compile a no BTF version with youeself by `make nocore` command,Please read Makefile for more info.") + BTF_NOT_SUPPORT) } }