您的位置:首页 > 其它

Pencil OJ 02 安装

2015-07-24 11:49 183 查看

Mongo

官方的安装方法

官方教程已经很好啦,这里就不罗嗦了。

源码编译

待补。我是从这里看到的。

遇到的问题

启动时的警告信息

2015-03-06T21:01:15.526-0800 I CONTROL  [initandlisten] ** WARNING: /sys/kernel/mm/transparent_hugepage/defrag is 'always'.
2015-03-06T21:01:15.526-0800 I CONTROL  [initandlisten] **        We suggest setting it to 'never'

解决方法:

stackoverflow上的回答


Official MongoDB documentation gives several solutions for this issue. You can also try this solution, which worked for me:

Open
/etc/init/mongod.conf
file.

Add the lines below immediately after
chown $DEAMONUSER /var/run/mongodb.pid
and before
end script
.

Restart mongod (service mongod restart).

Here are the lines to add to
/etc/init/mongod.conf
:

if test -f /sys/kernel/mm/transparent_hugepage/enabled; then


echo never > /sys/kernel/mm/transparent_hugepage/enabled


fi


if test -f /sys/kernel/mm/transparent_hugepage/defrag; then


echo never > /sys/kernel/mm/transparent_hugepage/defrag


fi


That's it!

shareimprove this answer

edited Apr 2 at 7:56

answered Mar 21 at 10:59


可惜我英语太渣,居然没有理解这句话(看漏了个单词before,然后就加在
end script
后面了):Add the lines below immediately after
chown $DEAMONUSER /var/run/mongodb.pid
and before
end script
.

service mongod stop 不起作用

返回信息:

stop: Unknown instance

解决方法:

删除
/var/lib/mongodb/mongod.lock
,然后重启。

Atom

不能显示中文?

http://atom-china.org/t/linux/85

步骤

打开 style.less 文件 ( 唤出 Command Palette 找到 Open Your Stylesheet )。

粘贴下面代码并保存。(其中 "ubuntu mono" 、"ubuntu" 替换为你希望的西文字体名)。

/* 等宽字体 */
@mono-font-family: "ubuntu mono", "Hiragino Sans GB", "Microsoft YaHei","WenQuanYi Micro Hei", sans-serif;
/* 非等宽字体 */
@font-family: "ubuntu", "Hiragino Sans GB", "Microsoft YaHei","WenQuanYi Micro Hei", sans-serif;
html,
body,
ol,
ul,
li,
h1,
h2,
h3,
h4,
h5,
h6,
div,
p,
span,
pre,
section,
input,
textarea,
.atom-panel,
.status-bar,
.tree-view,
.title,
.current-path,
.tooltip {
font-family: @font-family;
}
.autocomplete-plus span,
code,
.-tree-view-,
.symbols-view,
.editor {
font-family: @mono-font-family;
}
.editor {
font-size: 14px;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: