boot in lubuntu
in the pi home dir, there is a shell script to
copy image to SD + apt update & apt upgrade then reboot
$ dd if=2021-05-07-raspios-buster-armhf.img of=/dev/sdc bs=4M conv=fsync status=progress
open ssh + install nomachine
custom.sh
alias l='ls -lhX --group-directories-first' alias ssh='ssh -o ServerAliveInterval=100 -Y' alias cp='cp --preserve=xattr' # PATH export PATH=$PATH:~/bin # PROMPT if [ "$EUID" == "0" ]; then export PSUSERCOL=1 else export PSUSERCOL=2 fi export PS1="$(tput -Txterm-256color bold ; tput -Txterm-256color setaf $PSUSERCOL)### $(tput -Txterm-256color setaf 7)\d \A $(tput -Txterm-256color setaf $PSUSERCOL)\u $(tput -Txterm-256color setaf 3)\H $(tput -Txterm-256color setaf 2)\w $(tput -Txterm-256color sgr0)\n\$ "
install & configure ispy in ~/ispyconnect https://www.ispyconnect.com/download.aspx
working!
as a service, edit AgentDVR.service
[Unit] Description=AgentDVR [Service] # see https://www.ispyconnect.com/userguide-agent-service.aspx for instructions # systemd will run this executable to start the service. AGENT_LOCATION needs to be the absolute path # DOT_NET_LOCATION should point to where the dotnet executable is - this might be different on your computer. # For Raspberry Pi YOUR_USERNAME is usually pi # # eg for Raspberry Pi: ExecStart=/usr/share/dotnet/dotnet /home/pi/Desktop/Agent/Agent.dll # eg for Linux: ExecStart=/usr/bin/dotnet /home/sean/Desktop/Agent/Agent.dll ExecStart=/home/pi/ispyconnect/dotnet/dotnet /home/pi/ispyconnect/Agent.dll # to query logs using journalctl, set a logical name here SyslogIdentifier=AgentDVR # Use your username to keep things simple. # If you pick a different user, make sure dotnet and all permissions are set correctly to run the app # To update permissions, use 'chown YOUR_USERNAME -R AGENT_LOCATION' to take ownership of the folder and files User=pi # ensure the service automatically restarts Restart=always # amount of time to wait before restarting the service RestartSec=5 [Install] WantedBy=multi-user.target
copy image to SD
$ dd if=2021-05-07-raspios-buster-armhf.img of=/dev/sdc bs=4M conv=fsync status=progress
Downloaded piOS.
@inagua: generate passwordless keys names pi4e.id_rsa
ssh-keygen -f pi4e.id_rsa
append pi4e.id_rsa.pub to pi@pi4e:.ssh/authorized_keys
scp .ssh/pi4e.id_rsa.pub pi@pi4e:.ssh/ ssh pi@pi4e cat .ssh/pi4e.id_rsa.pub >> .ssh/authorized_keys'
install raspbian https://www.raspberrypi.org/downloads/ start and small config (wifi, keyboard, ssh)
sudo apt-get update sudo apt-get dist-upgrade sudo apt-get install -y rpi-chromium-mods sudo apt-get install -y python-sense-emu python3-sense-emu python-sense-emu-doc
@pi change server params: unix → vnc user, add admin user
sudo apt-get install sshfs autofs
added to
/sshfs /etc/auto.sshfs uid=1000,gid=1000,--timeout=30,--ghost
created
pendejo -fstype=fuse,rw,nodev,nonempty,noatime,allow_other,max_read=65536 :sshfs\#user@server\:/path/to/
created public/private key on pi with no password, and copied private to root@pi
ssh-keygen -t rsa
added public key to user@server:.ssh/authorized_keys2
sudo systemctl restart autofs
debugging:
sudo service autofs stop sudo automount -f -v
install motion
sudo apt-get install motion
edit /etc/motion/motion.conf
:
daemon on output_pictures off ffmpeg_output_movies off stream_quality 75 stream_localhost off stream_authentication username:password webcontrol_authentication username:password
redirect port 24/8080 26/8081
sudo systemctl restart motion sudo systemctl status motion
sudo apt-get install iotop sudo apt-get install iftop sudo apt-get install sysstat