Mac: 2008年12月アーカイブ

Mac上のVirtualBoxだとホストインターフェース接続設定が困難なため、ssh接続に悩みがあった。
で解決策を発見。

Headless - Fedora 9 (32-bit) Guest on Fedora 8 (64-bit) Host - VIrtualBox #6

sshの設定

$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/Protocol" TCP
$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/GuestPort" 22
$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/HostPort" 50022

macのterminalからアクセス

$ ssh -p 50022 -l administrator localhost

administratorはゲストOSでのユーザー名、ポートは50022 は使用。

httpの設定

$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guesthttp/Protocol" TCP
$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guesthttp/GuestPort" 80
$ VBoxManage setextradata "Fedora9" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guesthttp/HostPort" 50080

Virtualboxでの名前は"Fedora9"を使用し、ポートは50000台を使用。
以上、備忘録。

追:fedora10をそろそろ試すかな。



emacsの設定


Emacs上でGaucheが動くと聴いて即設定。


環境

Mac OS 10.5


設定手順


emacsの起動。


$ emacs

以下、emacs上の作業。

ホームディレクトリに存在する設定ファイル.emacs.elを指定。



C-x C-f ~/.emacs.el

.emacs.elの設定内容



;;言語設定は日本語を設定。
(set-language-environment 'Japanese)

;;Gaucheをemacs上で使うための設定。
(setq scheme-program-name "gosh -i")
(autoload 'scheme-mode "cmuscheme" "Major mode for Scheme." t)
(autoload 'scheme-mode "cmuscheme" "Run an inferior Scheme process." t)
(defun scheme-other-window()
"Run scheme on other window"
(interactive)
(switch-to-buffer-other-window
(get-buffer-create "*scheme*"))
(run-scheme scheme-program-name))
(define-key global-map "\C-cs" 'scheme-other-window)

保存。



C-x C-s

設定ファイルのリロード。



M-x load-file<RET>
.emacs.el


emacs上でgoshを実行。



C-c s

以上、完了。


あわせて読みたい

  • あわせて読みたいブログパーツ

Lingr java-ja

ウェブページ

Powered by Movable Type 4.1