Testing auto backup

finally i found some the time to re-setup sd-mirroring…

++ whiptail --title 'Setup SD mirroring' --cancel-button Cancel --ok-button Select --menu '\nSelect USB device to copy t                                                                                                                     he internal SD card data to' 12 76 0 sda 29.7G sdb 1006M
+ retval=sda
+ [[ -z sda ]]
+ dest=/dev/sda
++ blockdev --getsize64 /dev/sda
+ [[ ! -n 31914983424 ]]
++ mount
++ grep /dev/sda
+ [[ -n '' ]]
+ infoText='DANGEROUS OPERATION, USE WITH PRECAUTION!\n\nThis will *copy* your system root from your SD card to a USB at                                                                                                                     tached card writer device. Are you sure /dev/sda is an SD card writer device equipped with a dispensible SD card? Are yo                                                                                                                     u sure, this will destroy all data on that card and you want to proceed writing to this device?'
++ blockdev --getsize64 /dev/mmcblk0
+ srcSize=15931539456
+ minSize=30269924966
++ blockdev --getsize64 /dev/sda
+ destSize=31914983424
+ [[ 31914983424 -lt 30269924966 ]]
+ [[ -n 1 ]]
+ whiptail --title 'Copy internal SD to /dev/sda' --yes-button Continue --no-button Back --yesno 'DANGEROUS OPERATION, U                                                                                                                     SE WITH PRECAUTION!\n\nThis will *copy* your system root from your SD card to a USB attached card writer device. Are you                                                                                                                      sure /dev/sda is an SD card writer device equipped with a dispensible SD card? Are you sure, this will destroy all data                                                                                                                      on that card and you want to proceed writing to this device?' 12 116
++ basename /storage
+ mountUnit=storage.mount
+ systemctl stop storage.mount
++ fdisk -l /dev/mmcblk0
++ head -1
++ cut '-d ' -f7
+ start=31116288
+ (( destSize-=start ))
+ sfdisk -d /dev/mmcblk0
+ sfdisk --force /dev/sda
+ echo '/dev/mmcblk0p3 : start=31116288,size=31883867136, type=83'
Checking that no-one is using this disk right now ... OK

Disk /dev/sda: 29.7 GiB, 31914983424 bytes, 62333952 sectors
Disk model: Card  Reader
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x6afa72a2

Old situation:

Device     Boot    Start      End  Sectors  Size Id Type
/dev/sda1           8192   532479   524288  256M  c W95 FAT32 (LBA)
/dev/sda2         532480 31116287 30583808 14.6G 83 Linux
/dev/sda3       31116288 62333951 31217664 14.9G 83 Linux

>>> Script header accepted.
>>> Script header accepted.
>>> Script header accepted.
>>> Script header accepted.
>>> Created a new DOS disklabel with disk identifier 0xb5915213.
/dev/sda1: Created a new partition 1 of type 'W95 FAT32 (LBA)' and of size 256 MiB.
Partition #1 contains a vfat signature.
/dev/sda2: Created a new partition 2 of type 'Linux' and of size 14.6 GiB.
Partition #2 contains a ext4 signature.
/dev/sda3: Created a new partition 3 of type 'Linux' and of size 14.9 GiB.
Partition #3 contains a ext4 signature.
/dev/sda4: Done.

New situation:
Disklabel type: dos
Disk identifier: 0xb5915213

Device     Boot    Start      End  Sectors  Size Id Type
/dev/sda1           8192   532479   524288  256M  c W95 FAT32 (LBA)
/dev/sda2         532480 31116287 30583808 14.6G 83 Linux
/dev/sda3       31116288 62333951 31217664 14.9G 83 Linux

The partition table has been altered.
Calling ioctl() to re-read partition table.
Syncing disks.
+ partprobe
+ cond_redirect mke2fs -F -t ext4 /dev/sda3
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ mke2fs -F -t ext4 /dev/sda3 \033[39;49;00m'

$ mke2fs -F -t ext4 /dev/sda3
+ mke2fs -F -t ext4 /dev/sda3
mke2fs 1.44.5 (15-Dec-2018)
/dev/sda3 contains a ext4 file system
        last mounted on Sun Oct  4 20:38:18 2020
Creating filesystem with 3902208 4k blocks and 977280 inodes
Filesystem UUID: 8d6f13fa-3d20-473e-956d-def41210f882
Superblock backups stored on blocks:
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208

Allocating group tables: done
Writing inode tables: done
Creating journal (16384 blocks): done
Writing superblocks and filesystem accounting information: done

+ return 0
+ mirror_SD raw /dev/sda
+ local src=/dev/mmcblk0
+ local dest=/dev/sda
+ local start
+ local storageDir=/storage
+ local syncMount=/storage/syncmount
+ local dirty=no
+ local 'dumpInfoText=For your information as the operator of this openHABian system:\nA timed background job to run sem                                                                                                                     iannually has just created a full raw device copy of your RPI'\''s internal SD card.\nOnly partitions to contain openHAB                                                                                                                     ian (/boot and / partitions 1 & 2) were copied.'
+ local partUUID
+ [[ /dev/mmcblk0 == \/\d\e\v\/\s\d\a ]]
++ blockdev --getsize64 /dev/sda
+ [[ -n 31914983424 ]]
++ mount
++ grep /dev/sda
+ [[ -n '' ]]
+ [[ ! -d /storage/syncmount ]]
+ [[ raw == \r\a\w ]]
+ for i in 1 2
++ blockdev --getsize64 /dev/mmcblk0p1
+ srcSize=268435456
++ blockdev --getsize64 /dev/sda1
+ destSize=268435456
+ [[ 268435456 -lt 268435456 ]]
+ for i in 1 2
++ blockdev --getsize64 /dev/mmcblk0p2
+ srcSize=15658909696
++ blockdev --getsize64 /dev/sda2
+ destSize=15658909696
+ [[ 15658909696 -lt 15658909696 ]]
+ echo 'Taking a raw partition copy, be prepared this may take long such as 20-30 minutes for a 16 GB SD card'
Taking a raw partition copy, be prepared this may take long such as 20-30 minutes for a 16 GB SD card
+ cond_redirect dd if=/dev/mmcblk0p1 bs=1M of=/dev/sda1 status=progress
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ dd if=/dev/mmcblk0p1 bs=1M of=/dev/sda1 status=progress \033[39;49;00m'

$ dd if=/dev/mmcblk0p1 bs=1M of=/dev/sda1 status=progress
+ dd if=/dev/mmcblk0p1 bs=1M of=/dev/sda1 status=progress
268435456 bytes (268 MB, 256 MiB) copied, 12 s, 22.4 MB/s
256+0 records in
256+0 records out
268435456 bytes (268 MB, 256 MiB) copied, 18.3414 s, 14.6 MB/s
+ return 0
+ cond_redirect dd if=/dev/mmcblk0p2 bs=1M of=/dev/sda2 status=progress
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ dd if=/dev/mmcblk0p2 bs=1M of=/dev/sda2 status=progress \033[39;49;00m'

$ dd if=/dev/mmcblk0p2 bs=1M of=/dev/sda2 status=progress
+ dd if=/dev/mmcblk0p2 bs=1M of=/dev/sda2 status=progress
15654191104 bytes (16 GB, 15 GiB) copied, 969 s, 16.2 MB/s
14933+1 records in
14933+1 records out
15658909696 bytes (16 GB, 15 GiB) copied, 978.411 s, 16.0 MB/s
+ return 0
++ blkid /dev/mmcblk0p2
++ sed -n 's|^.*PARTUUID="\(\S\+\)".*|\1|p'
++ sed -e s/-02//g
+ origPartUUID=d0c18a5b
++ yes
++ cond_redirect set-partuuid /dev/sda2 random
++ [[ -n '' ]]
++ echo -e '\n\033[90;01m$ set-partuuid /dev/sda2 random \033[39;49;00m'
++ set-partuuid /dev/sda2 random
++ awk '/^PARTUUID/ { print substr($7,1,length($7) - 3) }'
++ return 0
+ partUUID=67d80d57
+ cond_redirect tune2fs /dev/sda2 -U random
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ tune2fs /dev/sda2 -U random \033[39;49;00m'

$ tune2fs /dev/sda2 -U random
+ tune2fs /dev/sda2 -U random
tune2fs 1.44.5 (15-Dec-2018)
+ return 0
+ mount /dev/sda1 /storage/syncmount
+ sed -i 's|d0c18a5b|67d80d57|g' /storage/syncmount/cmdline.txt
+ umount /storage/syncmount
+ mount /dev/sda2 /storage/syncmount
+ sed -i 's|d0c18a5b|67d80d57|g' /storage/syncmount/etc/fstab
+ sed -i 's|^What=.*|What=/dev/mmcblk0p3|g' /storage/syncmount/etc/systemd/system//storage.mount
+ umount /storage/syncmount
+ cond_redirect fsck -y -t ext4 /dev/sda2
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ fsck -y -t ext4 /dev/sda2 \033[39;49;00m'

$ fsck -y -t ext4 /dev/sda2
+ fsck -y -t ext4 /dev/sda2
fsck from util-linux 2.33.1
e2fsck 1.44.5 (15-Dec-2018)
rootfs: clean, 74101/936000 files, 1470734/3822976 blocks
+ return 0
+ [[ no == \n\o ]]
+ echo OK
OK
+ echo -e 'For your information as the operator of this openHABian system:\nA timed background job to run semiannually h                                                                                                                     as just created a full raw device copy of your RPI'\''s internal SD card.\nOnly partitions to contain openHABian (/boot                                                                                                                      and / partitions 1 & 2) were copied.'
+ mail -s 'SD card raw copy dump' ''
mail: No recipients specified
+ return 0
+ sed -e 's|%DEVICE|/dev/sda3|g' -e 's|%STORAGE|/storage|g' /opt/openhabian/includes/storage.mount
+ cond_redirect systemctl enable --now storage.mount
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ systemctl enable --now storage.mount \033[39;49;00m'

$ systemctl enable --now storage.mount
+ systemctl enable --now storage.mount
+ return 0
+ sed -e 's|%DEST|/dev/sda|g' /opt/openhabian/includes/sdrawcopy.service_template
+ sed -e 's|%DEST|/dev/sda|g' /opt/openhabian/includes/sdrsync.service_template
+ cond_redirect cp /opt/openhabian/includes/sdrawcopy.timer /opt/openhabian/includes/sdrsync.timer /etc/systemd/system//
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ cp /opt/openhabian/includes/sdrawcopy.timer /opt/openhabian/includes/sdrsync.timer /etc/system                                                                                                                     d/system// \033[39;49;00m'

$ cp /opt/openhabian/includes/sdrawcopy.timer /opt/openhabian/includes/sdrsync.timer /etc/systemd/system//
+ cp /opt/openhabian/includes/sdrawcopy.timer /opt/openhabian/includes/sdrsync.timer /etc/systemd/system//
+ return 0
+ echo OK
OK
+ cond_redirect install -m 755 /opt/openhabian/includes/mirror_SD /usr/local/sbin
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ install -m 755 /opt/openhabian/includes/mirror_SD /usr/local/sbin \033[39;49;00m'

$ install -m 755 /opt/openhabian/includes/mirror_SD /usr/local/sbin
+ install -m 755 /opt/openhabian/includes/mirror_SD /usr/local/sbin
+ return 0
+ cond_redirect systemctl -q daemon-reload
+ cond_redirect systemctl enable --now sdrawcopy.timer sdrsync.timer
+ [[ -n '' ]]
+ echo -e '\n\033[90;01m$ systemctl enable --now sdrawcopy.timer sdrsync.timer \033[39;49;00m'

$ systemctl enable --now sdrawcopy.timer sdrsync.timer
+ systemctl enable --now sdrawcopy.timer sdrsync.timer
+ return 0
+ echo OK
OK
+ [[ -z 1 ]]
+ '[' 0 -ne 0 ']'
+ true
+ show_main_menu
+++ get_git_revision
+++ local branch
+++ local latestTag
+++ local revCount
+++ local shorthash
++++ git -C /opt/openhabian rev-parse --abbrev-ref HEAD
+++ branch=master
++++ git -C /opt/openhabian describe --tags --abbrev=0
+++ latestTag=v1.6
++++ git -C /opt/openhabian log --oneline
++++ wc -l
+++ revCount=879
++++ git -C /opt/openhabian log --pretty=format:%h -n 1
+++ shorthash=c25239d
+++ echo '[master]v1.6-879(c25239d)'
++ whiptail --title 'Welcome to the openHABian Configuration Tool [master]v1.6-879(c25239d)' --menu 'Setup Options' 18 1                                                                                                                     16 11 --cancel-button Exit --ok-button Execute '00 | About openHABian' 'Information about the openHABian project and thi                                                                                                                     s tool' '' '' '01 | Select Branch' 'Select the openHABian config tool version ("branch") to run' '02 | Upgrade System' '                                                                                                                     Upgrade all installed software packages (incl. openHAB) to their latest version' '03 | openHAB Stable' 'Install or upgra                                                                                                                     de to the latest stable release of openHAB 2' '' '' '10 | Apply Improvements' 'Apply the latest improvements to the basi                                                                                                                     c openHABian setup ►' '20 | Optional Components' 'Choose from a set of optional software components ►' '30 | System Sett                                                                                                                     ings' 'A range of system and hardware related configuration steps ►' '40 | openHAB related' 'Switch the installed openHA                                                                                                                     B version or apply tweaks ►' '50 | Backup/Restore' 'Manage backups and restore your system ►'
+ choice=
+ RET=1
+ '[' 1 -eq 1 ']'
+ return 255
+ system_check_default_password
+ is_pi
+ is_pizero
+ [[ '' == \p\i\0 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]09[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pizerow
+ [[ '' == \p\i\0\w ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[cC][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pione
+ [[ '' == \p\i\1 ]]
+ grep -q '^Revision\s*:\s*00[0-9a-fA-F][0-9a-fA-F]$' /proc/cpuinfo
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[0-36][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmone
+ [[ '' == \c\m\1 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]06[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pitwo
+ [[ '' == \p\i\2 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]04[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithree
+ [[ '' == \p\i\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]08[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthree
+ [[ '' == \c\m\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[aA][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithreeplus
+ [[ '' == \p\i\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[dDeE][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthreeplus
+ [[ '' == \c\m\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]10[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pifour
+ [[ '' == \p\i\4 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo
+ return 0
+ return 0
+ local algo
+ local defaultPassword
+ local defaultUser
+ local generatedPassword
+ local introText
+ local originalPassword
+ local salt
+ is_pi
+ is_pizero
+ [[ '' == \p\i\0 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]09[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pizerow
+ [[ '' == \p\i\0\w ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[cC][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pione
+ [[ '' == \p\i\1 ]]
+ grep -q '^Revision\s*:\s*00[0-9a-fA-F][0-9a-fA-F]$' /proc/cpuinfo
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[0-36][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmone
+ [[ '' == \c\m\1 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]06[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pitwo
+ [[ '' == \p\i\2 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]04[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithree
+ [[ '' == \p\i\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]08[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthree
+ [[ '' == \c\m\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[aA][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithreeplus
+ [[ '' == \p\i\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[dDeE][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthreeplus
+ [[ '' == \c\m\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]10[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pifour
+ [[ '' == \p\i\4 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo
+ return 0
+ return 0
+ id -u pi
+ is_pi
+ is_pizero
+ [[ '' == \p\i\0 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]09[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pizerow
+ [[ '' == \p\i\0\w ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[cC][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pione
+ [[ '' == \p\i\1 ]]
+ grep -q '^Revision\s*:\s*00[0-9a-fA-F][0-9a-fA-F]$' /proc/cpuinfo
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[0-36][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmone
+ [[ '' == \c\m\1 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]06[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pitwo
+ [[ '' == \p\i\2 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]04[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithree
+ [[ '' == \p\i\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]08[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthree
+ [[ '' == \c\m\3 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[aA][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pithreeplus
+ [[ '' == \p\i\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]0[dDeE][0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_cmthreeplus
+ [[ '' == \c\m\3\+ ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]10[0-9a-fA-F]$' /proc/cpuinfo
+ return 1
+ is_pifour
+ [[ '' == \p\i\4 ]]
+ grep -q '^Revision\s*:\s*[ 123][0-9a-fA-F][0-9a-fA-F][0-9a-fA-F]11[0-9a-fA-F]$' /proc/cpuinfo
+ return 0
+ return 0
+ defaultUser=openhabian
+ defaultPassword=openhabian
++ grep -w openhabian /etc/shadow
++ cut -d: -f2
+ originalPassword='$6$Oa2jE7q9LCf2pwQg$CLetQr8dlemHVGxr9.wbHNvBb6ka.UdH.8usMFy8XpTqxGP15mVAkART3WMCVWhNCWoGU7kJFpwyuyp1                                                                                                                     EpmpQ1'
++ echo '$6$Oa2jE7q9LCf2pwQg$CLetQr8dlemHVGxr9.wbHNvBb6ka.UdH.8usMFy8XpTqxGP15mVAkART3WMCVWhNCWoGU7kJFpwyuyp1EpmpQ1'
++ cut '-d$' -f2
+ algo=6
+ introText='The default password was detected on your system! That is a serious security concern. Bad guys or malicious                                                                                                                      programs in your subnet are able to gain root access!\n\nPlease set a strong password by typing the command '\''passwd                                                                                                                      openhabian'\''!'
++ echo '$6$Oa2jE7q9LCf2pwQg$CLetQr8dlemHVGxr9.wbHNvBb6ka.UdH.8usMFy8XpTqxGP15mVAkART3WMCVWhNCWoGU7kJFpwyuyp1EpmpQ1'
++ cut '-d$' -f3
+ salt=Oa2jE7q9LCf2pwQg
+ export algo defaultPassword salt
++ perl -le 'print crypt("$ENV{defaultPassword}","\$$ENV{algo}\$$ENV{salt}\$")'
+ generatedPassword='$6$Oa2jE7q9LCf2pwQg$9HTAmBlN7dLelML.38m4zn0c87LbiBI6xQjDcD5xAeCDQQuMxeD6a3ueqs8x2w13Kogedhqd.gVsgbQ                                                                                                                     96lNM71'
++ timestamp
++ date +%F_%T_%Z
+ echo -n '2020-10-04_21:21:26_CEST [openHABian] Checking for default openHABian username:password combination... '
2020-10-04_21:21:26_CEST [openHABian] Checking for default openHABian username:password combination... ++ id -u openhabi                                                                                                                     an
+ [[ -n 1000 ]]
+ [[ $6$Oa2jE7q9LCf2pwQg$9HTAmBlN7dLelML.38m4zn0c87LbiBI6xQjDcD5xAeCDQQuMxeD6a3ueqs8x2w13Kogedhqd.gVsgbQ96lNM71 == \$\6\                                                                                                                     $\O\a\2\j\E\7\q\9\L\C\f\2\p\w\Q\g\$\C\L\e\t\Q\r\8\d\l\e\m\H\V\G\x\r\9\.\w\b\H\N\v\B\b\6\k\a\.\U\d\H\.\8\u\s\M\F\y\8\X\p\                                                                                                                     T\q\x\G\P\1\5\m\V\A\k\A\R\T\3\W\M\C\V\W\h\N\C\W\o\G\U\7\k\J\F\p\w\y\u\y\p\1\E\p\m\p\Q\1 ]]
+ echo OK
OK
++ timestamp
++ date +%F_%T_%Z
+ echo -e '2020-10-04_21:21:26_CEST [openHABian] We hope you got what you came for! See you again soon ;)'
2020-10-04_21:21:26_CEST [openHABian] We hope you got what you came for! See you again soon ;)
+ cd /home/openhabian

i don’t see any errors, so it should be okay to proceed with amanda, right?

I’d think so. You don’t have to put it on that third partition but you can, of course.

I set up the auto backup with 53.. and it looks like it worked.


Taking a raw partition copy, be prepared this may take long such as 20-30 minutes for a 16 GB SD card
OK
OK
OK

Is there a way or command how I can check when the last copy to the Backup SD was done?
I just want to make sure I set it up correctly and the backups are done in the background.

you should see when the script was executed last time with this:

probably you won’t see if everything went smooth :slight_smile:

This is what I get, I think these two are the ones I am looking for:

Sat 2021-01-16 02:00:00 CET 4 days left n/a n/a sdrsync.timer
Thu 2021-07-01 01:15:00 CEST 5 months 18 days left n/a n/a sdrawcopy.timer

They got both a “n/a” at LAST and PASSED.

So? It this what it should be?