0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

openvpnコマンドでプロキシ経由で接続を確立する

Last updated at Posted at 2025-06-26

What's?

タイトルどおり、openvpnコマンドでプロキシ経由で接続を確立したいということで。

環境

今回の環境はこちらのRocky Linux 9です。

$ cat /etc/redhat-release
Rocky Linux release 9.6 (Blue Onyx)


$ uname -srvmpio
Linux 5.14.0-570.22.1.el9_6.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Jun 18 17:59:46 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux

openvpnコマンドでプロキシ経由で接続を確立する

まずはOpenVPNのインストール。

$ sudo dnf install openvpn

バージョン確認。

$ openvpn --version
OpenVPN 2.5.11 x86_64-redhat-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on Jul 18 2024
library versions: OpenSSL 3.2.2 4 Jun 2024, LZO 2.10
Originally developed by James Yonan
Copyright (C) 2002-2022 OpenVPN Inc <sales@openvpn.net>
Compile time defines: enable_async_push=yes enable_comp_stub=no enable_crypto_ofb_cfb=yes enable_debug=yes enable_def_auth=yes enable_dependency_tracking=no enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown enable_fast_install=yes enable_fragment=yes enable_iproute2=no enable_libtool_lock=yes enable_lz4=yes enable_lzo=yes enable_management=yes enable_multihome=yes enable_pam_dlopen=no enable_pedantic=no enable_pf=yes enable_pkcs11=yes enable_plugin_auth_pam=yes enable_plugin_down_root=yes enable_plugins=yes enable_port_share=yes enable_selinux=yes enable_shared=yes enable_shared_with_static_runtimes=no enable_silent_rules=yes enable_small=no enable_static=yes enable_strict=no enable_strict_options=no enable_systemd=yes enable_werror=no enable_win32_dll=yes enable_x509_alt_username=yes with_aix_soname=aix with_crypto_library=openssl with_gnu_ld=yes with_mem_check=no with_openssl_engine=auto with_sysroot=no

接続時は、以下のように。--http-proxyでプロキシサーバを指定できます。

$ sudo openvpn --config [OpenVPN接続用の設定ファイル] --http-proxy [proxy-host] [proxy-port]
0
0
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
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?