2015年2月13日

由某云服务示例代码想到的...

摘要: 去年自己购买了云实例。 最近注意到服务商提供了“自定义云监控服务”,允许用户自定义对服务器的监控并提供图表展示和告警,服务商也提供了示例代码。 服务商提供了python 和 shell 版本的示例代码, 下载查看, 令我想起了先前的博客“我们还在像猴子一样对待脚本?”。 粗略扫过,其代码存在... 阅读全文

posted @ 2015-02-13 12:26 Lifen, Song 阅读(189) 评论(0) 推荐(0) 编辑

2014年11月13日

Programmer's Jokes

摘要: 1. 一天, 下着小雨, 和同事们一起去上班,一位同事差点滑倒,另一位同事笑话说:如果人走路用爬的就不会摔倒了! 遂反问他:能用两行代码搞定的事情为什么要用4行呢?2. 有趣的公式( From here )Software Produced = Number of Workers x Hours... 阅读全文

posted @ 2014-11-13 00:23 Lifen, Song 阅读(222) 评论(0) 推荐(0) 编辑

2014年11月1日

Lazy Makes Others Busy – a bad experience with DLL

摘要: A real story of windows DLL which does too much and without good version control 阅读全文

posted @ 2014-11-01 22:17 Lifen, Song 阅读(307) 评论(0) 推荐(0) 编辑

2014年7月2日

Developers, do consider different user roles! - A bad experience with cron

摘要: The Story:Last week, I found one of our embedded arm linux device ran out of flash space( totally only 128M for apps and OS).After checking for a whil... 阅读全文

posted @ 2014-07-02 00:36 Lifen, Song 阅读(704) 评论(0) 推荐(0) 编辑

2014年5月19日

运维人愿意听到的话 vs 不愿意听到的话

摘要: 运维人愿意听到的话 vs 不愿意听到的话 阅读全文

posted @ 2014-05-19 21:56 Lifen, Song 阅读(213) 评论(0) 推荐(0) 编辑

2013年12月3日

我们还在像猴子一样对待脚本? ^_^

摘要: 许多人(包括笔者)对待脚本的行为往往是: ”它简单, 轻量级,写了丢、丢了再写呗!“ Faint! 难道我们就是小时候故事中的哪只猴子? ^_^ 做了挺长时间的猴子, 一些经验教训总结分享: - 脚本开头注意写好其解释器,建议使用/usr/bin/env 获取 - 不假设命令已经在PATH里,脚本开头最好把需要的PATH路径确保或用绝对路径 - 别假设用户一定是在当前目录运行你的脚本 - 如果脚本有良好定义的返回值, 判断并提示用户, 会避免不少问题和疑惑 - 脚本可执行权限建议安装时保证,如果不放心,可以使用sh script.sh避归执行失败- 脚本代码的可读性也挺重要的- 经过设计... 阅读全文

posted @ 2013-12-03 21:49 Lifen, Song 阅读(225) 评论(0) 推荐(0) 编辑

2013年4月4日

致《程序员度量: 改善软件团队的分析学》的读者

摘要: Hi, 如本书译者序中所写,刚接触这本书,甚至在翻译过程中我们一直在担心读者(尤其是管理人员)会把这本书拿来当做度量程序员的工具书,成为程序员的梦魇! 我个人非常不认同只会拿各种度量标准来“管”研发人员而忽视“教导”和“理”的管理方式! 作为译者之一,我被作者能够如此全面的观察软件团队成员和整个团队所折服;作为一个软件研发管理人员,这本书扩充了我观察团队的视角;作为一个仍在写代码的程序员,我了解到作为团队成员,我们的团队可以从哪些方面去改善,这中间我自己可以做些什么。 愿您也有所收获!谢谢!- 宋励奋, 2013.04.04 阅读全文

posted @ 2013-04-04 14:35 Lifen, Song 阅读(444) 评论(0) 推荐(0) 编辑

2012年6月30日

[CopyPaste] We DON'T copy-paste as a professional programmer

摘要: Yesterday I used almost half day to debug a strange problem: When we set a specific timeout for watchdog timeout via a uart port in our application, the checking of the ack from the other end will not pass.But our HW engineer has a tiny tool which can do that too will be OK.Later I found the decodin 阅读全文

posted @ 2012-06-30 01:54 Lifen, Song 阅读(279) 评论(0) 推荐(0) 编辑

2012年6月26日

[Linux]Enable core dump in linux

摘要: http://stackoverflow.com/questions/2919378/how-to-enable-core-dump-in-my-linux-c-programhttp://www.akadia.com/services/ora_enable_core.html0. Make sur... 阅读全文

posted @ 2012-06-26 08:40 Lifen, Song 阅读(472) 评论(0) 推荐(0) 编辑

2012年5月7日

[C/C++] Anonymous field in struct

摘要: I have below code and try to bring under unit test with CppUtest in Linux. 1 typedef union { 2 unsigned char Byte; 3 struct { 4 byte :1; 5 byte :1; 6 byte :1; 7 byte :1; 8 } Bits; 9 10 } foo;And got compile error: "error: type... 阅读全文

posted @ 2012-05-07 11:45 Lifen, Song 阅读(560) 评论(0) 推荐(0) 编辑

导航