LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   unable to use some command when telnet in (https://www.linuxquestions.org/questions/linux-newbie-8/unable-to-use-some-command-when-telnet-in-162729/)

chongluo 03-26-2004 03:59 PM

unable to use some command when telnet in
 
i boot up my comuter into shell prompt, and i'm only able to issue commands like shutdown, useradd/adduser, which are located in /sbin, /usr/sbin on the local machine

But when I telnet to that computer, and i'm not allowed to issue those command, unless with /sbin/shutdown etc....

I know if I put some code in /etc/profile or /etc/bashrc will make it work, but still don't understand why i can use it on local machines, but not when i telnet

please help,

trickykid 03-26-2004 04:11 PM

You need to add /sbin to your users path. And why might I ask that your using telnet, its very insecure. Use ssh if your going to be doing some remote administration.

chongluo 03-26-2004 04:17 PM

Quote:

Originally posted by trickykid
You need to add /sbin to your users path. And why might I ask that your using telnet, its very insecure. Use ssh if your going to be doing some remote administration.
i know i can solve it if i add /sbin in my PATH, but I can use all these commands on my local machine without adding any PATH varibales. well I use ssh as well,

my question is why it is happenning? as I can issue all commands on local machine; but cann't issue some of these commands without adding a new PATH variable when I remotely login

tearinox 03-26-2004 10:12 PM

use ssh, its better

kdepa 03-27-2004 12:26 AM

Its probably happenning, because when you telnet in (bad idea to do, again use SSH) it doesnt read your .profile in your home directory...


All times are GMT -5. The time now is 06:34 PM.