running in debug mode and isolating the problem I saw that there is an issue with chown, and it also doesn’t work when I manually execute the failing command:
openhabian@openhabian:~ $ sudo chown --recursive backup:backup /storage/usbstick-msdos
chown: changing ownership of '/storage/usbstick-msdos': Operation not permitted
Note at this time there is no file yet in the folder, only should rename directory itself, see below for current owner and group:
openhabian@openhabian:/storage/usbstick-msdos $ ls -la
total 20
drwxr-xr-x 2 backup root 16384 Jan 1 1970 .
drwxr-xr-x 4 root root 4096 Feb 27 13:45 ..
One additional piece to the puzzle, the problem seems to be changing the group, since backup is owner already:
openhabian@openhabian:/storage/usbstick-msdos $ sudo chgrp --recursive backup /storage/usbstick-msdos
chgrp: changing group of '/storage/usbstick-msdos/misti': Operation not permitted
chgrp: changing group of '/storage/usbstick-msdos': Operation not permitted
group backup does exist…
After seeing a similar topic, I switched OpenHAB to main, still issue remains.
Any help is appreciated!
Thanks much
I run into the same issue with vfat.
I think it’s not possible to change the ownership because it’s vfat and it’s define in the fstab file.
adding gid=backup dit the trick for me. (and remount)
[16:48:45] root@openhabian:~# openhabian-config
2021-06-06_16:49:02_CEST [openHABian] Checking for root privileges... OK
2021-06-06_16:49:02_CEST [openHABian] Loading configuration file '/etc/openhabian.conf'... OK
2021-06-06_16:49:02_CEST [openHABian] openHABian configuration tool version: [openHAB3]{2021-05-05T15:53:37-06:00}(3e35b6d)
2021-06-06_16:49:02_CEST [openHABian] Checking for changes in origin branch openHAB3... OK
2021-06-06_16:49:04_CEST [openHABian] Switching to branch openHAB3... OK
2021-06-06_16:49:08_CEST [openHABian] Updating Linux package information... OK
2021-06-06_16:49:09_CEST [openHABian] Beginning setup of the Amanda backup system... OK
2021-06-06_16:49:11_CEST [openHABian] Configuring Amanda backup system prerequisites... 2021-06-06_16:49:22_CEST [openHABian] Configuring Amanda backup system prerequisites... OK
2021-06-06_16:49:45_CEST [openHABian] Creating Amanda filesystem... FAILED (chown)
2021-06-06_16:49:57_CEST [openHABian] Checking for default openHABian username:password combination... OK
2021-06-06_16:49:57_CEST [openHABian] We hope you got what you came for! See you again soon ;)
[16:49:57] root@openhabian:~# chown --recursive backup:backup /storage/usbstick
chown: changing ownership of '/storage/usbstick': Operation not permitted
[18:48:12] root@openhabian:~# vim /etc/fstab
[18:48:40] root@openhabian:~# chown --recursive backup:backup /storage/usbstick
chown: changing ownership of '/storage/usbstick': Operation not permitted
[18:48:42] root@openhabian:~# ls -ahl /storage/usbstick/
total 12K
drwxr-xr-x 2 backup root 8.0K Jan 1 1970 .
drwxr-xr-x 3 root root 4.0K Jun 6 16:28 ..
[18:49:09] root@openhabian:~# umount /storage/usbstick
[18:49:18] root@openhabian:~# mount /storage/usbstick/
[18:49:23] root@openhabian:~# ls -ahl /storage/usbstick/
total 12K
drwxr-xr-x 2 backup backup 8.0K Jan 1 1970 .
drwxr-xr-x 3 root root 4.0K Jun 6 16:28 ..
[18:49:25] root@openhabian:~# chown --recursive backup:backup /storage/usbstick
[18:49:33] root@openhabian:~# cat /etc/fstab
proc /proc proc defaults 0 0
PARTUUID=2801841c-01 /boot vfat defaults 0 2
PARTUUID=2801841c-02 / ext4 defaults,noatime 0 1
# a swapfile is not a swap partition, no line here
# use dphys-swapfile swap[on|off] for that
/dev/sda1 /storage/usbstick vfat noatime,noauto,user,uid=backup,gid=backup 0 1
[18:49:48] root@openhabian:~#