搜尋此網誌

2013年8月15日 星期四

Debian下pietty+screen

最近在vm下試debian與centos,發現只要是centos開screen,pietty上面會有一些不一定的文字...

但debian就沒有...原來是 PROMPT_COMMAND 與 /etc/screenrc  的問題


Debian 7.1下改grub2的開機桌布

上課打混用...


0.先裝套件
#apt-get  install grub2-splashimages
#ls  -l /usr/share/images/grub

1.修改設定
#vi /etc/default/grub

加入
GRUB_BACKGROUND="/usr/share/images/grub/Lake_mapourika_NZ.tga"
要確定下面這行有被註解
GRUB_TERMINAL=console


2.這個順便修改一下,加入紅色那行,約在132之後
# vi /etc/grub.d/00_header
if loadfont `make_system_path_relative_to_its_root "${GRUB_FONT_PATH}"` ; then
  set gfxmode=${GRUB_GFXMODE}
  set gfxpayload=keep
  load_video
  insmod gfxterm

3.更該配色...(不過好像改不太出來...)
#vi /etc/grub.d/05_debian_theme
set menu_color_normal=green/yellow
set menu_color_highlight=yellow/red


4.更新grub2,再重新開機...至少圖片賞心悅目多了...
#update-grub



參考網站:
https://wiki.debian.org/Grub2
http://forum.ubuntu.org.cn/viewtopic.php?t=257189
http://wiki.ubuntu-tw.org/index.php?title=GRUB2%E4%B8%AD%E6%96%87%E6%8C%87%E5%8D%97%E7%AC%AC%E4%BA%8C%E7%89%88%28%E4%B8%8A%EF%BC%89

2013年8月6日 星期二

安裝sysstat失敗...update-rc.d: error: insserv rejected the script header

錯誤訊息一堆...想移也移不掉...

insserv: Starting noip2 depends on minissdpd and therefore on system facility `$all' which can not be true!
insserv: Max recursions depth 99 reached
insserv:  loop involving service noip2 at depth 1
insserv: exiting now without changing boot order!
update-rc.d: error: insserv rejected the script header
dpkg: error processing sysstat (--purge):
 subprocess installed post-removal script returned error exit status 1
Errors were encountered while processing:
 sysstat
E: Sub-process /usr/bin/dpkg returned an error code (1)

查了一下google
原來是少了header...
#vi /etc/init.d/noip2



加入
### BEGIN INIT INFO
# Provides:          noip2
# Required-Start:    $syslog
# Required-Stop:     $syslog
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: noip2 service
# Description:       noip2 service
### END INIT INFO


之後移除再安裝就不會有問題啦...