Solaris / OpenSolarisThis forum is for the discussion of Solaris, OpenSolaris, OpenIndiana, and illumos.
General Sun, SunOS and Sparc related questions also go here. Any Solaris fork or distribution is welcome.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
When I use console port to config my server, I have some troubles with Vim editor. For example, the screen wasn't clear when I opened file. It also keep the old characters of the command prompt (like: #bash 3,0 --: .........) and the main content of this file is not shown out :-(. I have to move the cursor to see each line (can you imagine how xxx it is). And another trouble that is I can't use the backspace to delete character before cursor while i'm being in edit mode, I must press ESC and use X to delete, hix
I don't have these troubles when I use RedHat on my PC. What should I do to avoid them?
We only use the console port long enough to get a network connection. Then we ssh in with vt100 emulation to get work done. Console port is not fun to use.
Originally posted by jlliagre But vi works fine in the console, as long as you are using the right TERM environment variable, which seems to be the issue here.
That has not been my experience. TERM=vt100 + vt100 emulator results in the same as not doing any config
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789
Rep:
Okay, so you are complaining about issues when connecting to the Solaris box throuch the serial line ?
Of course in that case you have to set the TERM variable to what you emulator is faking.
If it doesn't works, you'd rather blame that emulator than Solaris, or find out what is going wrong in your process:
TERM not exported, escape sequences in the prompt messing the emulator, ...
Just get used to using vi blind
I usually cat the file out before editing and then use find in vi /or? to locate it and then replace it. Once I get done with the file I cat it out again to make sure it looks right.
As for the backspace in edit mode I think that's a vim feature and not supported with vi.
Like Brian said I use the serial connection long enough to get networking going then use a normal terminal.
Yeah, after I actived telnet and ssh, I don't use serial connection anymore. Vim works fine in telnet and ssh modes, but when I insert character (press "i"), it insert new character before the cussor. Can I make it insert after the cursor ?
Distribution: Solaris 11.4, Oracle Linux, Mint, Debian/WSL
Posts: 9,789
Rep:
You can erase the previous character with backspace when in edit mode under vi, provided these conditions are met:
- these characters were just added in the same insert session
- your emulator is really sending "backspace" when you hit the backspace key.
To check the latter, try erasing with [Ctrl-H] instead of [BackSpace], if only the first one works, blame you emulator, not vi.
"i" is inserting characters before the cursor as designed. If you want to 'insert after', also known as "append", use the "a" command instead of "i".
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.