Hi all,
I have 3-4 years of experience working on unix environment. I am not a beginner, but unix is not my primary skill set. I am very good at awk programming and doing many of my tasks very well, really very weak on basics. I moved to a new job recently and the settings there are driving me nuts. Following are my questions:
1) Who decides what shell would be default when we login to unix enviroment? Is there any way we can overide it?
2) I am currently using korn shell and i was using the same shell in my old job, but i am not able to mimic mostly of the usual commands and functionality at my new environment. The things that are driving me nuts is :
not able to use arrows on command line , gives me garbage
escape \ to get the command history
autocomplete the filenames
when i use the vi editor, it does even tell me which mode i am in, when i press insert it changes the case of the text
not able to use page up and page down to scroll through scripts
Many other things. they are very basic but i am so used to all these settings , it is literally driving me nuts. Can someone help me what settings need to be done?
Also some one can point to some books/documentation to understand the basics about shells and the settings and different editors how and when to use it would really help me a lot ! Thanks in advance .
What operating system were you using before? What operating system are you using now? What output do you get from the command?:
uname -a
How is the TERM environment variable set? What locale are you using? What are you using as a terminal or terminal emulator when logging in to your current system? What output do you get from the command?:
env
What shell settings are you using in the Korn shell? What output do you get from the command?:
set -o
If you can show us the output from the above requested command on your current system, it will help. If you can also show us the output from the above commands on your previous system, it will help us see things that are different between the two systems.
set -o
allexport off
braceexpand on
emacs off
errexit off
errtrace off
functrace off
hashall on
histexpand on
history on
ignoreeof off
interactive-comments on
keyword off
monitor on
noclobber off
noexec off
noglob off
nolog off
notify off
nounset off
onecmd off
physical off
pipefail off
posix off
privileged off
verbose off
vi on
xtrace off
---------- Post updated at 10:22 PM ---------- Previous update was at 10:12 PM ----------
New Job:
uname -a
SunOS infaetldev01 5.10 Generic_150400-23 sun4v sparc sun4v
set -o
Current option settings
allexport off
bgnice on
emacs off
errexit off
gmacs off
ignoreeof off
interactive on
keyword off
markdirs off
monitor on
noexec off
noclobber off
noglob off
nolog off
notify off
nounset off
privileged off
restricted off
trackall off
verbose off
vi on
viraw off
xtrace off
Interactive features like braceexpand and histexpand only exist in pdksh (optional on Linux) and ksh93 (Solaris 11).
But you have got ksh88 on Solaris 10.
Regarding command history, get comfortable with the fc command! (I never did.)
You can also do "which bash". I supported Solaris. The person who I worked with really wanted to use tcsh, and I would rather use bash. So every time I connected to a server, I needed to type bash to get the bash shell. Then I could maintain a .bashrc file to set preferences the way that I wanted them to be. This should work for you as well. There are plenty of sample .bashrc files on the web.