存档

‘OpenSource’ 分类的存档

使用rrdtoo resize修改已有rrd文件的数据量

2013年12月11日 评论已被关闭

Cacti中超过30天的数据精度明显下降,导致自己对交换机画出来的数据与IDC的数据对比存在一定的差异(IDC提供的数据要高一些,因为精度不如人家,于是表面上强硬,交钱时却只能按事实说话。)

rrd文件格式


rrdtool create 2hei_netflow.rrd \
--start `date +%s` \
--step 300 \
DS:bjidc:COUNTER:600:U:U \
DS:gzidc:COUNTER:600:U:U \
DS:shidc:COUNTER:600:U:U \
DS:szidc:COUNTER:600:U:U \
RRA:AVERAGE:0.5:1:8640 \
RRA:AVERAGE:0.5:4:4320 \
RRA:AVERAGE:0.5:24:2160 \
RRA:AVERAGE:0.5:288:730

说明:


(5分钟 * 1 * 8640) /(60(分钟) * 24(小时)) = 30天
(5分钟 * 4 * 4320) /(60(分钟) * 24(小时)) = 60天
(5分钟 * 24 * 2160)/(60(分钟) * 24(小时)) = 180天
(5分钟 * 288 * 730)/(60(分钟) * 24(小时)) = 730天

阅读全文…

分类: OpenSource 标签:

postfix删除mail中的邮件列表

2013年12月6日 评论已被关闭
  • 删除mailq中所有deferred的邮件:

postsuper -d ALL deferred

postsuper用法可以man一下:

man postsuper

  • 删除指定帐户的邮件:

mailq | tail +2 | grep -v ‘^ *(‘ | awk ‘BEGIN { RS = “” }
# $7=sender, $8=recipient1, $9=recipient2
{ if ($8 == “filter@2hei.net” && $9 == “”)
print $1 }’| tr -d ‘*!’ | postsuper -d –

修改后的脚本:
mailq | tail -n+2 | grep -v ‘^ *(‘ | awk ‘BEGIN { RS = “” } \
{ if ($8 == “filter@2hei.net”) \
print $1 }’| tr -d ‘*!’ | postsuper -d –

  • 删除指定的queue id:

postsuper -d queue_id

分类: OpenSource 标签:

Mozilla making progress with Firefox’s long journey to multiprocess

2013年12月6日 评论已被关闭
Multiple Firefox processes.

Internet Explorer and Chrome both use a multiprocess architecture to enhance stability and security. They separate the task of parsing and rendering Web pages from the job of drawing the browser on-screen, saving downloaded files, creating network connections, and so on. This allows them to run the dangerous parts—the parts exposed to malicious scripts and exploitative HTML—in a sandbox with reduced permissions, making it harder for browser flaws to be turned into system compromises.

It also means that they’re much more tolerant of crash bugs; a bug will bring down an individual tab, but shouldn’t, in general, bring down the browser as a whole.

In 2009, Mozilla announced the Electrolysis project, which was to bring this kind of multiprocess design to Firefox.

Read 10 remaining paragraphs | Comments

       



分类: OpenSource 标签:

All of Wikipedia can be installed to your desktop in just 30 hours

2013年11月26日 评论已被关闭

An open source application automates the process of downloading and displaying all of Wikipedia on your desktop, a large task that takes more than a day to complete.

Dubbed Xowa, the software displays an offline copy of 4.4 million Wikipedia articles with full HTML formatting intact. You can even set up additional wikis, like Wiktionary or Wikquote, and navigate between them while offline. For example, you could “Click on ‘Look up this word in Wiktionary’ and instantly view the page in Wiktionary.”

Xowa has been around for a while with support for “Simple Wikipedia,” which has just a fraction of the full collaborative dictionary. It was updated yesterday with support for the entire English language-version of Wikipedia.

Read 5 remaining paragraphs | Comments

       



分类: OpenSource 标签:

Winamp lovers beg AOL to open source code

2013年11月25日 评论已被关闭

Last week, AOL announced the impending death of Winamp, saying that the 16-year-old media player would be shut down within a month.

“Winamp.com and associated Web services will no longer be available past December 20, 2013. Additionally, Winamp Media players will no longer be available for download. Please download the latest version before that date,” AOL announced.

But fans of the venerable software have launched a “Save Winamp” website and petition asking AOL either to keep Winamp alive or to open source its code.

Read 3 remaining paragraphs | Comments

       



分类: OpenSource 标签:

Microsoft brings rich node.js support to Visual Studio

2013年11月21日 评论已被关闭

As the company continues to court programmers developing on software stacks that aren’t its own, Microsoft has released a plugin for Visual Studio that provides extensive support for Node.js within the Visual Studio IDE.

The Apache-licensed Node.js Tools for Visual Studio offer editing with IntelliSense, Node.js projects, debugging, profiling, and deployment, all inside Microsoft’s IDE. The plugin also includes a graphical interface to Node’s NPM package manager, so Node libraries can be downloaded from the NPM repository, again from within Visual Studio.

Though still only an “alpha” release, the development experience looks remarkably complete already. The plugin is plumbed into the V8 debugger and profiling APIs that Node already uses, so it should provide consistent results and capabilities as Node developers not using the plugin will have.

Read 1 remaining paragraphs | Comments

       



分类: OpenSource 标签:

New backdoor worm found attacking websites running Apache Tomcat

2013年11月20日 评论已被关闭
Diagram showing how Tomdep receives commands and spreads to new machines.

Researchers have identified new self-replicating malware that infects computers running the Apache Tomcat Web server with a backdoor that can be used to attack other machines.

Java.Tomdep, as the backdoor worm has been dubbed, is Java Servlet-based code that gives Apache Tomcat platforms malicious capabilities. It causes infected machines to maintain Internet relay chat (IRC) communications with attacker servers located in Taiwan and Luxembourg. The control servers send commands and receive progress reports to and from the infected machines. Affected platforms include Linux, Mac OS X, Solaris, and most supported versions of Windows. Researchers haven’t said precisely how the malware takes initial hold of servers, but there’s no evidence yet it exploits any vulnerability in Tomcat or any other software running on infected servers.

In a blog post published Wednesday, Takashi Katsuki, a researcher at security firm Symantec, said Java.Tomdep appears to be designed to harness the huge amounts of bandwidth and computing power available to Web servers for use in denial-of-service attacks against other machines. Unlike Darkleech and other malware targeting Web servers, there’s no indication that it’s used to attack end users visiting websites. Katsuki explained:

Read 3 remaining paragraphs | Comments

       



分类: OpenSource 标签:

GitHub resets user passwords following rash of account hijack attacks

2013年11月20日 评论已被关闭

GitHub is experiencing an increase in user account hijackings that’s being fueled by a rash of automated login attempts from as many as 40,000 unique Internet addresses.

The site for software development projects has already reset passwords for compromised accounts and banned frequently used weak passcodes, officials said in an advisory published Tuesday night. Out of an abundance of caution, site officials have also reset some accounts that were protected with stronger passwords. Accounts that were reset despite having stronger passwords showed login attempts from the same IP addresses involved in successful breaches of other GitHub accounts.

“While we aggressively rate-limit login attempts and passwords are stored properly, this incident has involved the use of nearly 40K unique IP addresses,” Tuesday night’s advisory stated. “These addresses were used to slowly brute force weak passwords or passwords used on multiple sites. We are working on additional rate-limiting measures to address this. In addition, you will no longer be able to login to GitHub.com with commonly used weak passwords.”

Read 3 remaining paragraphs | Comments

       



分类: OpenSource 标签:

Stability first: Ubuntu’s Mir won’t replace X in 14.04 desktop

2013年11月19日 评论已被关闭
Ubuntu 13.10.

Mir, Canonical’s replacement for the X window system, will not make it into the next version of the Ubuntu desktop.

Canonical initially planned to turn Mir on by default in Ubuntu 13.10, the version shipped in October 2013, but it was dropped due to compatibility problems in multi-monitor setups. It’s especially important not to add any buggy technologies to 14.04, the version coming in April 2014, because that is a Long-Term Support (LTS) edition that Canonical must maintain for five years. Mir itself seems to be working fine, but there are problems with XMir, an X11 compatibility layer that ensures Mir can work with applications built for X.”We will only bring Mir into 14.04 if we can be assured that we’re not going to have any support issues,” Ubuntu Community Manager Jono Bacon told Ars last month.

It now appears Mir won’t make it into the next edition. “It was affirmed today that Ubuntu 14.04 LTS will still be shipping with the stable and proven Unity 7 experience, which is designed around using an X.Org Server with Compiz,” Phoronix’s Michael Larabel wrote today. “It doesn’t appear they will try for using XMir by default in this next Long-Term Support release with Unity 7. It was also said today that point releases to Ubuntu 14.04 LTS will not be adding in Mir or Unity 8.”

Read 18 remaining paragraphs | Comments

       



分类: OpenSource 标签:

lvs ksoftirqd进程占用大量CPU

2013年11月19日 评论已被关闭

监控的时候,发现LVS貌似遇到了瓶颈,高峰期间发现有两个进程ksoftirqd/0ksoftirqd/1占用大量cpu,LVS为虚拟机:DR模式,配置了2GB内存,2core。
LVS带宽跑到了15M,见监控图:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

阅读全文…

分类: OpenSource 标签: