上一页 1 2 3 4 5 6 7 8 ··· 71 下一页
摘要: start_kernel函数的最后一行:rest_init,调用了init程序。看代码就很清楚了。有个地方值得注意的是,优先被调用的是initramfs中的init程序(可以通过rdinit=xxx来设定)。然后才会去检查"init="的设置。如果这两个都没有设置的话,kernel就会挨个去尝试/sbin/init, /bin/init, /bin/sh...这些都没有那就panic了 阅读全文
posted @ 2013-01-30 22:14 super119 阅读(350) 评论(0) 推荐(0) 编辑
摘要: zImage不是标准的gzip文件,需要自己strip掉开头的一些东西才可以gunzip。基本上的思路就是找gzip的magic number "1f 8b 08"。具体步骤:$ mkdir -p /tmp/kernel-uncompressed/; cd /tmp/kernel-uncompressed/$ cp /boot/vmlinuz-`uname -r` .$ od -t x1 -A d vmlinuz-2.6.18-128.el5.uvm6PAE | grep "1f 8b 08"0008320 1b 00 1f 8b 08 00 d5 c2 阅读全文
posted @ 2013-01-30 17:57 super119 阅读(1196) 评论(0) 推荐(0) 编辑
摘要: Gentoo将bash completion单独做成了一个package。而且安装完成之后,可以用:eselect bashcomp list -- 查询所有支持bash completion的模块,比如我们最常用的git, git-prompteselect bashcomp enable <module>所以,非常的方便。一定要安装,否则git就没有bash completion了。看了一下大概的原理,当bash-completion被安装之后,在/etc/profile.d目录下会生成一个文件:bash-completion.sh当一个module被enable了之后(假设不 阅读全文
posted @ 2013-01-22 23:52 super119 阅读(377) 评论(0) 推荐(0) 编辑
摘要: 比如说现在的project就是一个git repo,在这个project中我们有一些参考的project的源代码,也是git repo的形式。这样就会有问题,git push的时候,子git repo就没法push到server上(不知道为什么)。所以这样的子git repo就需要去掉.git目录,一般来说,下载该project的release package解开即可。我想这也可能是repo出现的原因吧。如果上述的情况git可以handle,就不需要repo了吧。 阅读全文
posted @ 2013-01-21 22:05 super119 阅读(323) 评论(0) 推荐(0) 编辑
摘要: # Add "--global" if you want this config to be globallygit config alias.cs "commit -s"git config user.name "<your name>"git config user.email "<your mail>"So after that, use "git cs" instead of "git commit". 阅读全文
posted @ 2013-01-21 17:43 super119 阅读(388) 评论(0) 推荐(0) 编辑
摘要: 编辑/etc/ssh/sshd_config:X11Forwarding yesX11DisplayOffset 10X11UseLocalhost yes 阅读全文
posted @ 2013-01-20 22:04 super119 阅读(694) 评论(0) 推荐(0) 编辑
摘要: 重新编译kernel,就直接make menuconfig, make即可。只是编译完成之后,将.config拷贝到/etc/kernels目录下,这是genkernel用来保存它配置的kernel config文件的地方。将arch/x86_64/boot/bzImage拷贝到/boot下,覆盖相应文件。将System.map拷贝到/boot下,覆盖相应文件。至于initramfs,则直接运行:genkernel initramfs即可 阅读全文
posted @ 2013-01-17 10:46 super119 阅读(1937) 评论(0) 推荐(0) 编辑
摘要: From: Documentation/SubmittingPatches2) #ifdefs are uglyCode cluttered with ifdefs is difficult to read and maintain. Don't doit. Instead, put your ifdefs in a header, and conditionally define'static inline' functions, or macros, which are used in the code.Let the compiler optimize away 阅读全文
posted @ 2013-01-14 16:32 super119 阅读(263) 评论(0) 推荐(0) 编辑
摘要: From: Documentation/email-clients.txtThunderbird (GUI)Thunderbird is an Outlook clone that likes to mangle text, but there are waysto coerce it into behaving.- Allows use of an external editor: The easiest thing to do with Thunderbird and patches is to use an "external editor" extension an 阅读全文
posted @ 2013-01-14 16:13 super119 阅读(224) 评论(0) 推荐(0) 编辑
摘要: gentoo-china-overlay和gentoo-taiwan-overlay目前合并成了gentoo-zh,并且这三个overlay都已经进入了gentoo官方layman数据库。所以:- sudo emerge -avt layman- sudo layman -L 可以查询overlay列表- sudo layman -a gentoo-zh- 编辑/etc/portage/make.conf,添加:source /var/lib/layman/make.conf(需要至少添加了一个overlay之后才会有这个make.conf)事实上,emerge layman之后,就会有一些打 阅读全文
posted @ 2013-01-09 23:24 super119 阅读(2116) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 7 8 ··· 71 下一页