Archive for the ‘Linux’ Category

[AMP] Mysql 导入导出csv

2015.8 28

导出csv select * from test_info into outfile ‘/tmp/test.csv’ fields terminated by ‘,’ optionally enclosed by ‘”‘ escaped by ‘”‘ lines terminated by ‘\n’; 导入csv … Read the rest of this entry

[AMP] Mysql 字符集设置

2015.8 28

MySQL字符集设置 • 系统变量: – character_set_server:默认的内部操作字符集 – character_set_client:客户端来源数据使用的字符集 – character_set_connection:连接层字符集 – character_set_results:查询结果字符集 – character_set_database:当 Read the rest of this entry

[AMP] mysqlimport: Error: 13, Can’t get stat of

2015.8 27

[root@sun ~]# mysqlimport –fields-terminated-by=, –lines-terminated-by=\n ziliao ./a.csv mysqlimport: Error: 13, Can’t get stat of ‘/var/lib/mysql/a.csv’ (Errcode: 2), when using table: a 缺少一个参数 … Read the rest of this entry

[Linux] bash: fork: retry: Resource temporarily unavailable

2015.3 14

程序都不能运行了!原本是想模拟多进程,幸亏不是用的root.要不然系统就要崩溃了! Read the rest of this entry

[Shell编程] shell脚本改变工作目录

2015.2 2

shell脚本运行的几种方式: 1:添加脚本的执行权限,然后通过路径加文件名的方式运行 chmod +x test.sh;./test.sh 2:source test.sh 或者 . test.sh 3: sh test.sh 后两种方式不必添加脚本的执行权限。怎么改变shell脚本运行的工作目录呢?请看 Read the rest of this entry

[Linux] linux mail 发送邮件

2012.12 7

前段时间看非你莫属,有微博营销的介绍。自己也从网上下了个发邮件的东西,不过是试用版,有好多限制。 自己以前弄过发邮件备份博客的脚本。 不过发送的邮件很可能是进入了对方的垃圾箱中。 在网上发邮件不能直接发送 Read the rest of this entry

[Linux] 我的毕业论文

2012.11 27

今晚无意中看到毕业论文答辩时用的ppt,不知不觉,毕业已经有4年半了。 虽然感觉不像是发生在昨天,记忆已有点模糊了。看着现在的ppt,依稀能感觉到当时对技术的执着。 截图让我回忆到了下面几件东西。 NE40,当时我们学 Read the rest of this entry

[Linux] php-cgi进程数超过预设值问题的解决

2012.9 14

nginx的502错误真是恼人。修改这又是修改那还是不行。 其中要修改一个php—fpm.conf 的配置文件:<value name=”max_children”>50</value>。 记得自己明明是设置的50,但是在执行ps aux|grep php-cgi|wc -l 后显示502。怎么会这样。 Read the rest of this entry

[Linux] vim 删除每行开头结尾空格

2012.9 14

别人的代码,有点乱。需要删除行首的空格,怎么也搞不出来,就搜了一下: 删除行末空格: :%s/\s\+$// 删除行首空格: :%s/^\s\+//  “%”:作用于整个文件; “\s\+$”:表示行末($)前的一个或者多个(\+)空格(\s Read the rest of this entry

[Linux] DES 加密

2012.7 10

一次无意中在用户的路由器的日志发现了一条有用的信息。意思就是说用户当前所在的vlan和服务器上的不一致。当时就很好奇,就用wireshark抓捕看了一下。详细信息请看BRAS升级。 给出的提示是很丰富的。我遇到的就有密码输入 Read the rest of this entry