Ubuntu 无法启动Terminal
从8.04升级到8.10后,打开Terminal后出现如下错误:
There was an error creating the child process for this terminal
Terminal打不开。
在/etc/fstab里添加如下两句后重启电脑就好了:
none /dev/pts devpts gid=5,mode=620 0 0
none /dev/shm tmpfs defaults 0 0
Ubuntu 8.04 下删除旧内核
出现的问题:最新一次升级后,发现无法打开“新立得”。出现错误提示为:dpkg was interrupted. 需要输入”dpkg –configure -a”来重新配置。但是当输入上述语句后,提示没有足够空间。。
df一看,发现100MB空间的/boot占用率100%。旧的内核一直没有删除,有2.6.24-16,19,20,21以及最新的22。
于是GOOGLE找出删除内核的办法:
- 实现uname -a 可以查看当前系统使用的内核
- 然后删除某个内核用:sudo apt-get remove linux-image-2.6.15-16
- 依次实行上述命令行删除其它的内核,空间就会被释放出来。
- 再执行sudo update-grub,这样/boot/grub/menu.lst的启动选项中,就不会再有旧内核的选项了
- 还有一个最简洁的命令行:sudo aptitude purge ~ilinux-image-.*\(\!`uname -r`\),这个可以自动删除除了最新内核外其它所有的旧内核,非常强大。
- 另外还有一个办法就是在“新立得”里查找linux来删除
不过,我的问题不是上面这么简单解决的,因为/boot空间是100%使用,所以最近一次升级中没有正常完成,造成dpkg interrupted。所以不管是执行sudo apt-get remove linux-image-2.6.15-16,还是执行sudo aptitude purge ~ilinux-image-.*\(\!`uname -r`\),都会提示dpkg was interrupted,需要重新configure一次。但是有趣又无奈的地方就在这里,因为空间已经满了,所以执行dpkg –configure -a就无法进行。
最后没有办法,只好使用另外一种方法:
先把/boot下的所有除了最新内核22以外的旧内核16,19,20,21的文件全部移到另外一个目录下。这样/boot空间就释放出来了。如果再执行sudo update-grub,启动选项中就不会再有旧内核,旧内核所占/boot的空间也被释放了(旧内核所占其它的空间不会被释放),而且旧内核还是存在于磁盘上,当需要它们的时候,还可以再把这些文件重新复制回/boot目录下。
因为我想把所有的旧内核都彻底删除掉。所以先把20,21的文件移除到别的地方,腾出来一些空间,以便于执行”dpkg –configure -a”。执行完毕后,使用命令行“sudo aptitude purge ~ilinux-image-.*\(\!`uname -r`\)”,自动删除所有旧内核。
有个小问题是,因为我先把/boot下的20,21文件挪到另外一个目录,虽然最后这些文件可以手动删除,但是不知道内核20,21的其它文件有没有被删除掉。。
Ubuntu下安装Codecs
sudo apt-get install gstreamer0.8-plugins sudo apt-get install gstreamer0.8-lame sudo apt-get install gstreamer0.8-ffmpeg sudo apt-get install w32codecs sudo apt-get install libdivx4linux sudo apt-get install lame sudo apt-get install sox sudo apt-get install ffmpeg sudo apt-get install mjpegtools sudo apt-get install vorbis-tools gst-register-0.8
双系统XP和Ubuntu: 重新安装XP后GRUB出错进不了Ubuntu的解决办法
使用ubuntu liveCD
打开Terminal
sudo -i (使用root身份)
grub (这个地方需要花一点时间)
find /boot/grub/stage1
(会出现(hdx,y) -> 里面没有空格. 我的出现的是(hd1,3),说明ubuntu是在第二块硬盘上,第3个分区)
root (hd1,3)
setup (hd1)
grub> setup (hd1)
Checking if “/boot/grub/stage1″ exists… yes
Checking if “/boot/grub/stage2″ exists… yes
Checking if “/boot/grub/e2fs_stage1_5″ exists… yes
Running “embed /boot/grub/e2fs_stage1_5 (hd1)”… 16 sectors are embedded.
succeeded
Running “install /boot/grub/stage1 (hd1) (hd1)1+16 p (hd1,3)/boot/grub/stage2
/boot/grub/menu.lst”… succeeded
Done.
grub>quit
安装配置Nessus
去http://www.nessus.org下载最新的版本
#dkpg -i Nessus-3.2.1-ubuntu804_i386.deb
然后去http://www.nessus.org/plugins/?view=register-info注册一下
去邮箱取回Activation code
/opt/nessus/bin/nessus-fetch --register 1E2A-4553-D03B-71AF-56F3 - Please run /opt/nessus/sbin/nessus-adduser to add an admin user - Register your Nessus scanner at http://www.nessus.org/register/ to obtain all the newest plugins - You can start nessusd by typing /etc/init.d/nessusd start
