su or sudo "command not found"
-
- Getting the hang of things
- Posts: 65
- Joined: Sun Mar 06, 2011 5:40 pm
su or sudo "command not found"
Hi,
Trying to do "su - admin" or "sudo", and I got "command not found".
Is there some env parameters that I need to set?
[~] # su - admin
-sh: su: command not found
[~] # sudo
-sh: sudo: command not found
[~] #
Thanks in advance.
Trying to do "su - admin" or "sudo", and I got "command not found".
Is there some env parameters that I need to set?
[~] # su - admin
-sh: su: command not found
[~] # sudo
-sh: sudo: command not found
[~] #
Thanks in advance.
- forkless
- Experience counts
- Posts: 1907
- Joined: Mon Nov 23, 2009 6:52 am
- Location: The Netherlands
Re: su or sudo "command not found"
Your 'admin' user is uid 0 (root)
-
- Getting the hang of things
- Posts: 65
- Joined: Sun Mar 06, 2011 5:40 pm
Re: su or sudo "command not found"
Hi Forkless,
Thanks for replying. How about "sudo" command? it's said it's not found.
Thanks for replying. How about "sudo" command? it's said it's not found.
- pwilson
- Guru
- Posts: 22533
- Joined: Fri Mar 06, 2009 11:20 am
- Location: Victoria, BC, Canada (UTC-08:00)
Re: su or sudo "command not found"
Sudo is not part of the Firmware image. It never was.rogsf wrote:Hi Forkless,
Thanks for replying. How about "sudo" command? it's said it's not found.
You can install "sudo" via both Optware and Entware.
Patrick M. Wilson
Victoria, BC Canada
QNAP TS-470 Pro w/ 4 * Western Digital WD30EFRX WD Reds (RAID5) - - Single 8.1TB Storage Pool FW: QTS 4.2.0 Build 20151023 - Kali Linux v1.06 (64bit)
Forums: View My Profile - Search My Posts - View My Photo - View My Location - Top Community Posters
QNAP: Turbo NAS User Manual - QNAP Wiki - QNAP Tutorials - QNAP FAQs
Please review: When you're asking a question, please include the following.
- schumaku
- Guru
- Posts: 43579
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: su or sudo "command not found"
..to su from admin uid:0 or sudo to admin uid:0 ... ? If login using admin you are already admin (uid:0 .. elsewhere named root).
- pwilson
- Guru
- Posts: 22533
- Joined: Fri Mar 06, 2009 11:20 am
- Location: Victoria, BC, Canada (UTC-08:00)
Re: su or sudo "command not found"
as evidenced with:schumaku wrote:..to su from admin uid:0 or sudo to admin uid:0 ... ? If login using admin you are already admin (uid:0 .. elsewhere named root).
Code: Select all
/usr/bin/id -a
uid=0(admin) gid=0(administrators) groups=0(administrators),100(everyone),1012(kvm),1013(libvirtd)
Patrick M. Wilson
Victoria, BC Canada
QNAP TS-470 Pro w/ 4 * Western Digital WD30EFRX WD Reds (RAID5) - - Single 8.1TB Storage Pool FW: QTS 4.2.0 Build 20151023 - Kali Linux v1.06 (64bit)
Forums: View My Profile - Search My Posts - View My Photo - View My Location - Top Community Posters
QNAP: Turbo NAS User Manual - QNAP Wiki - QNAP Tutorials - QNAP FAQs
Please review: When you're asking a question, please include the following.
-
- Getting the hang of things
- Posts: 65
- Joined: Sun Mar 06, 2011 5:40 pm
Re: su or sudo "command not found"
Thanks Patrick and schumaku for your help
-
- New here
- Posts: 5
- Joined: Thu Feb 28, 2013 8:24 pm
Re: su or sudo "command not found"
Found this one while looking for a solution to the same problem.
In case you want to su to another user in your NAS for whatever reason (i.e. run a cron job with that user in that user's home etc.); an alternative is to install coreutils package:
Cheers,
Erdem
In case you want to su to another user in your NAS for whatever reason (i.e. run a cron job with that user in that user's home etc.); an alternative is to install coreutils package:
Code: Select all
ipkg update ; ipkg install coreutils
Cheers,
Erdem
- spamkutu
- Know my way around
- Posts: 112
- Joined: Sun Aug 09, 2015 4:09 pm
Re: su or sudo "command not found"
What is Entware and how to install please and also Optware in Qnap..pwilson wrote:You can install "sudo" via both Optware and Entware.
Model name: TVS-EC-1080 + 24GB RAM
Firmware version: 4.1.4 20150910 stable
Operation System (OS): Windows XP/7/8.1/2012SR2 ; Slackware 14.1
Number of HDDs: 8 Segate NAS ST4000VN000-1H4168 ; 4TB each ; First 4 in Raid 5 , Next 4 in Raid 5
Services enabled: DDNS, NFS, SMB, SSH, SysLog, LDAP, Photo, Music, File and Download Station
NAS connection speed/ MTU: 1Gbps / 1500
Firmware version: 4.1.4 20150910 stable
Operation System (OS): Windows XP/7/8.1/2012SR2 ; Slackware 14.1
Number of HDDs: 8 Segate NAS ST4000VN000-1H4168 ; 4TB each ; First 4 in Raid 5 , Next 4 in Raid 5
Services enabled: DDNS, NFS, SMB, SSH, SysLog, LDAP, Photo, Music, File and Download Station
NAS connection speed/ MTU: 1Gbps / 1500
- dolbyman
- Guru
- Posts: 35249
- Joined: Sat Feb 12, 2011 2:11 am
- Location: Vancouver BC , Canada
- schumaku
- Guru
- Posts: 43579
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: su or sudo "command not found"
For Entware, start here -> http://forum.qnap.com/viewtopic.php?f=3 ... &start=135
Optware is an obsolete package manager, much more incomplete.
But ey, what for you need sudo if there is no login for any users different from admin anyway? Better don't expose the non-default OpenSSH sshd to the Internet - seriously...
Optware is an obsolete package manager, much more incomplete.
But ey, what for you need sudo if there is no login for any users different from admin anyway? Better don't expose the non-default OpenSSH sshd to the Internet - seriously...
- spamkutu
- Know my way around
- Posts: 112
- Joined: Sun Aug 09, 2015 4:09 pm
Re: su or sudo "command not found"
Maybe he could disable default admin and put to another users as a substitute a sudoers to fear somethings corrupt.schumaku wrote:
But ey, what for you need sudo if there is no login for any users different from admin anyway? Better don't expose the non-default OpenSSH sshd to the Internet - seriously...
Model name: TVS-EC-1080 + 24GB RAM
Firmware version: 4.1.4 20150910 stable
Operation System (OS): Windows XP/7/8.1/2012SR2 ; Slackware 14.1
Number of HDDs: 8 Segate NAS ST4000VN000-1H4168 ; 4TB each ; First 4 in Raid 5 , Next 4 in Raid 5
Services enabled: DDNS, NFS, SMB, SSH, SysLog, LDAP, Photo, Music, File and Download Station
NAS connection speed/ MTU: 1Gbps / 1500
Firmware version: 4.1.4 20150910 stable
Operation System (OS): Windows XP/7/8.1/2012SR2 ; Slackware 14.1
Number of HDDs: 8 Segate NAS ST4000VN000-1H4168 ; 4TB each ; First 4 in Raid 5 , Next 4 in Raid 5
Services enabled: DDNS, NFS, SMB, SSH, SysLog, LDAP, Photo, Music, File and Download Station
NAS connection speed/ MTU: 1Gbps / 1500
-
- New here
- Posts: 5
- Joined: Tue Dec 16, 2014 12:17 am
Re: su or sudo "command not found"
I know very little. Statement.
I apparently need the command sudo to get a beta weather program called cumulus to work on my QNAP 212P NAS. I have winscp and putty programs and copied cumulus files to /usr/bin/CumuluxMX folder. I need to run mono (already installed via qpkg) and cumulusmx.exe and told to type
sudo mono CumulusMX.exe
There is no version of Outward for qnap that I can find and entware looks very complicated to get on to the qnap. I need very simple instructions on how to install sudo .
Can anyone help?
David
I apparently need the command sudo to get a beta weather program called cumulus to work on my QNAP 212P NAS. I have winscp and putty programs and copied cumulus files to /usr/bin/CumuluxMX folder. I need to run mono (already installed via qpkg) and cumulusmx.exe and told to type
sudo mono CumulusMX.exe
There is no version of Outward for qnap that I can find and entware looks very complicated to get on to the qnap. I need very simple instructions on how to install sudo .
Can anyone help?
David
- schumaku
- Guru
- Posts: 43579
- Joined: Mon Jan 21, 2008 4:41 pm
- Location: Kloten (Zurich), Switzerland -- Skype: schumaku
- Contact:
Re: su or sudo "command not found"
Hi David,
Appears a pre-requirement for CumulusMX is the availability of Mono. To keep the story short - here the part applicable to U**x-derivatives, to the QNAP NAS in general, and your TS-212 in special.
- sudo is a program for U**x-like computer operating systems that allows users to run programs with the security privileges of another user, by default the user with hte uid:0, often named root.
- On the QNAP NAS, admin _is_ running as uid:0 - so no need for sudo.
- QNAP does offer Mono for x86 based (Intel, AMD) NAS models only - either form the App Center, or form the community builds -> http://forum.qnap.com/viewtopic.php?f=2 ... 46#p477383
To conclude (your?) thread here ... http://sandaysoft.com/forum/viewtopic.php?f=27&t=14232 ... the problem is not sudo ... much more mono. And then the fact that QNAP does not add each and every binary path to the path variable, and you might have to call the binary by using it's relative or full path. But that's beyond of the scope here.
Last ... just "blindy" using copy or move commands workable on generic U*x platforms will cause issues on an embedded system as we have here on the QNAP NAS. I'm shuddering to read about ideas of copy a what is supposed to be a Web application to /root or to /usr/bin ...
Regards,
-Kurt.
Appears a pre-requirement for CumulusMX is the availability of Mono. To keep the story short - here the part applicable to U**x-derivatives, to the QNAP NAS in general, and your TS-212 in special.
- sudo is a program for U**x-like computer operating systems that allows users to run programs with the security privileges of another user, by default the user with hte uid:0, often named root.
- On the QNAP NAS, admin _is_ running as uid:0 - so no need for sudo.
- QNAP does offer Mono for x86 based (Intel, AMD) NAS models only - either form the App Center, or form the community builds -> http://forum.qnap.com/viewtopic.php?f=2 ... 46#p477383
To conclude (your?) thread here ... http://sandaysoft.com/forum/viewtopic.php?f=27&t=14232 ... the problem is not sudo ... much more mono. And then the fact that QNAP does not add each and every binary path to the path variable, and you might have to call the binary by using it's relative or full path. But that's beyond of the scope here.
Last ... just "blindy" using copy or move commands workable on generic U*x platforms will cause issues on an embedded system as we have here on the QNAP NAS. I'm shuddering to read about ideas of copy a what is supposed to be a Web application to /root or to /usr/bin ...
Regards,
-Kurt.
-
- New here
- Posts: 5
- Joined: Tue Dec 16, 2014 12:17 am
Re: su or sudo "command not found"
Ah..... time to give up and perhaps dig out my old HP ProLiant microserver (runs on windows home server).
Many thanks for your full and understandable explanation.
Regards. David.
Many thanks for your full and understandable explanation.
Regards. David.