User Rating: 5 / 5

Star ActiveStar ActiveStar ActiveStar ActiveStar Active


Installing Domoticz on a Raspberry with Raspbian O/S is really simple:

  1. From a terminal/console logged as user pi, become superuser typing
    sudo su
  2. Execute the raspberry config program, to enable ssh service, 1wire and I2C bus, set IP address, .... and remember to change the password for pi user!

  3. Launch the installation script (directly from the domoticz website) that will update/install the required packages and download/install domoticz
    curl -sSL | sudo bash
  4. Select the installing directory /home/pi/domoticz and enable only HTTP port (default 8080)

Now, Domoticz is installed on /home/pi/domoticz and will be accessible from the web browser on the URL http://IP_ADDRESS:8080

How to extend flash memory life by writing log and tmp files on ramdisk


Backup RaspberryPI, Domoticz and other stuff on external USB hard disk, FTP server (NAS) and/or SMB/CIFS share

It's important to do frequent backup of raspberry, because SD flash disk is not so reliable! The proposed backup system create tar archives for each root directory, so it's easy to recover only what we really need. It performs a "daily backup" with only file changed in the last 24 hours, and a complete "weekly backup" with all files.
Also, it's possibile to set for how many days we have to keep daily backups (more than 7 days, if we have to recover specific version of a changed file), and how many weeks to keep weekly backups.

From root shell, on raspberry, execute the following commands

cd /tmp
rm backup_raspberry.tgz 2>/dev/null
tar xvzfp backup_raspberry.tgz -C /usr/local
chmod 700 /usr/local/sbin/
chmod 600 /usr/local/etc/backup.conf /usr/local/etc/backup.dir
echo -e "\n#make backup and export on USB hard disk, FTP NAS and/or SMB/CIFS share\n1 0 * * * root /usr/local/sbin/" >>/etc/crontab
if [ ! -x /usr/bin/mail ]; then
 #install smtp and mail client to send emails from shell
 apt install ssmtp mailutils
 echo -e "\n#Write here the user and password for SMTP server authentication\nAuthUser=This email address is being protected from spambots. You need JavaScript enabled to view it.\nAuthPass=password" >>/etc/ssmtp/ssmtp.conf
 echo "Press a key to edit ssmtp.conf inserting your smtp server configuration"; read x
 nano /etc/ssmtp/ssmtp.conf

Backup is pre-configured to export backup on a USB hard disk mounted on /mnt/usb :
please check /usr/local/etc/backup.dir to know which directories will be backupped, and /usr/local/etc/backup.conf to set backup parameters

Backup FAQ

For any questions, please check the web and/or write email to linux @ and we'll try to put the answer to your questions on this section.


Pin It