上一页 1 ··· 3 4 5 6 7 8 下一页
摘要: 安装sudo yum install -y gcc gcc-c++ pcre pcre-devel zlib zlib-devel openssl openssl-devel sudo vim /etc/sysctl.conffs.file-max = 999999net.ipv4.tcp_tw_reuse = 1net.ipv4.tcp_keepalive_time = 600net.ipv4.tcp_fin_timeout = 30net.ipv4.tcp_max_tw_buckets = 5000net.ipv4.ip_local_port_range = 1024 61000net.. 阅读全文
posted @ 2013-05-12 18:46 sunsweet 阅读(229) 评论(0) 推荐(0) 编辑
摘要: 1 struct bus_type { 2 char * name; 3 4 struct subsystem subsys; 5 struct kset drivers; 6 struct kset devices; 7 8 struct bus_attribute * bus_attrs; 9 struct device_attribute * dev_attrs;10 struct driver_attribute * drv_attrs;11 12 int (... 阅读全文
posted @ 2013-04-25 14:08 sunsweet 阅读(446) 评论(0) 推荐(0) 编辑
摘要: 1 #include <stdlib.h> 2 #include <stdio.h> 3 #include <sys/stat.h> 4 #include <sys/types.h> 5 #include <unistd.h> 6 #include <fcntl.h> 7 /* 8 * === FUNCTION ====================================================================== 9 * Name: main10 * Description: 11 . 阅读全文
posted @ 2013-04-24 21:21 sunsweet 阅读(311) 评论(0) 推荐(0) 编辑
摘要: $ cd /usr/src$ wget http://www.vim.org/scripts/download_script.php?src_id=9679$ mkdir ~/.vim$ cd ~/.vim$ unzip /usr/src/cvim.zip$ vim ~/.vimrcfiletype plugin on$ vim ~/.vim/c-support/templates/Templates|AUTHOR| = geekstuff|AUTHORREF| = gk|EMAIL| = subscribe@geekstuff|COMPANY| = thegeekstuff... 阅读全文
posted @ 2013-04-02 20:26 sunsweet 阅读(154) 评论(0) 推荐(0) 编辑
摘要: 工作用的web系统,长时间不操作就会cookie会过期,每次看是否有新单的时候,都要登录系统,烦死了用curl写个脚本,5分钟扫描一次,看看有木有单,哈哈新建一个cookie.txt文件 先登录系统,找到cookie,把名字和响应的值写上内容# Netscape HTTP Cookie File# http://curlm.haxx.se/rfc/cookie_spec.html# This file was generated by libcurl! Edit at your own risk.www.baidu.com FALSE / FALSE 0 PHPS... 阅读全文
posted @ 2013-04-01 15:19 sunsweet 阅读(273) 评论(0) 推荐(0) 编辑
摘要: 转自酷勤网http://www.kuqin.com/pragmatic/20130329/334072.html大部分人可能在搜索资料时,会把自己所需要搜索的资料输入Google、百度、雅虎的搜索引擎搜索框,此方法是可行的,但搜索出来的许多资料并不是我们所需要的,如果使用下面的一些方法会大大节省我们的时间。就以百度为例吧:其实百度的“百度搜索帮助”中已经有更详细的介绍,我这里重点推荐三个技巧:1)要学会组合关键词,记得一定要隔开。我想找的资料,一般换不同关键词组合后都会出现在结果首页甚至第一位;2)了解intitle 和filetype的使用方法以及各种文件的扩展名。比如说"我想快速 阅读全文
posted @ 2013-03-30 20:00 sunsweet 阅读(349) 评论(0) 推荐(0) 编辑
摘要: a@A:~> ssh-keygen -t rsaGenerating public/private rsa key pair.Enter file in which to save the key (/home/a/.ssh/id_rsa): Created directory '/home/a/.ssh'.Enter passphrase (empty for no passphrase): Enter same passphrase again: Your identification has been saved in /home/a/.ssh/id_rsa.You 阅读全文
posted @ 2013-03-12 11:01 sunsweet 阅读(131) 评论(0) 推荐(0) 编辑
摘要: 因为只有root才可以抓包,root权限开wireshark,这样会有风险。而且出现这种错误:tshark: Lua: Error during loading: [string "/usr/share/wireshark/init.lua"]:45: dofile has been disabled解决办法:sudo chgrp adm /usr/bin/dumpcap sudo chmod 750 /usr/bin/dumpcap sudo setcap cap_net_raw,cap_net_admin+eip /usr/bin/dumpcap 阅读全文
posted @ 2013-03-07 11:08 sunsweet 阅读(227) 评论(0) 推荐(0) 编辑
摘要: 转自酷壳 – CoolShell.cn原文-by 陈皓vim的学习曲线相当的大(参看各种文本编辑器的学习曲线),所以,如果你一开始看到的是一大堆VIM的命令分类,你一定会对这个编辑器失去兴趣的。下面的文章翻译自《Learn Vim Progressively》,我觉得这是给新手最好的VIM的升级教程了,没有列举所有的命令,只是列举了那些最有用的命令。非常不错。——————————正文开始——————————你想以最快的速度学习人类史上最好的文本编辑器VIM吗?你先得懂得如何在VIM幸存下来,然后一点一点地学习各种戏法。Vimthe Six Billion Dollar editorBetter 阅读全文
posted @ 2013-03-04 00:39 sunsweet 阅读(144) 评论(0) 推荐(0) 编辑
摘要: 转自酷壳 – CoolShell.cn原文by-陈皓相信每一个人对于操作系统的重定向不会陌生了。就是>, >>, <, <<,关于重定向的基本知识我就不说了。这里主要讨论bash的重定向中的一个鲜为人知的东西,那就是bash脚本的函数也可以定义相关的重定向操作。这可不是命令级的重定向,这是函数级的重点向。这并不是一个新的东西,我只是想告诉大家一个已经存在了多年但却可能不被人常用的功能。关于bash的这个函数级的重定向的语法其实很简单,你只需要在函数结尾时加上一些重定向的定义或指示符就可以了。下面是一个示例:function mytest(){ ...} &l 阅读全文
posted @ 2013-03-03 20:59 sunsweet 阅读(319) 评论(0) 推荐(0) 编辑
上一页 1 ··· 3 4 5 6 7 8 下一页