Nextcloud resetting a lost admin password

Dohuginn

Dabbler
Joined
Nov 6, 2022
Messages
35
Hi
Please help, this command is not working
sudo -u www-data php /var/www/nextcloud/occ user:resetpassword admin
occ
root@truenas[~]# find / -name occ
/mnt/Urte/Nextcloud/html/occ
/mnt/Urte/ix-applications/docker/zfs/graph/4b44...ba596fde/usr/src/nextcloud/occ
/var/lib/kubelet/pods/a392d191..f823cf2f7/volume-subpaths/nextcloud-data/nextcloud/1/occ
I just started to get acquainted with Truenas Scale
 

SnoppyFloppy

Explorer
Joined
Jun 17, 2021
Messages
77
You provide very little information to go by.

1) How have you installed Nextcloud? In a VM or iX's or Truechart's Nextcloud container app?
2) If containerized, how are you entering the shell?

I run Truecharts Nextcloud and if I have to use occ comands i shell into it using heavy-script. From there I can run runuser --user www-data -- ./occ <command>
 

Dohuginn

Dabbler
Joined
Nov 6, 2022
Messages
35
Hello SnoppyFloppy. Thank you very much for the tip. I looked through some information and got
su -s /bin/bash -c 'php ./occ user:resetpassword admin' www-data
which led to the reset of the password. Thank you.
 
Top