anvd anvd - 2 years ago 71
Linux Question

CLI limited when doing login with a user created

In my VPS, I don't know why, but when I do a

to another user what I get is:

root@deb64:~# su john

The autocomplete with tab doesn't work, and even the command source. Example:

root@deb64:/home/john/myproject# source venv/bin/activate
(venv) root@deb64:/home/john/myproject#

root@deb64:/home/john/myproject# su john
$ cd /home/john/myproject
$ source venv/bin/activate
sh: 2: source: not found

What is happening with the command line?

Answer Source

You switching into a shell which does not have tab-completion (sh for instance). You can start bash or similar like this: exec bash. You can edit /etc/passwd if you wish to make this permanent.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download