centos 7修改系统语言
查看当前系统语言:
1 [root@localhost http]# env | grep LANG 2 LANG=en_US.UTF-8
检查字符集:
1 [root@localhost http]# locale -a 2 aa_DJ 3 aa_DJ.iso88591 4 aa_DJ.utf8 5 aa_ER 6 aa_ER@saaho 7 aa_ER.utf8 8 aa_ER.utf8@saaho 9 aa_ET 10 aa_ET.utf8 11 af_ZA 12 af_ZA.iso88591 13 af_ZA.utf8 14 am_ET 15 am_ET.utf8 16 an_ES 17 an_ES.iso885915 18 an_ES.utf8 19 ar_AE 20 ar_AE.iso88596 21 ar_AE.utf8 22 ar_BH 23 ar_BH.iso88596 24 ar_BH.utf8 25 ar_DZ 26 ar_DZ.iso88596 27 ar_DZ.utf8 28 ar_EG 29 ar_EG.iso88596 30 ar_EG.utf8 31 ar_IN 32 ar_IN.utf8 33 ar_IQ 34 ar_IQ.iso88596 35 ar_IQ.utf8 36 ar_JO 37 ar_JO.iso88596 38 ar_JO.utf8 39 ar_KW 40 ar_KW.iso88596 41 ar_KW.utf8 42 ar_LB 43 ar_LB.iso88596 44 ar_LB.utf8 45 ar_LY 46 ar_LY.iso88596 47 ar_LY.utf8 48 ar_MA 49 ar_MA.iso88596 50 ar_MA.utf8 51 ar_OM 52 ar_OM.iso88596 53 ar_OM.utf8 54 ar_QA 55 ar_QA.iso88596 56 ar_QA.utf8 57 ar_SA 58 ar_SA.iso88596 59 ar_SA.utf8 60 ar_SD 61 ar_SD.iso88596 62 ar_SD.utf8 63 ar_SY 64 ar_SY.iso88596 65 ar_SY.utf8 66 ar_TN 67 ar_TN.iso88596 68 ar_TN.utf8 69 ar_YE 70 ar_YE.iso88596 71 ar_YE.utf8 72 as_IN 73 as_IN.utf8 74 ast_ES 75 ast_ES.iso885915 76 ast_ES.utf8 77 ayc_PE 78 ayc_PE.utf8 79 az_AZ 80 az_AZ.utf8 81 be_BY 82 be_BY.cp1251 83 be_BY@latin 84 be_BY.utf8 85 be_BY.utf8@latin 86 bem_ZM 87 bem_ZM.utf8 88 ber_DZ 89 ber_DZ.utf8 90 ber_MA 91 ber_MA.utf8 92 bg_BG 93 bg_BG.cp1251 94 bg_BG.utf8 95 bho_IN 96 bho_IN.utf8 97 bn_BD 98 bn_BD.utf8 99 bn_IN 100 bn_IN.utf8 101 bo_CN 102 bo_CN.utf8 103 bo_IN 104 bo_IN.utf8 105 bokmal 106 bokm 107 br_FR 108 br_FR@euro 109 br_FR.iso88591 110 br_FR.iso885915@euro 111 br_FR.utf8 112 brx_IN 113 brx_IN.utf8 114 bs_BA 115 bs_BA.iso88592 116 bs_BA.utf8 117 byn_ER 118 byn_ER.utf8 119 C 120 ca_AD 121 ca_AD.iso885915 122 ca_AD.utf8 123 ca_ES 124 ca_ES@euro 125 ca_ES.iso88591 126 ca_ES.iso885915@euro 127 ca_ES.utf8 128 ca_FR 129 ca_FR.iso885915 130 ca_FR.utf8 131 ca_IT 132 ca_IT.iso885915 133 ca_IT.utf8 134 catalan 135 crh_UA 136 crh_UA.utf8 137 croatian 138 csb_PL 139 csb_PL.utf8 140 cs_CZ 141 cs_CZ.iso88592 142 cs_CZ.utf8 143 cv_RU 144 cv_RU.utf8 145 cy_GB 146 cy_GB.iso885914 147 cy_GB.utf8 148 czech 149 da_DK 150 da_DK.iso88591 151 da_DK.iso885915 152 da_DK.utf8 153 danish 154 dansk 155 de_AT 156 de_AT@euro 157 de_AT.iso88591 158 de_AT.iso885915@euro 159 de_AT.utf8 160 de_BE 161 de_BE@euro 162 de_BE.iso88591 163 de_BE.iso885915@euro 164 de_BE.utf8 165 de_CH 166 de_CH.iso88591 167 de_CH.utf8 168 de_DE 169 de_DE@euro 170 de_DE.iso88591 171 de_DE.iso885915@euro 172 de_DE.utf8 173 de_LU 174 de_LU@euro 175 de_LU.iso88591 176 de_LU.iso885915@euro 177 de_LU.utf8 178 deutsch 179 doi_IN 180 doi_IN.utf8 181 dutch 182 dv_MV 183 dv_MV.utf8 184 dz_BT 185 dz_BT.utf8 186 eesti 187 el_CY 188 el_CY.iso88597 189 el_CY.utf8 190 el_GR 191 el_GR@euro 192 el_GR.iso88597 193 el_GR.iso88597@euro 194 el_GR.utf8 195 en_AG 196 en_AG.utf8 197 en_AU 198 en_AU.iso88591 199 en_AU.utf8 200 en_BW 201 en_BW.iso88591 202 en_BW.utf8 203 en_CA 204 en_CA.iso88591 205 en_CA.utf8 206 en_DK 207 en_DK.iso88591 208 en_DK.utf8 209 en_GB 210 en_GB.iso88591 211 en_GB.iso885915 212 en_GB.utf8 213 en_HK 214 en_HK.iso88591 215 en_HK.utf8 216 en_IE 217 en_IE@euro 218 en_IE.iso88591 219 en_IE.iso885915@euro 220 en_IE.utf8 221 en_IN 222 en_IN.utf8 223 en_NG 224 en_NG.utf8 225 en_NZ 226 en_NZ.iso88591 227 en_NZ.utf8 228 en_PH 229 en_PH.iso88591 230 en_PH.utf8 231 en_SG 232 en_SG.iso88591 233 en_SG.utf8 234 en_US 235 en_US.iso88591 236 en_US.iso885915 237 en_US.utf8 238 en_ZA 239 en_ZA.iso88591 240 en_ZA.utf8 241 en_ZM 242 en_ZM.utf8 243 en_ZW 244 en_ZW.iso88591 245 en_ZW.utf8 246 es_AR 247 es_AR.iso88591 248 es_AR.utf8 249 es_BO 250 es_BO.iso88591 251 es_BO.utf8 252 es_CL 253 es_CL.iso88591 254 es_CL.utf8 255 es_CO 256 es_CO.iso88591 257 es_CO.utf8 258 es_CR 259 es_CR.iso88591 260 es_CR.utf8 261 es_CU 262 es_CU.utf8 263 es_DO 264 es_DO.iso88591 265 es_DO.utf8 266 es_EC 267 es_EC.iso88591 268 es_EC.utf8 269 es_ES 270 es_ES@euro 271 es_ES.iso88591 272 es_ES.iso885915@euro 273 es_ES.utf8 274 es_GT 275 es_GT.iso88591 276 es_GT.utf8 277 es_HN 278 es_HN.iso88591 279 es_HN.utf8 280 es_MX 281 es_MX.iso88591 282 es_MX.utf8 283 es_NI 284 es_NI.iso88591 285 es_NI.utf8 286 es_PA 287 es_PA.iso88591 288 es_PA.utf8 289 es_PE 290 es_PE.iso88591 291 es_PE.utf8 292 es_PR 293 es_PR.iso88591 294 es_PR.utf8 295 es_PY 296 es_PY.iso88591 297 es_PY.utf8 298 es_SV 299 es_SV.iso88591 300 es_SV.utf8 301 estonian 302 es_US 303 es_US.iso88591 304 es_US.utf8 305 es_UY 306 es_UY.iso88591 307 es_UY.utf8 308 es_VE 309 es_VE.iso88591 310 es_VE.utf8 311 et_EE 312 et_EE.iso88591 313 et_EE.iso885915 314 et_EE.utf8 315 eu_ES 316 eu_ES@euro 317 eu_ES.iso88591 318 eu_ES.iso885915@euro 319 eu_ES.utf8 320 fa_IR 321 fa_IR.utf8 322 ff_SN 323 ff_SN.utf8 324 fi_FI 325 fi_FI@euro 326 fi_FI.iso88591 327 fi_FI.iso885915@euro 328 fi_FI.utf8 329 fil_PH 330 fil_PH.utf8 331 finnish 332 fo_FO 333 fo_FO.iso88591 334 fo_FO.utf8 335 fran栩s 336 fr_BE 337 fr_BE@euro 338 fr_BE.iso88591 339 fr_BE.iso885915@euro 340 fr_BE.utf8 341 fr_CA 342 fr_CA.iso88591 343 fr_CA.utf8 344 fr_CH 345 fr_CH.iso88591 346 fr_CH.utf8 347 french 348 fr_FR 349 fr_FR@euro 350 fr_FR.iso88591 351 fr_FR.iso885915@euro 352 fr_FR.utf8 353 fr_LU 354 fr_LU@euro 355 fr_LU.iso88591 356 fr_LU.iso885915@euro 357 fr_LU.utf8 358 fur_IT 359 fur_IT.utf8 360 fy_DE 361 fy_DE.utf8 362 fy_NL 363 fy_NL.utf8 364 ga_IE 365 ga_IE@euro 366 ga_IE.iso88591 367 ga_IE.iso885915@euro 368 ga_IE.utf8 369 galego 370 galician 371 gd_GB 372 gd_GB.iso885915 373 gd_GB.utf8 374 german 375 gez_ER 376 gez_ER@abegede 377 gez_ER.utf8 378 gez_ER.utf8@abegede 379 gez_ET 380 gez_ET@abegede 381 gez_ET.utf8 382 gez_ET.utf8@abegede 383 gl_ES 384 gl_ES@euro 385 gl_ES.iso88591 386 gl_ES.iso885915@euro 387 gl_ES.utf8 388 greek 389 gu_IN 390 gu_IN.utf8 391 gv_GB 392 gv_GB.iso88591 393 gv_GB.utf8 394 ha_NG 395 ha_NG.utf8 396 hebrew 397 he_IL 398 he_IL.iso88598 399 he_IL.utf8 400 hi_IN 401 hi_IN.utf8 402 hne_IN 403 hne_IN.utf8 404 hr_HR 405 hr_HR.iso88592 406 hr_HR.utf8 407 hrvatski 408 hsb_DE 409 hsb_DE.iso88592 410 hsb_DE.utf8 411 ht_HT 412 ht_HT.utf8 413 hu_HU 414 hu_HU.iso88592 415 hu_HU.utf8 416 hungarian 417 hy_AM 418 hy_AM.armscii8 419 hy_AM.utf8 420 ia_FR 421 ia_FR.utf8 422 icelandic 423 id_ID 424 id_ID.iso88591 425 id_ID.utf8 426 ig_NG 427 ig_NG.utf8 428 ik_CA 429 ik_CA.utf8 430 is_IS 431 is_IS.iso88591 432 is_IS.utf8 433 italian 434 it_CH 435 it_CH.iso88591 436 it_CH.utf8 437 it_IT 438 it_IT@euro 439 it_IT.iso88591 440 it_IT.iso885915@euro 441 it_IT.utf8 442 iu_CA 443 iu_CA.utf8 444 iw_IL 445 iw_IL.iso88598 446 iw_IL.utf8 447 ja_JP 448 ja_JP.eucjp 449 ja_JP.ujis 450 ja_JP.utf8 451 japanese 452 japanese.euc 453 ka_GE 454 ka_GE.georgianps 455 ka_GE.utf8 456 kk_KZ 457 kk_KZ.pt154 458 kk_KZ.utf8 459 kl_GL 460 kl_GL.iso88591 461 kl_GL.utf8 462 km_KH 463 km_KH.utf8 464 kn_IN 465 kn_IN.utf8 466 kok_IN 467 kok_IN.utf8 468 ko_KR 469 ko_KR.euckr 470 ko_KR.utf8 471 korean 472 korean.euc 473 ks_IN 474 ks_IN@devanagari 475 ks_IN.utf8 476 ks_IN.utf8@devanagari 477 ku_TR 478 ku_TR.iso88599 479 ku_TR.utf8 480 kw_GB 481 kw_GB.iso88591 482 kw_GB.utf8 483 ky_KG 484 ky_KG.utf8 485 lb_LU 486 lb_LU.utf8 487 lg_UG 488 lg_UG.iso885910 489 lg_UG.utf8 490 li_BE 491 li_BE.utf8 492 lij_IT 493 lij_IT.utf8 494 li_NL 495 li_NL.utf8 496 lithuanian 497 lo_LA 498 lo_LA.utf8 499 lt_LT 500 lt_LT.iso885913 501 lt_LT.utf8 502 lv_LV 503 lv_LV.iso885913 504 lv_LV.utf8 505 mag_IN 506 mag_IN.utf8 507 mai_IN 508 mai_IN.utf8 509 mg_MG 510 mg_MG.iso885915 511 mg_MG.utf8 512 mhr_RU 513 mhr_RU.utf8 514 mi_NZ 515 mi_NZ.iso885913 516 mi_NZ.utf8 517 mk_MK 518 mk_MK.iso88595 519 mk_MK.utf8 520 ml_IN 521 ml_IN.utf8 522 mni_IN 523 mni_IN.utf8 524 mn_MN 525 mn_MN.utf8 526 mr_IN 527 mr_IN.utf8 528 ms_MY 529 ms_MY.iso88591 530 ms_MY.utf8 531 mt_MT 532 mt_MT.iso88593 533 mt_MT.utf8 534 my_MM 535 my_MM.utf8 536 nan_TW@latin 537 nan_TW.utf8@latin 538 nb_NO 539 nb_NO.iso88591 540 nb_NO.utf8 541 nds_DE 542 nds_DE.utf8 543 nds_NL 544 nds_NL.utf8 545 ne_NP 546 ne_NP.utf8 547 nhn_MX 548 nhn_MX.utf8 549 niu_NU 550 niu_NU.utf8 551 niu_NZ 552 niu_NZ.utf8 553 nl_AW 554 nl_AW.utf8 555 nl_BE 556 nl_BE@euro 557 nl_BE.iso88591 558 nl_BE.iso885915@euro 559 nl_BE.utf8 560 nl_NL 561 nl_NL@euro 562 nl_NL.iso88591 563 nl_NL.iso885915@euro 564 nl_NL.utf8 565 nn_NO 566 nn_NO.iso88591 567 nn_NO.utf8 568 no_NO 569 no_NO.ISO-8859-1 570 norwegian 571 nr_ZA 572 nr_ZA.utf8 573 nso_ZA 574 nso_ZA.utf8 575 nynorsk 576 oc_FR 577 oc_FR.iso88591 578 oc_FR.utf8 579 om_ET 580 om_ET.utf8 581 om_KE 582 om_KE.iso88591 583 om_KE.utf8 584 or_IN 585 or_IN.utf8 586 os_RU 587 os_RU.utf8 588 pa_IN 589 pa_IN.utf8 590 pap_AN 591 pap_AN.utf8 592 pa_PK 593 pa_PK.utf8 594 pl_PL 595 pl_PL.iso88592 596 pl_PL.utf8 597 polish 598 portuguese 599 POSIX 600 ps_AF 601 ps_AF.utf8 602 pt_BR 603 pt_BR.iso88591 604 pt_BR.utf8 605 pt_PT 606 pt_PT@euro 607 pt_PT.iso88591 608 pt_PT.iso885915@euro 609 pt_PT.utf8 610 romanian 611 ro_RO 612 ro_RO.iso88592 613 ro_RO.utf8 614 ru_RU 615 ru_RU.iso88595 616 ru_RU.koi8r 617 ru_RU.utf8 618 russian 619 ru_UA 620 ru_UA.koi8u 621 ru_UA.utf8 622 rw_RW 623 rw_RW.utf8 624 sa_IN 625 sa_IN.utf8 626 sat_IN 627 sat_IN.utf8 628 sc_IT 629 sc_IT.utf8 630 sd_IN 631 sd_IN@devanagari 632 sd_IN.utf8 633 sd_IN.utf8@devanagari 634 se_NO 635 se_NO.utf8 636 shs_CA 637 shs_CA.utf8 638 sid_ET 639 sid_ET.utf8 640 si_LK 641 si_LK.utf8 642 sk_SK 643 sk_SK.iso88592 644 sk_SK.utf8 645 slovak 646 slovene 647 slovenian 648 sl_SI 649 sl_SI.iso88592 650 sl_SI.utf8 651 so_DJ 652 so_DJ.iso88591 653 so_DJ.utf8 654 so_ET 655 so_ET.utf8 656 so_KE 657 so_KE.iso88591 658 so_KE.utf8 659 so_SO 660 so_SO.iso88591 661 so_SO.utf8 662 spanish 663 sq_AL 664 sq_AL.iso88591 665 sq_AL.utf8 666 sq_MK 667 sq_MK.utf8 668 sr_ME 669 sr_ME.utf8 670 sr_RS 671 sr_RS@latin 672 sr_RS.utf8 673 sr_RS.utf8@latin 674 ss_ZA 675 ss_ZA.utf8 676 st_ZA 677 st_ZA.iso88591 678 st_ZA.utf8 679 sv_FI 680 sv_FI@euro 681 sv_FI.iso88591 682 sv_FI.iso885915@euro 683 sv_FI.utf8 684 sv_SE 685 sv_SE.iso88591 686 sv_SE.iso885915 687 sv_SE.utf8 688 swedish 689 sw_KE 690 sw_KE.utf8 691 sw_TZ 692 sw_TZ.utf8 693 szl_PL 694 szl_PL.utf8 695 ta_IN 696 ta_IN.utf8 697 ta_LK 698 ta_LK.utf8 699 te_IN 700 te_IN.utf8 701 tg_TJ 702 tg_TJ.koi8t 703 tg_TJ.utf8 704 thai 705 th_TH 706 th_TH.tis620 707 th_TH.utf8 708 ti_ER 709 ti_ER.utf8 710 ti_ET 711 ti_ET.utf8 712 tig_ER 713 tig_ER.utf8 714 tk_TM 715 tk_TM.utf8 716 tl_PH 717 tl_PH.iso88591 718 tl_PH.utf8 719 tn_ZA 720 tn_ZA.utf8 721 tr_CY 722 tr_CY.iso88599 723 tr_CY.utf8 724 tr_TR 725 tr_TR.iso88599 726 tr_TR.utf8 727 ts_ZA 728 ts_ZA.utf8 729 tt_RU 730 tt_RU@iqtelif 731 tt_RU.utf8 732 tt_RU.utf8@iqtelif 733 turkish 734 ug_CN 735 ug_CN.utf8 736 uk_UA 737 uk_UA.koi8u 738 uk_UA.utf8 739 unm_US 740 unm_US.utf8 741 ur_IN 742 ur_IN.utf8 743 ur_PK 744 ur_PK.utf8 745 uz_UZ 746 uz_UZ@cyrillic 747 uz_UZ.iso88591 748 uz_UZ.utf8@cyrillic 749 ve_ZA 750 ve_ZA.utf8 751 vi_VN 752 vi_VN.utf8 753 wa_BE 754 wa_BE@euro 755 wa_BE.iso88591 756 wa_BE.iso885915@euro 757 wa_BE.utf8 758 wae_CH 759 wae_CH.utf8 760 wal_ET 761 wal_ET.utf8 762 wo_SN 763 wo_SN.utf8 764 xh_ZA 765 xh_ZA.iso88591 766 xh_ZA.utf8 767 yi_US 768 yi_US.cp1255 769 yi_US.utf8 770 yo_NG 771 yo_NG.utf8 772 yue_HK 773 yue_HK.utf8 774 zh_CN 775 zh_CN.gb18030 776 zh_CN.gb2312 777 zh_CN.gbk 778 zh_CN.utf8 779 zh_HK 780 zh_HK.big5hkscs 781 zh_HK.utf8 782 zh_SG 783 zh_SG.gb2312 784 zh_SG.gbk 785 zh_SG.utf8 786 zh_TW 787 zh_TW.big5 788 zh_TW.euctw 789 zh_TW.utf8 790 zu_ZA 791 zu_ZA.iso88591 792 zu_ZA.utf8
以上字符集都可以用来设置当前系统语言,设置方法如下:
1、临时修改 export LANG=zh_CN.UTF-8 // 中文 export LANG=en_US.UTF-8 // 英文 // 此方法可以在此终端中生效,而且是即时生效。 2、永久修改 [root@localhost http]# cat /etc/locale.conf LANG="en_US.UTF-8" // 将/etc/locale.conf文件的LANG值进行修改,如修改为LANG="zh_CN.UTF-8" [root@localhost http]# source /etc/locale.conf // 使其生效