会员
众包
新闻
博问
闪存
赞助商
HarmonyOS
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
王清河
博客园
首页
新随笔
联系
订阅
管理
上一页
1
···
13
14
15
16
17
18
19
20
21
···
90
下一页
2020年3月30日
ping github请求超时解决方案
摘要: 打开网址 https://www.ipaddress.com/ 输入 github.com 或者 github.global.ssl.fastly.net 将得到的ip地址放入到host文件中 用管理员权限(Win10)打开 C:\Windows\System32\drivers\etc 目录下的
阅读全文
posted @ 2020-03-30 09:19 王清河
阅读(3641)
评论(1)
推荐(0)
2020年2月21日
将时间戳化成int型
摘要: 今天遇到了一个紧急问题,需要把时间戳转成一个int型,就有了这个小demo #include<cstdio> #include<ctime> #include<cstdlib> int main() { time_t t; time(&t); t = t + 8 * 3600; tm *tt = g
阅读全文
posted @ 2020-02-21 14:48 王清河
阅读(4137)
评论(0)
推荐(0)
VS系列报C4996的错误
摘要: VS编译器报 C4996的问题 1.在文件开头加定义 1)在文件的最开头加一个 #pragma warning(disable:4996) 2) 或者加一个宏定义 #define _CRT_SECURE_NO_WARNINGS 2. 取消掉安全开发生命周期(SDL)检查 1)建项目的时候勾选取消 2
阅读全文
posted @ 2020-02-21 09:56 王清河
阅读(399)
评论(0)
推荐(0)
2020年2月10日
shell编程题(五十一)
摘要: 题目: 显示当前系统上所有用户的shell,要求,每种shell只显示一次; 答案: cut -d: -f7 /etc/passwd | sort -u
阅读全文
posted @ 2020-02-10 10:17 王清河
阅读(149)
评论(0)
推荐(0)
shell编程题(五十)
摘要: 题目: 统计/bin、/usr/bin、/sbin和/usr/sbin等各目录中的文件个数; 答案: ls /bin | wc -l
阅读全文
posted @ 2020-02-10 10:15 王清河
阅读(139)
评论(0)
推荐(0)
shell编程题(四十四)
摘要: 题目: 创建一个用户mandriva,其ID号为2002,基本组为distro(组ID为3003),附加组为linux; 答案: #! /bin/bash groupadd linux groupadd -g 3003 distro useradd -u 2002 -g distro -G linu
阅读全文
posted @ 2020-02-10 10:12 王清河
阅读(171)
评论(0)
推荐(0)
2020年2月9日
shell编程题(四十三)
摘要: 题目: 查看哪些蜘蛛在抓取内容 答案: /usr/sbin/tcpdump -i eth0 -l -s 0 -w - dst port 80 | strings | grep -i user-agent | grep -i -E 'bot|crawler|slurp|spider' 这题没看懂!!!
阅读全文
posted @ 2020-02-09 14:57 王清河
阅读(160)
评论(0)
推荐(0)
shell编程题(三十三)
摘要: 题目: 获得访问前10位的ip地址 答案: awk '{print $1}' access.log | sort | uniq -c | sort access.log 172.16.8.11 - - [19/Sep/2018:12:35:21 +0800] "GET /console/stat/o
阅读全文
posted @ 2020-02-09 13:06 王清河
阅读(139)
评论(0)
推荐(0)
2020年2月7日
shell编程题(三十二)
摘要: 题目: 根据端口号列出进程号 答案: sudo netstat -ntlp | grep 22 | awk '{print $7}' | cut -d/ -f1 运行结果: linux cut 命令: cut 命令从文件的每一行剪切字节、字符和字段并将这些字节、字符和字段写至标准输出。 如果不指定
阅读全文
posted @ 2020-02-07 11:53 王清河
阅读(131)
评论(0)
推荐(0)
shell编程题(三十一)
摘要: 题目: 查看当前连接SYN的IP数 答案: netstat -an | grep SYN | awk '{print $5}' | awk -F: '{print $1}' | uniq -c | sort -nr | more 运行结果:
阅读全文
posted @ 2020-02-07 11:40 王清河
阅读(120)
评论(0)
推荐(0)
上一页
1
···
13
14
15
16
17
18
19
20
21
···
90
下一页
公告