過去ログ

アフィリエイト広告を利用しています

Sun xVM VirtualBox NAT設定メモ

Oracle VM VirtualBoxの設定メモ

SSHの設定例 Port22をホストの20022に設定

VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/Protocol" TCP
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/GuestPort" 22
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/HostPort" 20022

VBoxManage  : VirtualBox設定用コマンド
setextradata : 設定コマンド?
Debian404ra : 名前に設定したもの
VBoxInternal : 固定
Devices   : 固定
pcnet    : pcnet(PCNet-FAST?) e1000(Intel PRO/1000 MT Desktop )
0      : アダプタ番号が1なら0、2なら1
LUN#0    : 不明
Config    : 固定
guestssh   : ユニークな名前、sshならguestssh、HTTPならguesthttp
Protocol   : プロトコル指定 TCP/UDP
GuestPort  : 仮想サーバ側のNATしたいポート
HostPort   : ホスト側で参照するためのポート


HTTPの例 Port80をホストの20080に設定

VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/Protocol" TCP
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/GuestPort" 80
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/HostPort" 20080


HTTPSの例 Port443をホストの20443に設定

VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/Protocol" TCP
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/GuestPort" 443
VBoxManage setextradata "Debian404ra" "VBoxInternal/Devices/pcnet/0/LUN#0/Config/guestssh/HostPort" 20443