tamipon’s diary

自分と家族の成長の記録

rasberry pi 固定IP設定メモ

下記サイトを参考に

 

deviceplus.jp

 

Raspbian(jessie)の固定IPアドレス設定方法

 

http://geisterhacker.com/index.php/2017/01/16/raspberry-pi3-tightvncserver/

 

relativelayout.hatenablog.com

 

vncbootは下記とおり

 

#! /bin/sh

### 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

# /etc/init.d/vncboot

# ログインするユーザーがpiの場合
USER=pi
HOME=/home/pi

export 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 1440x900 -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