上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 15 下一页
摘要: 背景:ldap数据库要同步,按照如下操作步骤:1.导出:使用slapcat,slapcat直接对数据库操作,slapcat2.将所需的条目取出,生成文件in.ldif3.在目标机器上导入:ldapadd -D 'cn=admin,dc=xxxx,dc=xxx' -x -f in.ldif -W但是爆出如下问题:additional info: structuralObjectClass: no user modification allowedldap_add: Constraint violation (19)参考下面的链接,http://serverfault.com/qu 阅读全文
posted @ 2014-02-24 17:26 silence.li 阅读(713) 评论(0) 推荐(0)
摘要: ctrl+shift 鼠标变成正十字。按住右键就可以随意截图了。设置方法:打开系统设置面板system settings --> keyboard --> shortcuts --> screenshots --> take a screen of an area 阅读全文
posted @ 2014-02-21 11:35 silence.li 阅读(528) 评论(0) 推荐(0)
摘要: 1.nginx作为反向代理,如果代理请求的页面不存在,返回404,但是浏览器中一片空白。要求:将404跳转到指定页面。在server段添加:error_page 404 /;不能生效,原因是需要添加一条proxy_intercept_errors on;语句。同理对于动态页面的404响应,需要添加fastcgi_intercept_errors on;语句。2.error_page语法error_page code ... [ = [ response ]] uri例如以下:error_page 404 /404.html;error_page 502 503 504... 阅读全文
posted @ 2014-02-21 10:04 silence.li 阅读(2238) 评论(0) 推荐(0)
摘要: While passing request nginx replaces URI part which corresponds to location with one indicated in proxy_pass directive. But there are two exceptions from this rule when it is not possible to determine what to replace:if the location is given by regular expression;if inside proxied location URI is ch 阅读全文
posted @ 2014-02-20 17:35 silence.li 阅读(3459) 评论(0) 推荐(0)
摘要: c俺靠这篇博文http://eyesmore.iteye.com/blog/1142162有用的配置:1.开启rewrite_log,这样在/var/log/nginx/error.log中显示匹配的规则,便于debug,理解rewrite的过程。 rewrite_log on; access_log /var/log/nginx/access.log; error_log /var/log/nginx/error.log info;总结:Break和last都能阻止继续执行后面的rewrite指令,但是last如果在location下用的话,对于重写... 阅读全文
posted @ 2014-02-19 17:51 silence.li 阅读(566) 评论(1) 推荐(0)
摘要: solr是什么?翻译:SolrTMis the popular, blazing fast open source enterprise search platform from the Apache LuceneTMproject. Its major features include powerful full-text search, hit highlighting, faceted search, near real-time indexing, dynamic clustering, database integration, rich document (e.g., Word, 阅读全文
posted @ 2014-02-19 11:38 silence.li 阅读(415) 评论(0) 推荐(0)
摘要: 介绍地址:http://www.tummy.com/blogs/2005/07/17/some-iptables-modules-you-probably-dont-know-about/[1] -- nth 阅读全文
posted @ 2014-02-18 11:14 silence.li 阅读(305) 评论(0) 推荐(0)
摘要: #!/usr/bin/python #-*- coding: utf-8 -*-import osimport rerawfile = '/var/log/auth.log'def rawparse(rawfile): ipdict = {} fhandle = open(rawfile,'r') regexp = re.compile('\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}') for line in fhandle: result = regexp.findall(line) if result and i.. 阅读全文
posted @ 2014-02-14 14:05 silence.li 阅读(449) 评论(1) 推荐(0)
摘要: app ALL = (ALL:ALL) ALLeric.zhan ALL = (app : app) ALLDefaults:eric.zhan runas_default=app如果在/etc/sudoers中添加这么一段,原本的想法是将eric.zhan可以提权到app用户,但存在隐患eric.zhan$ sudo bashpasswd --------app$ sudo bashpasswd --------root#note1:如果想在sudo的时候不输入密码,这么设定eric.zhan ALL = (app:app) NOPASSWD: ALL如果想只给使用部分命令的权限,且不... 阅读全文
posted @ 2014-02-14 11:04 silence.li 阅读(331) 评论(0) 推荐(0)
摘要: nginx debug模式1.编译安装的话,需要添加编译参数--with-debug;大部分预编译软件包都已经包含了改参数。2.格式:error_log LOGFILE [debug | info | notice | warn | error | crit |debug_core | debug_alloc | debug_mutex | debug_event | debug_http |debug_imap];其中分为六个等级--debug--info--notice--warn--error--crit--自左至右日志信息输出越来越少,级别越来越高debug-core -- 当ngin 阅读全文
posted @ 2014-02-12 22:48 silence.li 阅读(384) 评论(0) 推荐(0)
上一页 1 ··· 3 4 5 6 7 8 9 10 11 ··· 15 下一页