OK so I fully admit that I am new to administrating Open Solaris but I had been a user of it back in Solaris 8 days. Since I wanted to build a ZFS NAS server I figured that Open Solaris would be be a better platform choice over FreeBSD.
Anyway - I've been having a humdinger of a time getting into the groove here admin wise and its frustrating me completely.
I've got a couple of questions:
- Am I loosing my mind or is Open Solaris seem overly complex? I haven't had to deal with any #3 in years...
- Should I switch to FreeBSD for simplicity?
- How do I setup the term so that it properly works with remote logins from my Windows (putty) and Linux boxes?
- Specifically, vim gets no colors unless TERM=xtermc which according to the community is not a bug (HA). Is there some standard way to setup the .bashrc/.profile script to consistently fix term colors?
- A standard way to fix special keys like del, pgup, pgdn, end etc. which don't work in any remote terms but also don't work on Open Solaris's own install of gnome-terminal.
- Are there some software (from 3rd party repos or opensolaris's) which help with these problems?
Please keep in mind that the reason this is important is because this is a headless server with primary administration via ssh and thus it is important to me that the shell terminal work correctly from all of the places I login from, preferably without needing special client-side settings. Ideally fixes would go in a shell script / bash script / whatever executed on account login.
I ran into the same frustrations when I started using OpenSolaris. I was able to fix most of the terminal problems by installing screen.
pfexec pkg install SUNWscreen
I would love to hear other peoples solutions to this problem though.
adding the following to /etc/profile does the trick with HOME, END, DEL keys (and maybe more things):
thoughts: I guess temporarily setting the TERM to screen sets some additional things that aren't overridden when setting back the original term (at least for me. I'm connecting using xterm (putty's default)). even though i consider this luck, i actually like this solution as it means not messing with inputrc file(s).
tested on snv_127 (OpenSolaris) and a fresh install of oi_147 (OpenIndiana)
(btw: thx for the answers suggesting screen, it's what led me to testing around until i got to this)
For those Linux Admins just moving to Solaris don't forget to add:
to your ~/.profile so it actually reads your bash configurations.
OpenSolaris is really the cutting-edge version of Solaris. It's definitely got some rough edges. I tend to stick to the real Solaris to avoid those issues. Even there, the x86 version of Solaris doesn't feel quite as polished as the SPARC version.
I've never tried to setup colors for the terminal (and haven't encountered keyboard weirdness anywhere other than the system console), so I'm only commenting on general items/feel.
OK, its been a while since I wrote this question, but I think I've come to enough of a solution to post something comprehensive... Most of this info comes from 3dinfluence so please up vote his answer too.
The first thing you'll want to do is grab this inputrc file from this blog. I put this file in /etc/inputrc, and then modified /etc/profile to
export INPUTRC="/etc/inputrc"
.I also then created
/etc/bash.bashrc
in which I added a number of my normal bashrc items such asexport HISTCONTROL=ignoreboth
, etc.To fix vim it was a larger pain in the butt in that your only real solution was to recompile it by hand, or use a 3rd party solaris-repo like blastwave. The simplest solution I could come to was to alias vim in /etc/bash.bashrc with
alias vim='TERM=xterm-color vim'
.Using screen also solves vim's color problems, if you don't mind using screen.