Fix bash Shell foot This newspaper error ': not a valid identifier

Source: Internet
Author: User
Tags i18n ultraedit

Reprinted from Matchless Castle | Demon Angel

When the shell edits the script, the runtime appears "': not a valid identifier", or it will appear (: Command not found, many inexplicable symbols) it is likely that you are editing under Windows, running under Linux, Due to different text formats for Linux and Windows.

The above may be one of the reactions, and sometimes the terminal displays ": No files ..." and that's why most of it starts with a semicolon ":"

Solution: As long as the UltraEdit tool to convert to Linux format, the source run without errors can be

The difference between Linux and Windows text:

1.Linux line Wrap: "N"
2.windows line break: "RN" (carriage return, linefeed)

For example today in Rhel use Tomcat has been in garbled, view i18n, found has been modified to support the GBK, should be no problem, but, has been garbled. Suddenly think of SSH login prompt ': not a valid identifier. Again with locale looked, output lang unexpectedly empty, is depressed want a script turn over to look. source/etc/sysconfig/i18n hint ': not a valid identifier. After the download with UltraEdit converted into UNIX file format, upload, execute source, restart Tomcat, garbled elimination.

Attached: i18n Chinese support content, the province is looking everywhere, solves the Chinese garbled

#以下注释为原文件内容,   in English
#LANG = en_US. UTF-8 " 
#SYSFONT =" Latarcyrheb-sun16 " 
#以下为中文支持内容  
lang=" ZH_CN.GBK " 
language=" Zh_CN.GBK:zh_CN.GB2312:zh_CN " 
supported=" ZH_CN. GBK:zh_CN:zh:en_US. Utf-8:en_us:en " 
sysfont=" Latarcyrheb-sun16 " 
lc_all=" ZH_CN.GBK " 
Export Lc_all

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.