fedora linux命令setup进入后无法进入network configure

时间:2021-09-25 20:29:33

问题: setup进入后无法进入network configure

[root@linux ~]# setup

Traceback (most recent call last):
File "/usr/sbin/system-config-network-tui", line 20, in <module>
from netconfpkg import NC_functions
File "/usr/share/system-config-network/netconfpkg/NC_functions.py", line 38, in <module>
locale.setlocale(locale.LC_ALL, "")
File "/usr/lib/python2.5/locale.py", line 478, in setlocale
return _setlocale(category, locale)

locale.Error: unsupported locale setting Repay:

问题:

[root@linux sbin]# locale

locale: Cannot set LC_CTYPE to default locale: No such file or directory
locale: Cannot set LC_MESSAGES to default locale: No such file or directory
locale: Cannot set LC_ALL to default locale: No such file or directory
LANG=zh_CN.UTF-8
LC_CTYPE="en"
LC_NUMERIC="en"
LC_TIME="en"
LC_COLLATE="en"
LC_MONETARY="en"
LC_MESSAGES="en"
LC_PAPER="en"
LC_NAME="en"
LC_ADDRESS="en"
LC_TELEPHONE="en"
LC_MEASUREMENT="en"
LC_IDENTIFICATION="en"
LC_ALL=en

解决方法:

[root@linux ~]# export LC_ALL=C 

[root@linux ~]# locale

LANG=zh_CN.UTF-8
LC_CTYPE="C"
LC_NUMERIC="C"
LC_TIME="C"
LC_COLLATE="C"
LC_MONETARY="C"
LC_MESSAGES="C"
LC_PAPER="C"
LC_NAME="C"
LC_ADDRESS="C"
LC_TELEPHONE="C"
LC_MEASUREMENT="C"
LC_IDENTIFICATION="C"

LC_ALL=C 

测试成功:

[root@linux ~]# setup