Issue in Linux Command

Hi,
:wall:
I am not able to run any utility command in Redat, Please see the below example and suggest me how I shall run this type of command.

[Pradipta@localhost ~]$ su
Password: 
[root@localhost Pradipta]# ifconfig
bash: ifconfig: command not found
[root@localhost Pradipta]# which ifconfig
/usr/bin/which: no ifconfig in (/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin:/home/Pradipta/bin)

I can see that " no ifconfig " when I fired the which command for ifconfig. Advance thanks for helping.

Any command, or just ifconfig? ifconfig in RHEL is in /sbin, and that's maybe just not in your PATH.

Try switching to root by

su -

Yes. Adding the dash (-) invokes the environment of the user, which contains their PATH variables. Otherwise, if it is not in the path of the user that used su, then you do not get their PATH.