Don't wanna be here? Send us removal request.
Text
nginx隐藏版本号
1 z在配置zhong在配置中在xiug修改 root@mail ~]# vi /usr/local/nginx0.8/conf/nginx.conf worker_processes 1; events { worker_connections 1024; } http { include mime.types; default_type application/octet-stream; server_tokens off; expires 5s; sendfile on; keepalive_timeout 65; include "sites-enabled/mail*"; } [root@mail ~]#service nginx reload 2代码中修改 root@mail nginx-0.8.53]# vi src/core/nginx.h #define nginx_version 8053 #define NGINX_VERSION "10.0" #define NGINX_VER "jh/" NGINX_VERSION #define NGINX_VAR "NGINX" #define NGX_OLDPID_EXT ".oldbin" #endif /* _NGINX_H_INCLUDED_ */ https://www.cnblogs.com/tl542475736/p/5504074.html
0 notes
Text
in_addr_t转换成字符串
原文:https://blog.csdn.net/hanghang121/article/details/50290357 https://stackoverflow.com/questions/23212084/assigning-ip-address-in-ip-header-in-c in_addr_t IP_i; printf("IPstr:%s\n",inet_ntoa(*((struct in_addr*)&IP_i)));
0 notes
Text
Linux 下git 保存用户名密码
Linux/Unix/Mac 系统 新建一个 ~/.netrc 文件, 将 git 服务器, 用户名以及密码记录在这个文件, 如下所示: machine your-git-server login your-username password your-password 普通用户的 git-server 填 github.com 就可以了. 如果有多个 server 就重复上面的三行, 分别输入对应的服务器、 用户名和密码即可. link: http://blog.csdn.net/xzz_hust/article/details/23602007
0 notes
Text
CXXABI_1.3.8' not found和`GLIBCXX_3.4.20' not found,解决方
https://www.centos.net.cn/archive/4897 http://blog.csdn.net/yyongchao/article/details/72896907
0 notes
Text
proxychains在终端使用socks5代理
windows下有SocksCap64做为socks5客户端代理 现在平时用linux比较多,平时访问谷歌就得找个代理软件了。介绍一下 linux平台下客户端代理 proxychains安装: 1 下载代码 git clone https://github.com/rofl0r/proxychains-ng.git 2 进入代码目录编译 cd proxychains-ng ./configure make && make install 3 拷贝配置文件到/etc/ cp ./src/proxychains.conf /etc/proxychains.conf 以下是我的配置文件/etc/proxychains.conf [root@192 etc]# grep -v "#" /etc/proxychains.conf strict_chain proxy_dns remote_dns_subnet 224 tcp_read_time_out 15000 tcp_connect_time_out 8000 [ProxyList]# 这里是主要的,以下列表对应的 socks5 47.11.22.33 80 test abc123 协议 代理服务器ip 端口 用户 密码 5配置完成后可以用 curl 测试一下 proxychains4 curl -I https://www.google.com 转自:https://blog.fazero.me/2015/08/31/%E5%88%A9%E7%94%A8proxychains%E5%9C%A8%E7%BB%88%E7%AB%AF%E4%BD%BF%E7%94%A8socks5%E4%BB%A3%E7%90%86/
0 notes
Quote
linux 中两个文档怎么对比内容是否一致
https://zhidao.baidu.com/question/536986778.html
0 notes
Text
mov和movl 的区别
汇编语言(Assembly Language)中 mov和movl 有什么区别(举例说明) In a word, they belong to two instruction set, movl is at%t and mov is intel 参考正确回答: AT&T汇编语言(Assembly Language)是UNIX下惯用的汇编语言(Assembly Language)各式 l,w,b是ATT汇编语言(Assembly Language)中用来表达操作属性的限定符 l是长字(4字节), w是双字 b是唯一字节 加在命令的后边 相当于intel中的 dword ptr word ptr byte ptr 比如: subl $8, %esp leal -792(%ebp), %eax pushl %eax movl -796(%ebp), %eax sall $8, %eax addl 12(%ebp), %eax pushl %eax call _strcpy addl $16, %esp 在intel 汇编语言(Assembly Language)中就相当于: sub esp,8 lea eax,dword ptr [ebp-792] push eax mov eax,dword ptr [ebp- 796] ... ATT各式的汇编语言(Assembly Language)和intel编的差别没去外国疑问参看有关AT&T汇编语言(Assembly Language)的书 l根本是32位的意思。 来源 http://blog.csdn.net/zhangxinrun/article/details/5807590
0 notes
Quote
Jenkins+Maven+SVN+Nexus 搭建持续集成环境
https://www.abcdocker.com/abcdocker/2897
0 notes
Text
Jenkins主目录修改
Jenkins默认会存放在用户主目录下的.jenkins文件夹中 如:Linux root用户:/root/.jenkins 注意:这是linux版本的。windows系统请自行更改。这个值在Jenkins运行时是不能更改的. 请先将Jenkins停止运行。 如果查看当前Jenkins目录:系统管理→系统设置→主目录→/root/.jenkins(注意:用户不同,路径也不同) Jenkins储存所有的数据文件在这个目录下. 你可以通过以下几种方式更改: 使用你Web容器的管理工具设置JENKINS_HOME环境参数. 打开tomcat的bin目录,编辑catalina.sh文件。 在# OS specific support. $var _must_ be set to either true or false.上面添加:export JENKINS_HOME="" 在引号中填入你的路径。 在启动Web容器之前设置JENKINS_HOME环境变量. 用root用户登录 编辑profile文件:vi /etc/profile 在最后加入:export JENKINS_HOME=xxxx 保存,退出后执行:source /etc/profile 让配置生效 (不推荐)更改Jenkins.war(或者在展开的Web容器)内的web.xml配置文件. 复制代码 HUDSON_HOME java.lang.String 复制代码 好了,现在运行Jenkins看看效果吧。 来源 :https://www.cnblogs.com/zz0412/p/jenkins_jj_07.html
0 notes
Text
mysql中delete的语法别名问题
首先确认,mysql中的delete语句是支持别名的;
在自己书写delete语法时候,语句如下:
delete from tableA a where a.c_pk_id = '123'
但是会报一个别名使用错误,如下:
通过查询资料得知,mysql的delete的语法有些特殊,如下:
[Err] 1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'q WHERE q.C_PLY_NO = '1100107000404000220150000001' AND q.N_EDR_PRJ_NO = '1'' at line 3
delete a from tableA a where a.c_pk_id = '123'
成功删除!!!比较之后可知道,delete语句在用别名的时候要多写一个别名在delete后边
来源:http://blog.csdn.net/qq_16736531/article/details/51136424
0 notes
Text
Python中'__main__'模块的作用
Python不同于C/C++,程序执行并不需要主程序,如main(),而是文件自上而下的执行。
但很多Python程序中都有
if __name__ == '__main__':
statements
这样的语句。这段代码的主要作用主要是让该python文件既可以独立运行,也可以当做模块导入到其他文件。当导入到其他的脚本文件的时候,此时__name__的名字其实是导入模块的名字,不是'__main__', main代码里面的就不执行了。
比如写一个程序test_main.py:
def fun():
print 'This is function'
if __name__ == '__main__':
fun()
print 'This is main'
F5执行这个程序,得到结果:
此结果为test_main.py顺序执行的结果,然后将test_main作为模块引入
得到结果:
可以发现,'__main__'模块中的代码并未执行。
原文:http://blog.csdn.net/rena521/article/details/46895539
0 notes
Text
iptables如何过滤同一网段的连续几个IP
来源:https://zhidao.baidu.com/question/391202121293379765.html
过滤源地址范围: iptables -A INPUT -m iprange --src-range 192.168.1.2-192.168.1.7 -j DROP 过滤目标地址范围: iptables -A INPUT -m iprange --dst-range 192.168.1.2-192.168.1.7 -j DROP
0 notes
Text
ELF文件分析
ELF文件各项详细说明:http://blog.csdn.net/cavalier_anyue/article/details/45009297
相关文档:http://staff.ustc.edu.cn/~sycheng/ssat/exp_crack/ELF.pdf
0 notes
Quote
nagios mysql slave
http://blog.csdn.net/reblue520/article/details/52045999
#!/bin/sh declare -a slave_is slave_is=($(/usr/local/mysql/bin/mysql -S /mnt/box/mysql5.7/mysql.sock -h 127.0.0.1 -unagios -pnagios -e "show slave status\G"|grep Running |awk '{print $2}')) if [ "${slave_is[0]}" = "Yes" -a "${slave_is[1]}" = "Yes" ] then echo "OK -slave is running" exit 0 else echo "Critical -slave is error" exit 2 fi
0 notes
Text
Kafka使用遇到的问题
1 kafka/Kafka : Unsupported major.minor version 52.0
问题原因需要 jdk1.8版本以上
JAVA_HOME=/usr/local/jdk1.8.0_131/ CLASSPATH=.:$JAVA_HOME/lib/dt.jar:$JAVA_HOME/lib/tools.jar export JAVA_HOME export PATH export CLASSPATH
kafka 安装 http://blog.51cto.com/xiangcun168/1933375 elk + kafka http://blog.csdn.net/workdsz/article/details/77851857
logstash 根据type 判断输出
http://blog.csdn.net/zhaoyangjian724/article/details/52275803
1、创建topic $bin/kafka-topics.sh --create --zookeeper localhost:2181 --replication-factor 1 --partitions 1 --topic nginxaccess
2、查看创建的topic $ bin/kafka-topics.sh -list -zookeeper localhost:2181 test
3、生产消息测试 $bin/kafka-console-producer.sh --broker-list 192.168.12.105:9092 --topic test this is test #输入后回车
4、消费消息测试 $bin/kafka-console-consumer.sh --zookeeper localhost:2181 --topic nginxaccess --from-beginning this is test
topic删除 kafka-topics.sh --delete --zookeeper localhost:2181 --topic nginxaccess
0 notes
Text
DRBD踩的坑
1 drbd not defined in your config (for this host)on drbd1 要和主机名相同resource r0{ device /dev/drbd0; disk /dev/sdb1; meta-disk internal; on drbd1 { address 192.168.2.55:7789; } on drbd2 { address 192.168.2.177:7789; } }
2 Command 'drbdmeta 0 v08 /dev/sdb1 internal create-md' terminated with exit code 40 drbdadm create-md share: exited with code 40 解决办法: root@hadoop2-virtual-machine:/home/hadoop# dd if=/dev/zero bs=1M count=1 of=/dev/sdb1
3 Command 'drbdsetup-84 primary 0' terminated with exit code 17
解决办法:
chmod 777 /dev/console
systemctl start drbd
drbdadm up r0
drbdadm primary --force r0
0 notes
Text
无线WIFI--2什么是Aircrack-ng
1 aircrack-ng 要用于WEP 及WPA-PSK 密码的恢复,只要Airodump-ng 收集到足够数量的数据包,Aircrack-ng 就可以自动检测数据包并判断是否可以破解
2 airmon-ng 用于改变无线网卡的工作模式,以便其他工具的顺利使用 3 airodump-ng 用于捕获802.11数据报文,以便于Aircrack-ng 破解
4 aireplay-ng 在进行WEP 及WPA-PSK 密码恢复时,可以根据需要创建特殊的无线网络数据报文及流量
5 airserv-ng 可以将无线网卡连接至某一特定端,为攻击时灵活调用做准备
6 ariolib-ng 进行WPARainbowTable 攻击时使用,用于建立特定数据库文件 7 airdecap-ng 用于解开处于加密状态的数据包
tools 其他用于辅助的工具,如airdriver-ng.packetforge-ng 等
0 notes