Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Failed to retrieve UFW status. #7527

Open
Wuchieh opened this issue Dec 23, 2024 · 11 comments
Open

[Bug] Failed to retrieve UFW status. #7527

Wuchieh opened this issue Dec 23, 2024 · 11 comments
Assignees
Milestone

Comments

@Wuchieh
Copy link

Wuchieh commented Dec 23, 2024

Contact Information

No response

1Panel Version

v1.10.22-lts

Problem Description

My UFW is already enabled, but it is displayed as disabled in 1Panel.

我的 ufw 是已经开启的状态,但是在 1panel 中却显示成未启用

Steps to Reproduce

When the system language is neither English nor Simplified Chinese, open the /hosts/firewall/port screen.

当系统不是英文或简体中文时,开启 /hosts/firewall/port 画面

The expected correct result

No response

Related log output

No response

Additional Information

It is recommended to set the environment before executing the status query command in backend/utils/firewall/client/ufw.go.

For example:
LANGUAGE=en_US:en ufw status

建议在 backend/utils/firewall/client/ufw.go 执行状态查询命令前 设置环境

如: LANGUAGE=en_US:en ufw status

@ssongliu
Copy link
Member

感谢反馈,麻烦执行 which ufw 看一下

@wanghe-fit2cloud
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Thanks for the feedback, please run which ufw to take a look

@Wuchieh
Copy link
Author

Wuchieh commented Dec 23, 2024

感謝回饋,麻煩請看which ufw一下

感谢反馈,麻烦执行 which ufw 看一下

$ which ufw
/usr/sbin/ufw

@wanghe-fit2cloud
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Thanks for the feedback, please take a look at which ufw

Thanks for the feedback, please run which ufw to take a look

$ which ufw
/usr/sbin/ufw

@ssongliu
Copy link
Member

这样应该是能正常获取到的,这两部分哪里有问题方便截图看看吗
image

@wanghe-fit2cloud
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


This should be able to be obtained normally. Can you take a screenshot to see if there are any problems with these two parts?
image

@Wuchieh
Copy link
Author

Wuchieh commented Dec 23, 2024

这样应该是能正常获取到的,这两部分哪里有问题方便截图看看吗 image

不好意思,我發現我在 Steps to Reproduce 網頁路徑打錯了,正確應該是 /hosts/firewall/port

這是截圖
image

@1Panel-dev 1Panel-dev deleted a comment from wanghe-fit2cloud Dec 23, 2024
@ssongliu
Copy link
Member

感謝感謝,下個版本我們優化該部分判斷

@wanghe-fit2cloud
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Thank you. We will optimize this part in the next version.

@Wuchieh
Copy link
Author

Wuchieh commented Dec 23, 2024

麻煩再截圖看一下下面命令返回

ufw status | grep Status

防火墻頁面有開啟按鈕,點擊能正常打開嗎?

image
我的 ufw 本來就是開啟的狀態,點下後好像只是單純的重啟了 1Panel。

@wanghe-fit2cloud
Copy link
Member

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Please take another screenshot and check the following command to return

ufw status | grep Status

There is an enable button on the firewall page. Can it be opened normally by clicking on it?

image
My ufw is originally turned on, but after clicking it, it seems to simply restart 1Panel.

@wanghe-fit2cloud wanghe-fit2cloud changed the title [Bug] Failed to retrieve UFW status. ufw 状态获取错误 [Bug] Failed to retrieve UFW status. Dec 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants