- WINDOWS下命令行执行报错,可以输入以下2条命令解决
chcp 65001 set PYTHONIOENCODING=utf-8
- 写日志时报错,说明变量有些字符是utf8,可以用下面方法解决
logging.error(“some log:” + unicode(input, ‘utf-8’))
chcp 65001 set PYTHONIOENCODING=utf-8
logging.error(“some log:” + unicode(input, ‘utf-8’))
参考:
https://letsencrypt.org/zh-cn/getting-started/
https://www.cnblogs.com/stulzq/p/8628163.html
yum -y install yum-utils
yum-config-manager --enable rhui-REGION-rhel-server-extras rhui-REGION-rhel-server-optional
yum install certbot python2-certbot-apache
certbot certonly -d 你的域名 -d *.你的域名 --manual --preferred-challenges dns
(more…)
从证书服务商得来的压缩包里,只有一个公钥crt和一个证书链文件,缺少私钥key文件,百思不得其解,最后只能自己手动在服务器上生成一个csr和key文件,重新向证书服务商请求Rekey,用新得来的crt文件配置上apache了:
[code language=”bash”]
openssl req -new -newkey rsa:2048 -nodes -keyout yourdomain.key -out yourdomain.csr
[/code]
一、参考IBM方式,重载new方法,见:https://www.ibm.com/developerworks/cn/linux/l-shared/index.html
二、类似IBM,自定义new方法的alloc参数,自定义内存分配,
译文参见:http://www.cppblog.com/doing5552/archive/2010/07/24/121197.aspx
原文:http://www.ddj.com/cpp/184401639
三、高大上用BOOST
参见:http://lday.me/2017/12/17/0019_boost_share_memory_ipc/
Powered by WordPress