Page 1 of 1

root is not getting admin password.

Posted: 19 Jun 2021, 05:08
by penright
The subject basically says the issue. I am trying to clean up an owncloud and when I try to delete the owncloud folder, I do not have permission. Also, I can not sudo.

I have read a lot about "root access" from ssh. I see the root password should be the same as admin, is that correct? So for ssh should I be using root and the admin password? If so then when I try to ssh with and log in with root and admin password is like the password is wrong.

So, as I said, what should I do to get root access so I can remove the owncloud directory, so I can do a fresh install?

Re: root is not getting admin password.

Posted: 19 Jun 2021, 09:59
by TMS
First log in with the administrator, and then sudo -i to switch the root user, the password is the administrator password.

Re: root is not getting admin password.

Posted: 20 Jun 2021, 04:51
by mossholderm
I'm experiencing the same issue after updating to 4.2.13. Worse yet, both su and sudo seem to have their permissions set incorrectly:

(admin@filer01) Password:
Welcome to Tnas!
[admin@filer01 ~]$ ls -l /bin/su
lrwxrwxrwx 1 root root 7 Nov 25 2019 /bin/su -> busybox
[admin@filer01 ~]$ su -
su: must be suid to work properly
[admin@filer01 ~]$ sudo -i
sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set
[admin@filer01 ~]$ ls -l /usr/bin/sudo
-rwxr-xr-x 1 root root 139248 Jun 17 13:59 /usr/bin/sudo

Re: root is not getting admin password.

Posted: 20 Jun 2021, 11:41
by TMS
What is your device model?

Re: root is not getting admin password.

Posted: 21 Jun 2021, 10:32
by mossholderm
U4-111

Re: root is not getting admin password.

Posted: 21 Jun 2021, 15:29
by TMS
sudo: /usr/bin/sudo must be owned by uid 0 and have the setuid bit set
The following steps are the solution:
1. Turn off the device and turn it on without any hard disks
and TNAS PC found the device.
2. Log in as root, password admin(IP+9222)
3. After logging in to the background, insert all hard disks and enter the following command
ls /dev/sd*
4. After seeing the hard disk information, execute the command
/etc/tos/scripts/mntcore
chmod 4755 /mnt/core/usr/bin/sudo
5. Then enter reboot.