设定开机启动脚本的新方法

@ref: http://askubuntu.com/questions/814/how-to-run-scripts-on-start-up One approach is to add an @reboot cron task: Running crontab -e will allow you to edit your cron. Adding a line like this to it: @reboot /path/to/script will execute that script once your computer boots up. Run on actual reboot, rather than cron restart static void run_reboot_jobs(db) cron_db *db; { register user *u; register entry *e; int rbfd; #ifdef DEBIAN #define REBOOT_FILE "/var/run/crond.reboot" /* Run on actual reboot, rather than cron restart */ if (access(REBOOT_FILE, F_OK) == 0) { /* File exists, return */ log_it("CRON", getpid(),"INFO", "Skipping @reboot jobs -- not system startup"); return; }

2016-03-16 · wuan

SaltStack

2015-12-13 · wuan

坐请坐请上坐

2015-08-21 · wuan

春夏秋冬又一春

@端传媒: 刺耳的声音不见了?中国调查报道的冬天 报禁未开,报纸已死。 – 吴婧 发轫 「打死老虎有两种读法:打──死老虎,打死──老虎。」2015年夏天,北京一家川菜馆,王克勤将右拳攮在左手掌上,面前那盆毛血旺的水平面陡地上斜。 六十年代生人王克勤是中国著名揭黑记者,1989年入行,从业二十...

2015-08-20 · wuan

msmtp and gmail and smtp and proxy

我日他个佬佬,Gmail 你也封啊,好不了了哦。 在网页上,咱有科学上网,自然不会有问题。 问题在用客户端时,只能收(pop3)不能发(smtp)。 最先怀疑是 msmtp 的配置问题,以为 Gmail 变更了参数。 期间发现是 smtp.gmail.com 的 IP 被枪了,用 telnet 测试。 未被枪 % telnet smtp.gmail.com 587 Trying 74.125.204.108... Connected to gmail-smtp-msa.l.google.com. Escape character is '^]'. 220 smtp.gmail.com ESMTP vx1sm6944922pac.43 - gsmtp quit 221 2.0.0 closing connection vx1sm6944922pac.43 - gsmtp Connection...

2015-08-07 · wuan