07 2018 档案

摘要:镜像从http://downloads.openwrt.org/releases下载 注意选择generic-rootfs.tar.gz这种类型的镜像 使用docker import导入镜像,导入后可以使用docker images查看看 进入lede里的shell交互环境 docker run - 阅读全文
posted @ 2018-07-31 14:45 sherlock-merlin 阅读(17653) 评论(0) 推荐(0) 编辑
摘要:在sourceforge.net网站下载源码包 需要安装的依赖项有zlib-devel、xz-devel.x86_64 修改Makefile文件以支持xz压缩的squashfs文件,去掉Makefile中 #XZ_SUPPORT = 1的#号 yum install -y zlib-devel xz 阅读全文
posted @ 2018-07-30 09:31 sherlock-merlin 阅读(1927) 评论(0) 推荐(0) 编辑
摘要:使用chkconfig命令列举出所有服务,配合管道筛选出开机默认启动的服务,再去掉level0(关机)、level4(无意义)和level6(重启)的显示,使结果更直观。 chkconfig | grep 3:on | awk '{print $1,$3,$4,$5,$7}' abrt-ccpp 1 阅读全文
posted @ 2018-07-28 15:43 sherlock-merlin 阅读(666) 评论(0) 推荐(0) 编辑
摘要:cat /etc/hosts 127.0.0.1 localhost tw-vars hiwifi 192.168.199.1 t.w tw t 4006024680.com www.4006024680.com tw-download hiwifi.com hiwifi 192.168.199.1 阅读全文
posted @ 2018-07-24 17:10 sherlock-merlin 阅读(1725) 评论(0) 推荐(0) 编辑
摘要:以前以为添加计划任务就是crontab -e来添加,知道今天偶然发现了/etc/cron.d目录,才发现事情没有那么简单。。 crontab -e命令编辑的文件是保存在/var/spool/cron/目录下的一个以用户名为名的文件。 cron有三个地方的配置文件:/etc/crontab,/etc/ 阅读全文
posted @ 2018-07-24 15:27 sherlock-merlin 阅读(428) 评论(0) 推荐(0) 编辑
摘要:不同于标准linux主机,openwrt使用dnsmasq来管理dns和dhcp。 修改dnsmasq的配置文件 vi /etc/config/dhcp 在config dnsmasq这组下面添加 list addnhosts '/etc/myhosts' 这样就可以把/etc/myhosts文件当 阅读全文
posted @ 2018-07-21 15:19 sherlock-merlin 阅读(10675) 评论(0) 推荐(0) 编辑
摘要:其中参数-k表示 允许不使用证书到SSL站点 阅读全文
posted @ 2018-07-20 22:35 sherlock-merlin 阅读(1089) 评论(0) 推荐(0) 编辑
摘要:我们经常用ps | grep xxx来查询是否存在某进程,但默认情况下会将grep这个命令也作为结果返回,这样无论是否存在查询的进程,该命令的返回值都是0。 要避免这种情况可以使用grep的-v参数,含义是Select non-matching lines(选择不匹配的行)。 比如查询cron服务是 阅读全文
posted @ 2018-07-19 09:44 sherlock-merlin 阅读(4866) 评论(0) 推荐(0) 编辑
摘要:本来想安装openwrt的,但是op官方没有支持pi3,甚至op都不怎么发新版了,仅LEDE分支有缓慢的更新。。离题了,之前给pi3装过LEDE,体验不是很好。今天到openwrt官网看了下,发现之前lede不支持pi3,之前刷的固件是为pi2准备的。好在现在已经为pi3做了适配。 根据官方的说法, 阅读全文
posted @ 2018-07-16 23:41 sherlock-merlin 阅读(1501) 评论(0) 推荐(0) 编辑
摘要:也可以用binwalk分析路由器固件,得到uImage文件头起始地址(xxx用10进制起始地址代替) dd if=a.bin of=a.out skip=xxx bs=1c count=64 阅读全文
posted @ 2018-07-16 16:05 sherlock-merlin 阅读(932) 评论(0) 推荐(0) 编辑
摘要:之前用binwalk -Me提取固件中的squashfs,但会生成大量的压缩包等,只提取文件系统的话,可以定位squashfs的文件头(hsqs)位置,然后用dd将它分离出来,然后在unsquashfs解压出来。 比如手头上有个路由器固件,文件名为hc6361.bin hexdump -C hc63 阅读全文
posted @ 2018-07-14 17:46 sherlock-merlin 阅读(3364) 评论(1) 推荐(0) 编辑
摘要:document.addEventListener('keydown',test); function test(e){ var x=e.keyCode; if(x == 49){ console.log("hello"); } } 阅读全文
posted @ 2018-07-13 10:45 sherlock-merlin 阅读(649) 评论(0) 推荐(0) 编辑
摘要:在linux控制台下工作,有时候遇到不懂的单词,想要找个linux下的词典程序,搜寻无果,只好自己动手写个了。 首先获取词典文本文件,在github上找到一个 建立数据库 create database dictdb; 创建表 create table dict(en text,zh text); 阅读全文
posted @ 2018-07-09 12:14 sherlock-merlin 阅读(175) 评论(0) 推荐(0) 编辑
摘要:yum install mysql mysql-server 或者 yum install mariadb mariadb-server 安装完后启动mysql systemctl start mariadb 设置root密码 mysqladmin -u root password "urpassw 阅读全文
posted @ 2018-07-08 18:30 sherlock-merlin 阅读(430) 评论(0) 推荐(0) 编辑
摘要:youtube-dl是谷歌出品的在线视频下载利器,可以用来下载youtube视频(前提是你得能上youtube)。 使用方法很简单,只需要在cmd下执行youtube-de.exe +视频页面网址,程序会自动解析页面中视频的真实地址,并将其下载保存到当前目录。 另外程序有linux版本。 官网地址是 阅读全文
posted @ 2018-07-07 17:42 sherlock-merlin 阅读(459) 评论(0) 推荐(0) 编辑
摘要:原先有个tcpdump的插件,但是现在已经下架了。 条件: 已root的极1s HC5661 1.4.11.21001s 步骤: ssh进去后,opkg install http://downloads.openwrt.org.cn/PandoraBox/ralink/mt7620_old/pack 阅读全文
posted @ 2018-07-04 09:08 sherlock-merlin 阅读(710) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示