cobbler的ks文件带有特殊字符导致错误

时间:2024-09-06 16:04:02

aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAAykAAACWAQMAAADg0FUUAAAAAXNSR0IArs4c6QAAAAZQTFRFq6urAAAASyFoYQAABz5JREFUaN7tmrFu47gWhhcmoNNFQNxvgFtEvdXdwuriYjr7Haxe7O4FpFuNOgtIygXEhwmw7sRHSGf2Vi/ecyhaVmwziWesWexCxsA8Ijn8LIrkz5/Kb/pXfP7324gZMSNmxIyYETNiRsyvwORaNxOmoYBqwnK9pew3LbV8MzXyAmROAcPcwmQ1gF9SU9WGb036ZtujEmqByfbapogRWDnhDZ/zTcqVVpQtCCNMDTHnhWoxlGs+YYtRhHkxacvHS20uL2N0XTdJyu+yusMcvnSZcl/J5r/6m8VgGLZtKAyDP0y7wQnmm727b/ocUxHm+8L31qA3iw3cx14MiJGI4Vp64Mu2qRAANhxyDEF4i5y6w1v4U9DzBQB1sdwE1H+H1GKU0hNgFWAaTHdJjL87lOV6nax5CSAV/cSKC2W6QGkvSXiV8ADD4o5PA8QkfLpbc13MKBubryZcH1OLkVLveS1rqZo49NK4ZC1msmZlwgkjCQMGI/XjJGVVMokxLEo2i3EMJSz01kyr2QSzqfkl08fUYoRoMQIx83Xa3U26zixGIKaMZfvMZmmaVUkaYwhlNo/pbrL5ep3pGossJtPH9IsYqaMjJjpiIh28wzT8E4zccUW9T5gkfiHMc/tsEjsEKv4c2yEww0chH5O4wXlQcsLwR44YvMQii7HPZsm76UkYH3wGItf3D1OYbnUe5lvACHIAnLRNrXPYTqluUzc00nDaTjHkvvcwRUyBCYDGApjSpP7OzUiz6YeLjbpySVGmR69e067ENPGPYV6vvBsfUQ+j3twU067WRlQ64RgM067uYjiMEQXUjoExRhSadP208J5gQAyJQpPG03seDnk3JAqICWdsYExGmGieDY/5zy/AoCjMEMPDl+EwrSjk978/QLgd17QR84/wNx4rPAYuf9P4BRkX3KMV1sBYtwNWo3ATsH07+ptzjPU3CX/ETZ7T3wT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o4syjg4Yk7XJIsQUh5GWtpgyU05/M2kx8iOMOsXsDEb1BnRFGK6cfy/wrx7mXbl+qZYJ5WAzz3H0QhibRQ5Qhs/cTs+G4RQEECV7dfqb4P4hzEMcNKflevudA+XgLN/eP2yp0iELvIcctnC18VBfMSbq/OTrOkwTfwFzUulzzLni+l/xP/75AduoNz+lNzu2m7BiaL3Rf2Z/JjwYWm/09yyv3e9vbqU3+jELavf7mxvpDWvWXqx2q2H1ZlU3bM9ktRpWb3itVa2E+/3NbfTmM8yN9CZQ9PdpQgQD640vX+FViGLUm1Fv/gl6Iwtd0AucgfWmCHTwmCRZNKje1HetjUqzQfVGVUfMgHqDCtAsVzDxYFC9EYRZ8g/f39xAbyLTafyj9ze30JvsM8yN9EYGMnjkuPMYVm9YIXF6+gCj3ox68/fG/B8JRunC9SgvmQAAAABJRU5ErkJggg==" alt="" />

cat  /var/lib/cobbler/kickstarts/CentOS-7-x86_64.cfg 中带又特殊字符

前面省略。。。。。。
%post
echo "a=$(date +%F_%T)'&'b=$(cat /tmp/a.txt)" # 就是带有这些格式的字符导致
%end

解决方法就是把这些字符去掉就可以了。