自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(12)
  • 资源 (6)
  • 收藏
  • 关注

原创 java.lang.OutOfMemoryError: Java heap space

线上的一个报表系统,基于tomcat  经常出现out of memory错误,增加JVM内存,在catalina.sh 修改如下配置:  -Xmx6g -Xms6g -Xmn256m   仍不解决问题,后来内存涨到15G,照样oom。  我推测可能是新生代内存太少,导致新生代内存区不断充满,转移到old区,  而old区回收速度慢,导致的问题,于是我将设置  -Xmx

2015-06-03 16:11:13 372

原创 slab子系统初始化的chicken-egg问题(先有鸡还是先有蛋)

slab子系统的初始化,需要使用kmalloc分配slab系统初始化所需要数据结构的内存,而kmalloc必须在slab系统初始化完成后才能正常工作。所以这就形成一个环,先有鸡还是先有蛋的问题。kmem_cache_init()的过程,分以下几步解决这个问题:1、创建cache_cache和cache_cache中的head array,采用静态数据的方式2.、使用cache_cache分配第一个

2010-05-24 19:30:00 730

原创 emacs 换行符(dos2unix)

最近做项目需要在windows上使用putty通过SSH登录到LINUX上写代码,很不舒服,就是使用samba建立与windows的目录共享。这样直接可以在windows上操作LINUX上的代码了。但是问题就来了。windows上换行符与LINUX不同,在windows编辑的文件,在LINUX编译不过。 想了一个简单的办法(global-set-key (kbd "C-x

2010-01-29 11:58:00 3420

原创 我的emacs配置

;显示括号匹配(show-paren-mode t);括号匹配时显示另外一边的括号,而不是跳到另一个括号(setq show-paren-style parentheses);;显示所在行号和列号(column-number-mode t); 光标显示为一竖线(setq-default cursor-type bar); 不要问 yes-or-no,只问 y-or-n (fset yes-o

2010-01-20 17:46:00 1758

原创 linux 进程间共享内存

可以采用sysV的shmget + shmat 实现。但是我更喜欢shm_open + mmap 更简单。#---------------------writer.c----------------------------#include #include #include #include #include #include #include #inclu

2009-12-16 23:05:00 515

原创 mew 在w32下适配emacs的问题

 在emacs中使用mew接收mime的邮件,打开附件时,mew-win32.el会指定打开程序默认程序fiber.exe网上没有找到这个程序。mew-win32.el(defvar mew-w32-exec           "fiber.exe")改为(defvar mew-w32-exec           "explorer.exe") 然后把mew-m

2009-11-19 09:23:00 671

原创 设置emacs字体

通过options菜单选择字体,满意后 M-x ielm RET  执行 (frame-parameter nil font) RET获取配置的字符串例如"-outline-Courier New-normal-r-normal-normal-16-120-96-96-c-*-iso8859-1"把如下形式的代码贴入.emacs,即可 (set-default-font

2009-11-17 16:50:00 439

原创 socket close vs shutdown

         Calling close and shutdown have two different affects on the underlying socket.                                                                                                                

2009-11-16 16:45:00 550

原创 emacs todo-mode 简单实用

 To-do可以用来做日程安排,todo,done,top分别表示要完成的事情,已完成的事情,和优先事情。记录文件默认放到目录下~/.todo/下面是一些快捷操作i 加入一个条目e 编辑条目k 删除条目+/- 在不同category之间切换j 跳转到不同的categoryf 对已完成的事

2009-11-05 09:25:00 1967

转载 模冗余系统

m模冗余系统由m个(m=2n+1为奇数)相同的子系统和一个表决器组成,经过表决器表决后,m个子系统中占多数相同结果的输出作为系统的输出,如图1-8所示。┇ 图1-8 模冗余系统在m个子系统中,只有n+1个或n+1个以上子系统能正常工作,系统就能正常工作,输出正确结果。假设表决器是完全可靠的,每个子系统的可靠性为R0,则m模冗余系统的可靠性

2009-10-21 10:28:00 1593

原创 emacs Mew的使用

~/.new.el内容:(setq mew-config-alist (        ("default"        ("name"         .  "KT")        ("user"         .  "paragenius")        ("smtp-server"  .  "smtp.sohu.com")        ("smtp-por

2009-07-23 10:31:00 3221

原创 do_mmap_pgoff中一处疑问

     vma = find_vma_prepare(mm, addr, &prev, &rb_link, &rb_parent);    if (vma && vma->vm_start         if (do_munmap(mm, addr, len)) 《---这里为什么要删除空间            return -ENOMEM;        goto mu

2009-07-22 23:34:00 756

Debugging with GDB

GDB can do four main kinds of things (plus other things in support of these) to help u catch bugs in the act: • Start your program, specifying anything that might affect its behavior. • Make your program stop on specified conditions. • Examine what has happened, when your program has stopped. • Change things in your program, so you can experiment with correcting the effects of one bug and go on to learn about another.

2010-03-13

Practical File System Design with the Be File System

This is the new guide to the design and implementation of file systems in general, and the Be File System (BFS) in particular. This book covers all topics related to file systems, going into considerable depth where traditional operating systems books often stop. Advanced topics are covered in detail such as journaling, attributes, indexing and query processing. Built from scratch as a modern 64 bit, journaled file system, BFS is the primary file system for the Be Operating System (BeOS), which was designed for high performance multimedia applications. You do not have to be a kernel architect or file system engineer to use Practical File System Design. Neither do you have to be a BeOS developer or user. Only basic knowledge of C is required. If you have ever wondered about how file systems work, how to implement one, or want to learn more about the Be File System, this book is all you will need.

2009-09-08

Mastering_Perl-Tk.chm

The Tk module gives the Perl programmer full access to the powerful Tk widget set. This rich and diverse library, like Perl itself, makes the easy things easy and the hard things possible. Easy things include designing graphical interfaces with Buttons, Checkbuttons, Menus, and text entry fields—all of which you will learn about in the first half of this book. The second half of the book contains more advanced topics, such as creating custom widgets, interprocess communication, images, animation, and key bindings. The goal of this book is to take you from Tk neophyte to Tk expert.

2009-04-18

Perl&Lwp.chm

LWP套装的模块,可以让您的程式下载和提取信息从网络。 Perl&lwp表明,如何使Web请求,提交表格,甚至提供认证信息,它表明使用正则表达式,令牌,和树木来解析的HTML ..这本书是一个Perl程序员想要自动化和WEB必须所拥有的。

2009-04-18

空空如也

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除