LoginSignup
15
9

More than 5 years have passed since last update.

Windowsで特定の接続先のみVPN接続をする備忘録

Last updated at Posted at 2019-05-22

1.デフォルトでVPNを使う設定を外す

①コントロール パネル>ネットワークとインターネット>ネットワーク接続で、
 該当のVPNを右クリック⇒プロパティをクリック

②ネットワークタブでTCP/IPv4を選択⇒プロパティをクリック⇒詳細設定をクリック

③IP設定タブで「リモートネットワークでデフォルトゲートウェイを使う」のチェックを外す

2.VPNの番号を確認

以下をcmdで実行してインターフェイス一覧からルーティングしたいVPN番号メモ

route print

3.接続したいIPアドレスを設定

以下をcmdで実行してVPNを使用して接続したいIPアドレスを設定

route -p add 接続先IPアドレス mask 255.255.255.255 VPNサーバIPアドレス metric 1 if メモしたVPNの番号
15
9
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
15
9