2011年6月29日水曜日

Scientific Linux 6.0 インストール


このエントリーをはてなブックマークに追加


Scientific Linux とは?

Wikipediaより
Scientific Linux(サイエンティフィック・リナックス)は、フェルミ国立加速器研究所(Fermi National Accelerator Laboratory)及び欧州原子核研究機構(CERN)によるLinuxディストリビューション。RHELをベースとしており、CentOS同様の高い互換性を持つ。

Scientific Linux(以下SL) は CentOSやOracle LinuxのようなRHELクローンOSです。RHELからRedHatの商標を取り除いたパッケージで構成され、ここに科学技術演算用パッケージを追加したものになります。RHELとほぼ完全なバイナリ互換を持っており、サーバー用パッケージもRHELとほぼ同等ですので科学技術用途だけで無くサーバ・クライアント用としても使うことが可能です。

CentOSの開発が鈍化している現状を考えると、巨大組織を開発バックに抱えるSLが今後のRHELクローンの主流になるかもしれません。

入手先
https://www.scientificlinux.org/

ミラー
http://ftp.jaist.ac.jp/pub/Linux/scientific/
http://ftp.ne.jp/Linux/distributions/scientificlinux/
http://ftp.riken.jp/Linux/scientific/
http://ftp.yz.yamagata-u.ac.jp/pub/linux/scientific/

入手するのはinstall-DVD.iso。インストールの流れは以下(デフォルトインストール)



VirtualBox 4.0.10 リリース


このエントリーをはてなブックマークに追加


そんなに気になるリリースは無し。太字部分が自分に影響ありそうな部分。
http://www.virtualbox.org/wiki/Changelog

アップデートしていくつかゲストを動かした感じでは大きな問題はなさそう(Win7 64host - guest winxp, win2000, sol10, sol11, rhel6, rhel5, centos5)
・GUI: fixed disappearing settings widgets on KDE hosts (bug #6809)
・Storage: fixed hang under rare circumstances with flat VMDK images
・Storage: a saved VM could not be restored under certain circumstances after the host kernel was updated (bug #8983)
・Storage: refuse to create a medium with an invalid variant (for example Split2G with VDI; bug #7227)
・Snapshots: none of the hard disk attachments must be attached to another VM in normal mode when creating a snapshot
・USB: fixed occasional VM hangs with SMP guests (bug #4580)
・USB: proper device detection on RHEL/OEL/CentOS 5 guests (partial fix for bug #8978)
・ACPI: force the ACPI timer to return monotonic values for improve behavior with SMP Linux guests (bug #8511 and others)
・RDP: fixed screen corruption under rare circumstances (bug #8977)
・rdesktop-vrdp: updated to version 1.7.0
・OVF: under rare circumstances some data at the end of a VMDK file was not written during export
・Mac OS X hosts: Lion fixes (bug #8903)
・Mac OS X hosts: GNOME 3 fix
・Linux hosts: fixed VT-x detection on Linux 3.0 hosts (bug #9071)
・Linux hosts: fixed Python 2.7 bindings in the universal Linux binaries
・Windows hosts: fixed leak of thread and process handles
・Windows Additions: fixed bug when determining the extended version of the Guest Additions (4.0.8 regression; bug #8948)
・Solaris Additions: fixed installation to 64-bit Solaris 10u9 guests (4.0.8 regression)
・Linux Additions: RHEL6.1/OL6.1 compile fix
・Linux Additions: fixed a memory leak during VBoxManage guestcontrol execute (bug #9068)


2011年6月28日火曜日

Emacs wanderlust mailcapを参照せずに添付ファイルを開く(fiber.exe利用)


このエントリーをはてなブックマークに追加


これはすごい便利。以下をdot.emacsかdot.wlに記載しておけば、添付ファイルにカーソルを合わせてvでアプリが起動してくる。
(defvar my-mime-preview-play-current-entity-appname "fiber"
 "meadow なら fiber, mac なら open, linux なら xdg-open")

(unless (functionp #'mime-preview-play-current-entity-orig)
  (fset #'mime-preview-play-current-entity-orig
        (symbol-function #'mime-preview-play-current-entity)))

(setq mime-play-delete-file-immediately nil)

(defun mime-preview-play-current-entity (&optional ignore-examples mode)
  (interactive "P")
  (if (and mode (not (equal mode "play")))
      (mime-preview-play-current-entity-orig ignore-examples mode)
    (let* ((entity (get-text-property (point) 'mime-view-entity))
           (name (mime-entity-safe-filename entity))
           (filename (expand-file-name (if (and name (not (string= name "")))
                                           name
                                         (make-temp-name "EMI"))
                                       (make-temp-file "EMI" 'directory))))
      (mime-write-entity-content entity filename)
      (message "External method is starting...")
      (let* ((process-name
              (concat my-mime-preview-play-current-entity-appname " " filename))
             (process
              (start-process process-name
                             mime-echo-buffer-name
                             my-mime-preview-play-current-entity-appname
                             filename)))
        (set-alist 'mime-mailcap-method-filename-alist process filename)
        (set-process-sentinel process 'mime-mailcap-method-sentinel)))))
参考>> 俺 wanderlust。さっき mailcap と別れてきた


2011年6月24日金曜日

Emacs isearch で C-h できない


このエントリーをはてなブックマークに追加


恥ずかしながらずっとこういうものだと思っていたんだけど、以下のように設定するればちゃんと使えました。

(global-set-key "\C-h" 'backward-delete-char-untabify)

  ↓

(keyboard-translate ?\C-h ?\C-?)
(global-set-key "\C-h" nil)

参考>> emacsのisearchでC-hで削除できない


2011年6月23日木曜日

Emacs Warning: past XX % of memory limit


このエントリーをはてなブックマークに追加


gc-cons-threshold を大きくするとガベージコレクションの頻度が落ちてEmacsが早くなる、というのを聞いて大きめの値を設定していたんだけど、これを大きくしすぎるとGCが働かなくなってすぐにメモリが上限に近づいてタイトルのメッセージを出してくる。

最近のマシンじゃGC頻度を上げたことで目に見えるパフォーマンスに差は無さそうな感じなので、gc-cons-threshold を小さめに設定しておくと一度起動したEmacsを長く使い回せます。

(setq gc-cons-threshold 10000)


2011年6月20日月曜日

Solaris11 ターミナルで256色を使う


このエントリーをはてなブックマークに追加


Solrais11 exp はncurses が標準でインストールされているので、以下のようにリンクを張ってやるだけでターミナル上ので256色の利用が可能。

# ln -s /usr/gnu/share/terminfo/x/xterm-256color /usr/share/lib/terminfo/x/
# export TERM=xterm-256color


2011年6月19日日曜日

Solaris11/Emacs ATOK + IIIMECF による日本語入力


このエントリーをはてなブックマークに追加


ネットワーク経由でSolarisのATOKは使うのはこちら。今回はX上で使う方法。



2011年6月18日土曜日

Solaris11/Emacs inconsolata フォントを使う


このエントリーをはてなブックマークに追加


Emacs自身はパッケージマネージャーで23.1.1がインストール可能。

フォントの公式サイトは以下。
http://www.levien.com/type/myfonts/inconsolata.html

Solaris11はOTFが使えるので以下を入手する。
http://www.levien.com/type/myfonts/Inconsolata.otf

入手したフォントは/usr/share/fonts/TrueType以下に好きなディレクトリを追加して配置する。
# mkdir /usr/share/fonts/TrueType/emacsfonts
# cp Inconsolata.ttf /usr/share/fonts/TrueType/emacsfonts/

フォントキャッシュを再構築
# fc-cache -vf

確認
# fc-list |grep Inconsolata
Inconsolata:style=Medium

Emacsでの設定
;; フォント設定
(set-face-attribute 'default nil
                    :family "inconsolata"
                    :height 120)


Solaris11 zfs の cifs共有


このエントリーをはてなブックマークに追加


よく使うのでSolaris11用も記載

まずどこでもいいので共有を有効化
# zfs set sharesmb=on rpool/export/cifs01

認証を設定。/etc/pam.confの最終行に以下を追記
# vi /etc/pam.conf
other password required pam_smb_passwd.so.1 nowarn

パスワードを再設定
# passwd username

共有するだけならこれでOK。

参考>> Nexenta で CIFSワークグループ共有を行う


Solaris11 Alt を Metaキーとして使う


このエントリーをはてなブックマークに追加


VBox上のSolaris11でAltがMetaとして使えなかったので、以下で対処。
xmodmap -e 'keycode 64 = Alt_L Meta_L'
これを~/.bashrcに書いておけばOKだった。

参考>> emacs -nw で Alt を Meta として使う