差分
このページの2つのバージョン間の差分を表示します。
両方とも前のリビジョン 前のリビジョン 次のリビジョン | 前のリビジョン | ||
linux:vnc [2022/08/28 02:36] – [VNC(Virtual Network Computing)] ともやん | linux:vnc [2023/09/01 12:54] (現在) – [インストール] ともやん | ||
---|---|---|---|
行 1: | 行 1: | ||
====== VNC(Virtual Network Computing) ====== | ====== VNC(Virtual Network Computing) ====== | ||
+ | {{: | ||
+ | |||
VNC(Virtual Network Computing)は、リモートデスクトップを実現するクロスプラットフォームのソフトウェアである。\\ | VNC(Virtual Network Computing)は、リモートデスクトップを実現するクロスプラットフォームのソフトウェアである。\\ | ||
VNCサーバが動作するOS(Windows CE/ | VNCサーバが動作するOS(Windows CE/ | ||
行 6: | 行 8: | ||
[[wwjp> | [[wwjp> | ||
+ | |||
+ | ===== TigerVNC (Tiger Virtual Network Computing) ===== | ||
+ | |||
+ | ==== インストール ==== | ||
+ | tigervnc-server パッケージをインストールする🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result_long>< | ||
+ | メタデータの期限切れの最終確認: | ||
+ | 依存関係が解決しました。 | ||
+ | ======================================================================================================================== | ||
+ | | ||
+ | ======================================================================================================================== | ||
+ | インストール: | ||
+ | <b class=GRN> | ||
+ | 依存関係のインストール: | ||
+ | <b class=GRN> | ||
+ | |||
+ | トランザクションの概要 | ||
+ | ======================================================================================================================== | ||
+ | インストール | ||
+ | |||
+ | ダウンロードサイズの合計: | ||
+ | インストール後のサイズ: | ||
+ | これでよろしいですか? | ||
+ | パッケージのダウンロード: | ||
+ | (1/2): tigervnc-selinux-1.12.0-6.fc36.noarch.rpm | ||
+ | (2/2): tigervnc-server-1.12.0-6.fc36.x86_64.rpm | ||
+ | ------------------------------------------------------------------------------------------------------------------------ | ||
+ | 合計 | ||
+ | トランザクションの確認を実行中 | ||
+ | トランザクションの確認に成功しました。 | ||
+ | トランザクションのテストを実行中 | ||
+ | トランザクションのテストに成功しました。 | ||
+ | トランザクションを実行中 | ||
+ | 準備 | ||
+ | scriptletの実行中: | ||
+ | インストール中 | ||
+ | scriptletの実行中: | ||
+ | インストール中 | ||
+ | scriptletの実行中: | ||
+ | 検証 | ||
+ | 検証 | ||
+ | |||
+ | インストール済み: | ||
+ | tigervnc-selinux-1.12.0-6.fc36.noarch | ||
+ | |||
+ | 完了しました! | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | 現在のファイヤウォールの内容を確認する🤔\\ | ||
+ | [[linux: | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | dhcpv6-client mdns samba-client ssh | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | vnc-server のファイヤウォール定義は以下のようになっている🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_code mincode>< | ||
+ | <?xml version=" | ||
+ | < | ||
+ | < | ||
+ | < | ||
+ | <port protocol=" | ||
+ | </ | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ファイヤウォールに vnc-server の設定を行う🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | success | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ファイヤウォール設定を有効化するためにリロードする🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | success | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | 設定が適用されていることを確認する🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | dhcpv6-client mdns samba-client ssh vnc-server | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | VNC 接続時に適用されるデフォルト設定を行う(例: | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | session=gnome | ||
+ | geometry=1366x768 | ||
+ | EOF | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | session=gnome | ||
+ | geometry=1366x768 | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | 画面番号 :1 のログインユーザーを設定する(例: | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | :1=tomoyan | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | VNC 接続時パスワードを設定する(この設定を行わないとサービスが起動出来ない)🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | Password: | ||
+ | Verify: | ||
+ | Would you like to enter a view-only password (y/n)? n | ||
+ | A view-only password is not used | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | vnc-server サービスの有効化と起動を行い、正常に起動することを確認する😀\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | <b class=GRN> | ||
+ | | ||
+ | | ||
+ | Process: 2756 ExecStartPre=/ | ||
+ | Process: 2768 ExecStart=/ | ||
+ | Main PID: 2775 (vncsession) | ||
+ | Tasks: 0 (limit: 19016) | ||
+ | | ||
+ | CPU: 38ms | ||
+ | | ||
+ | | ||
+ | |||
+ | 10月 07 10:26:31 WICKED-BEAT systemd[1]: Starting vncserver@: | ||
+ | 10月 07 10:26:31 WICKED-BEAT systemd[1]: Started vncserver@: | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | ==== Remmina で実際に接続確認を行う ==== | ||
+ | [[linux: | ||
+ | {{: | ||
+ | |||
+ | ==== vncserver が起動しない場合...😥 ==== | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | <WRAP color_result>< | ||
+ | <b class=GRN> | ||
+ | | ||
+ | | ||
+ | | ||
+ | Process: 3001 ExecStartPre=/ | ||
+ | Process: 3010 ExecStart=/ | ||
+ | Main PID: 3017 (code=exited, | ||
+ | CPU: 56ms | ||
+ | |||
+ | 3月 04 16:24:57 highway-x.fireball.local systemd[1]: Starting vncserver@: | ||
+ | 3月 04 16:24:57 highway-x.fireball.local systemd[1]: Started vncserver@: | ||
+ | 3月 04 16:24:58 highway-x.fireball.local systemd[1]: vncserver@: | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | vnc パスワードの設定をしていない可能性があるので設定する🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | Password: | ||
+ | Verify: | ||
+ | Would you like to enter a view-only password (y/n)? n | ||
+ | A view-only password is not used | ||
+ | </ | ||
+ | </ | ||
+ | |||
+ | vncserver を起動し直してステータスを確認する🤔\\ | ||
+ | <WRAP color_term> | ||
+ | <WRAP color_command>< | ||
+ | <b class=GRN> | ||
+ | <b class=GRN> | ||
+ | </ | ||
+ | <WRAP color_result>< | ||
+ | <b class=GRN> | ||
+ | | ||
+ | | ||
+ | Process: 3220 ExecStartPre=/ | ||
+ | Process: 3232 ExecStart=/ | ||
+ | Main PID: 3239 (vncsession) | ||
+ | Tasks: 0 (limit: 9402) | ||
+ | | ||
+ | CPU: 67ms | ||
+ | | ||
+ | ‣ 3239 / | ||
+ | |||
+ | 3月 04 16:31:50 highway-x.fireball.local systemd[1]: Starting vncserver@: | ||
+ | 3月 04 16:31:50 highway-x.fireball.local systemd[1]: Started vncserver@: | ||
+ | </ | ||
+ | </ | ||
===== Xvnc の設定(xinetd 編) ===== | ===== Xvnc の設定(xinetd 編) ===== | ||
行 17: | 行 249: | ||
- リモートデスクトップ(vnc)のパッケージをインストールする。\\ **CentOS**< | - リモートデスクトップ(vnc)のパッケージをインストールする。\\ **CentOS**< | ||
$ sudo yum install vnc vnc-server | $ sudo yum install vnc vnc-server | ||
- | </ | + | </ |
+ | <WRAP color_command>< | ||
$ sudo yum install tigervnc-server-minimal | $ sudo yum install tigervnc-server-minimal | ||
- | </code> | + | </pre></ |
+ | <WRAP color_result>< | ||
+ | メタデータの期限切れの最終確認: | ||
+ | パッケージ tigervnc-server-minimal-1.12.0-6.fc36.x86_64 は既にインストールされています。 | ||
+ | 依存関係が解決しました。 | ||
+ | 行うべきことはありません。 | ||
+ | 完了しました! | ||
+ | </ | ||
+ | </ | ||
==== 設定と反映 ==== | ==== 設定と反映 ==== | ||
- サービスのポートを指定するために、以下の設定ファイルを修正する。(行追加)\\ < | - サービスのポートを指定するために、以下の設定ファイルを修正する。(行追加)\\ < | ||
行 230: | 行 472: | ||
$ sudo firewall-cmd --reload | $ sudo firewall-cmd --reload | ||
</ | </ | ||
- | ==== 参考文献 ==== | + | |
- | [[http:// | + | |
- | [[http:// | + | |
- | [[http:// | + | |
- | [[http:// | + | |
- | [[http:// | + | |
===== VNCサーバの設定(vncserver サービス編) ===== | ===== VNCサーバの設定(vncserver サービス編) ===== | ||
この方法では、ユーザー1人につきポート5901より1ポートを消費します。また、VNCSERVERARGSの定義数が増えるとメモリーを多く消費します。\\ | この方法では、ユーザー1人につきポート5901より1ポートを消費します。また、VNCSERVERARGSの定義数が増えるとメモリーを多く消費します。\\ | ||
行 307: | 行 544: | ||
... | ... | ||
</ | </ | ||
+ | |||
+ | ===== 参考文献 ===== | ||
+ | [[https:// | ||
+ | [[https:// | ||
+ | [[qita> | ||
+ | [[http:// | ||
+ | [[http:// | ||
+ | [[http:// | ||
+ | [[http:// | ||
+ | [[http:// | ||
+ |