可以用iconv命令来转换文件的编码,格式:iconv -f 原本的编码格式 -t 要转换成的编码 文件名 -o 新文件名例如:iconv -f gb2312 -t utf8 mytext.txt -o utf8.txt