Warning: Declaration of FeedWordPie_Item::get_id($hash = false) should be compatible with SimplePie_Item::get_id($hash = false, $fn = 'md5') in /home/nekyo/nekyo.wp.xdomain.jp/public_html/wp-content/plugins/feedwordpress/feedwordpie_item.class.php on line 0

Warning: Declaration of FeedWordPress_Parser::parse(&$data, $encoding) should be compatible with SimplePie_Parser::parse(&$data, $encoding, $url = '') in /home/nekyo/nekyo.wp.xdomain.jp/public_html/wp-content/plugins/feedwordpress/feedwordpress_parser.class.php on line 0
Raspberry pi にVNCサーバを入れる。 | 日々のできごと

Raspberry pi にVNCサーバを入れる。

VNCサーバをインストールして起動する。
[code lang=”bash”]
sudo apt-get install tightvncserver[/code]
[code lang=”bash”]tightvncserver[/code]
パスワードを聞かれるので入力する。

 

ブートスクリプトを作る。
sudo vi /etc/init.d/vncboot
[code lang=”bash”]
##
# BEGIN INIT INFO# Provides: vncboot
# Required-Start: $remote_fs $syslog
# Required-Stop: $remote_fs $syslog
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: Start VNC Server at boot time# Description: Start VNC Server at boot time.### END INIT INFO
#! /bin/sh
# /etc/init.d/vncbootUSER=piHOME=/home/piexport USER HOME
case “$1” in
start)
echo “Starting VNC Server”
#Insert your favoured settings for a VNC session
su $USER -c ‘/usr/bin/vncserver :1 -geometry 1600×900 -depth 24’
;;
stop)
echo “Stopping VNC Server”
su $USER -c ‘/usr/bin/vncserver -kill :1’
;;
*)
echo “Usage: /etc/init.d/vncboot {start|stop}”
exit 1
;;
esac
exit 0
[/code]
実行権限を与える。
[code lang=”bash”]chmod 755 /etc/init.d/vncboot[/code]
自動起動登録。
[code lang=”bash”]update-rc.d vncboot defaults[/code]
Windows用VNCクライアント(RealVNC Viewer)をインストールする。
接続する際のVNCサーバ名は、IPアドレス::5901 と指定して接続すれば画面が表示される。

自動起動登録できない場合

というエラーが出る場合は、初期インストールされているwolfram(プログラミング系と数学系のソフトウェアのパッケージ)の影響なので、簡単な対処法はアンインストールしてしまう。

VNC接続でエラー
デスクトップ(LXDE)を起動した際に GDBus.Error:org.freedesktop.PolicyKit1.Error.Failed: Cannot determine user of subject というエラーメッセージが表示された場合、以下を修正して vncserver を再起動してから再接続する。
/etc/xdg/autostart/lxpolkit.desktop


コメントを残す

メールアドレスが公開されることはありません。 * が付いている欄は必須項目です

CAPTCHA