http://deflate.medialayer.com/
netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n
关注互联网、网页设计、Web开发、服务器运维优化、项目管理、网站运营、网站安全…
http://deflate.medialayer.com/
netstat -ntu | awk '{print $5}' | cut -d: -f1 | sort | uniq -c | sort -n
Posted in linux 维护优化, shell, 安全, 技术.
rev="post-390" 1 comment
– 2009/03/05
ServerAdmin [email protected] DocumentRoot /dev/null ServerName www.sina.com.cn ServerAlias www.dummy-host.example.com # ErrorLog “logs/dummy-host.example.com-error_log” # CustomLog “logs/dummy-host.example.com-access_log common” 放在虚拟主机最上面.即第一个虚拟主机.
来自linuxtone群主
Posted in Apache.
rev="post-388" No comments
– 2009/03/05
watch 是一个非常实用的命令,基本所有的 Linux 发行版都带有这个小工具,如同名字一样,watch 可以帮你监测一个命令的运行结果,省得你一遍遍的手动运行。
直接在 watch 后面接你想运行的命令,watch 就会帮你重复运行,并把每次的结果都更新在屏幕上。
默认 watch 会以 2s 的间隔重复运行命令,你也可以用 -n 参数指定时间间隔~
还有一个实用的参数是 -d,这样 watch 会帮你高亮显示变化的区域,这样更加一目了然了~ Ctrl+c 就可以退出~
你可以拿他来监测你想要的一切命令的结果变化,比如 tail 一个 log 文件,ls 监测某个文件的大小变化,看你的想象力了~
-d, –differences[=cumulative] 高亮显示变动 -n, –interval= 周期(秒)
而在FreeBSD下的watch命令是查看其它用户的正在运行的操作,watch允许你偷看其它terminal正在做什么,该命令只能让超级用户使用。
如何运行watch:
SYNOPSIS watch [-dhvt] [-n ] [–differences[=cumulative]] [–help] [–interval=] [–no-title] [–version]
DESCRIPTION watch runs command repeatedly, displaying its output (the first screenfull). This allows you to watch the program output change over time. By default, the program is run every 2 seconds; use -n or –interval to specify a different interval.
The -d or –differences flag will highlight the differences between successive updates. The –cumulative option makes highlighting “sticky”, presenting a running display of all positions that have ever changed. The -t or –no-title option turns off the header showing the interval, command, and current time at the top of the display, as well as the following blank line. watch will run until interrupted.
NOTE Note that command is given to “sh -c” which means that you may need to use extra quoting to get the desired effect.
Note that POSIX option processing is used (i.e., option processing stops at the first non-option argument). This means that flags after command don’t get interpreted by watch itself.
EXAMPLES To watch for mail, you might do: watch -n 60 from
To watch the contents of a directory change, you could use: watch -d ls -l
If youre only interested in files owned by user joe, you might use: watch -d ‘ls -l | fgrep joe’
You can watch for your administrator to install the latest kernel with: watch uname -r (Just kidding.)呵呵
BUGS Upon terminal resize, the screen will not be correctly repainted until the next scheduled update. All –differences highlighting is lost on that update as well. Non-printing characters are stripped from program output. Use “cat -v” as part of the command pipeline if you want to see them.
rev="post-386" No comments
– 2009/02/24
查看平均负载的命令 有5个可用:
tload 能够绘制出负载变化的图形 uptime 同时显示开机以来的时间 w 同时显示出已登录的用户 top 这个对资源占用太高,不建议使用 cat /proc/loadavg 通过/proc系统信息得到平均负载
注意:如果你要持续的观察平均负载,建议用 watch uptime 或 watch cat /proc/loadavg
备注:关于watch:每隔一定时间执行指定的程序,并全屏显示结果 时间默认是2秒
rev="post-384" 1 comment
– 2009/02/24
支持iPhone, Windows Mobile, RIM and Symbian,将来会支持Android ,以类似html标签的方式来编写应用。
rev="post-382" No comments
– 2009/02/17
sugarcrm为基于php的开源crm
分为社区版,专业版和企业版,其中社区版为免费使用,和收费版基本一样,工组流和组有差别。
最新版为5.2 http://www.sugarforge.org/content/downloads/downloads.php
中文语言包 http://www.sugarforge.org/frs/?group_id=448
array ( ‘en_us’ => ‘US English’, ), 并更改为 array ( ‘zh_cn’ => ‘简体中文’, ‘en_us’ => ‘US English’, ),
退出系统,然后点击 Options ,选择“简体中文”然后重新登陆…OK!
rev="post-379" 1 comment
– 2009/01/04
Posted in HTML/XHTML/CSS, 技术.
rev="post-376" No comments
– 2008/12/23
方法一:使用tinymce的函数setupcontent_callback 在内容的开头增加
function myCustomSetupContent(editor_id, body, doc) {
body.innerHTML = "" + body.innerHTML;
}
tinyMCE.init({
...
setupcontent_callback : "myCustomSetupContent"
});
方法二:在程序入库前在内容的开头增加
以php为例
$Content = "" +$Content;
方法三:修改tiny_mce.js文件valid_elements中a属性的默认target属性为_blank
使用未压缩片的文件是tiny_mce_src.js.
,a[rel|rev|charset|hreflang|tabindex|accesskey|type|name|href|target=_blank|
总结:
tinymce版本为3 0rc1
方法一和二的base方式在FF中有效,IE下需把放在前,并对以后的所有链接都有效,所以效果欠佳。
方法三比较好。
Posted in JavaScript/DOM/XML, 技术.
rev="post-374" No comments
– 2008/12/19
web系统无法登录,用phpmyadmin查看表内容时报”1030-Got error 28 from table handler”
原因为硬盘没有空间了。
rev="post-372" No comments
– 2008/12/18
UCenter Home 1.5 Nginx rewrite http://www.discuz.net/forum-149-1.html
rewrite ^/(space|network)-(.+).html$ /$1.php?rewrite=$2 last; rewrite ^/(space|network).html$ /$1.php last; rewrite ^/([0-9]+)$ /space.php?uid=$1 last;
以上规则含用[Nginx CVE‑2026‑42945高危漏洞](https://blog.c1gstudio.com/archives/2227),2026/05/15 更新新规则
rewrite ^/(?
space|network)-(?.+)\.html$ /${type}.php?rewrite=${rewrite} last;
rewrite ^/(?
space|network)\.html$ /${type}.php last;
rewrite ^/(?
[0-9]+)$ /space.php?uid=${uid} last;
rev="post-369" No comments
– 2008/11/24
近期评论