NSLU2-Linux
view · edit · print · history

Optware.Nano History

Hide minor edits - Show changes to markup

December 28, 2009, at 06:49 AM by Jim DeLaHunt -- Rewrite the intro, some refactoring.
Changed lines 2-8 from:

The Nano editor is described at the nano site.

NOTE: Many people seem to experience the same problem I did - nano does not work after "ipkg install nano". I simply rebooted and everything worked fine! I did NOT need to follow any of the below, more complicated "solutions". I suggest rebooting first before reading any further. _________________________________________________________________________________________________________________________

Remark: Read the whole page (the first solution does not work)...

to:

The Nano editor is a simple, small, fairly easy to use text editor. It is generally considered an easier way to edit text configuration files than the vi editor included with the NSLU2, and lighter-weight than alternatives like emacs. Nano is described at the nano site.

Installation

Added lines 11-30:

Next, log out from your telnet/ssh session with the Slug, and log in again. If you do not do this, you may discover that your text display is garbled when you first start nano.

Troubleshooting and configuration

Like all full-screen text editors, nano needs to have some way of knowing how to tell your terminal (your telnet or ssh program) where to draw its text. Below are many approaches to configuring Nano so that it knows this.

One symptom of this configuration being wrong is that your text display is garbled when you first start nano. For instance, the lower case letters could display as box drawing characters, while upper case letters display correctly. If this happens to you, don't panic. Assume that the letters you type are interpreted correctly, even if they are displayed wrong. Use ^X to exit Nano, and proceed with troubleshooting.

Logging out, restarting NSLU

If you log out from your telnet/ssh session with the Slug, and log in again, this might be enough to configure Nano so that it draws text correctly. It will certainly solve the garbled text problem caused by a mis-configured Nano.

If logging out doesn't work, try restarting the NSLU2. This is a more extreme form of the state reset which logging out accomplishes.

Configure TERMINFO

The TERMINFO environment variable helps programs which display text understand how to tell your terminal (your telnet or ssh program) where to draw its text. If the above steps don't get this set automatically, you may have to set it manually.

NOTE: the solutions below are not in a very helpful order. Read the whole page (the first solution is reported not to work). If you can edit the page to make it more helpful, that would be wonderful. This is a wiki, after all.

May 18, 2007, at 09:59 PM by slyhne --
Changed lines 105-113 from:

ABE

to:

ABE

---

Using Ubuntu 7.04 I found that this works the best:

 export TERM=xterm

---

May 06, 2007, at 08:36 PM by abe --
Changed lines 103-105 from:

The function keys in mc are working perfectly now and nano works as it should too.

to:

The function keys in mc are working perfectly now and nano works as it should too.

ABE

May 04, 2007, at 11:19 PM by cyrxi --
Deleted lines 1-3:

Remark: Read the whole page (the first solution does not work)...

Added lines 4-8:

NOTE: Many people seem to experience the same problem I did - nano does not work after "ipkg install nano". I simply rebooted and everything worked fine! I did NOT need to follow any of the below, more complicated "solutions". I suggest rebooting first before reading any further. _________________________________________________________________________________________________________________________

Remark: Read the whole page (the first solution does not work)...

October 09, 2006, at 06:21 PM by Per-Einar Dahlen --
Changed lines 3-4 from:

Remark: Read the whole page...

to:

Remark: Read the whole page (the first solution does not work)...

October 09, 2006, at 06:20 PM by Per-Einar Dahlen --
Added lines 3-4:

Remark: Read the whole page...

September 11, 2006, at 08:02 PM by abe --
Added line 92:
September 11, 2006, at 08:01 PM by abe --
Changed lines 91-92 from:


to:

\\\

September 11, 2006, at 08:01 PM by abe --
Added line 87:

\\

Changed line 89 from:
to:

\\

Changed lines 91-98 from:

export PATH=$PATH:/opt/sbin:/opt/bin export TERMINFO=/opt/share/terminfo export TERM=linux

The keyboard-settings in PuTTy? are changed to 'linux' (instead of the default 'ESC[n~')

The function keys in mc are working perfectly now and nano works as it should too.

to:


 export PATH=$PATH:/opt/sbin:/opt/bin
 export TERMINFO=/opt/share/terminfo
 export TERM=linux

The keyboard-settings in PuTTy? are changed to 'linux' (instead of the default 'ESC[n~')

The function keys in mc are working perfectly now and nano works as it should too.

September 11, 2006, at 07:56 PM by abe -- working env 4 nano & mc
Changed lines 84-97 from:

I'm a newbie. I did everything to "export TERMINFO=/opt/share/terminfo" and it returned without error. I was a bit confused when nano didn't work after that but it works ok after a reboot.

to:

I'm a newbie. I did everything to "export TERMINFO=/opt/share/terminfo" and it returned without error. I was a bit confused when nano didn't work after that but it works ok after a reboot.

--- Hi, I just started using the NSLU2, but couldn't make thing work for me as described above. I have Unslung 6.8-beta and want to use nano and mc. After searching/reading/fiddling I have found the settings that work for me.

My /etc/profile looks like this:

export PATH=$PATH:/opt/sbin:/opt/bin export TERMINFO=/opt/share/terminfo export TERM=linux

The keyboard-settings in PuTTy? are changed to 'linux' (instead of the default 'ESC[n~')

The function keys in mc are working perfectly now and nano works as it should too.

July 01, 2006, at 12:49 PM by metamind -- reboot
Added lines 81-84:

---

I'm a newbie. I did everything to "export TERMINFO=/opt/share/terminfo" and it returned without error. I was a bit confused when nano didn't work after that but it works ok after a reboot.

March 16, 2006, at 02:18 AM by calvin --
Added lines 79-80:

vt100 wouldn't work for me, I had to use export TERM=dec-vt100. The toe command lists available terminals (i think).

January 11, 2006, at 07:20 AM by Phil Endecott -- Note that it shouldn\'t normally be necessary to change TERM
Added lines 68-78:

Of course, this all assumes that the terminal emulator that you're using is a vt100 or compatible. Which it might not be.

Your ssh client and server really should work this out and set TERM to something sensible for you. What was TERM set to (if anything) before you re-defined it? Perhaps it was set to something that isn't included in your terminfo database. In this case, changing it to something that is in your terminfo and is compatible is sensible. You can put conditional code in your /etc/profile or ~/.profile to do this:

case $TERM in linux|xterm|someweirdvt100comptabileterm) export TERM=vt100 ;;

  • ) # don't change TERM

esac

January 10, 2006, at 08:52 PM by Josh --
Added line 60:
Added line 62:
January 10, 2006, at 08:51 PM by Josh -- Updated info
Added lines 54-65:

This guy is on the right track. I used the following in my /etc/profile:

export TERMINFO=/opt/lib/terminfo export PATH=/sbin:/bin:/usr/sbin:/usr/bin:/opt/sbin:/opt/bin:/opt/sbin:/opt/bin export TERM=vt100

After a save and re-login, nano works perfectly.

October 23, 2005, at 01:58 AM by Kim Sandberg --
Changed lines 40-42 from:

Instead of setting the TERMINFO like this export TERMINFO=/opt/share/terminfo

to:

Instead of setting the TERMINFO like this export TERMINFO=/opt/share/terminfo

Added line 45:
Added line 48:
October 23, 2005, at 01:57 AM by Kim Sandberg --
Changed line 49 from:

Well on the the next adventure, the FTP server;-)

to:

Well on to the next adventure, the FTP server;-)

October 23, 2005, at 01:57 AM by Kim Sandberg --
Changed line 49 from:

;-)

to:

Well on the the next adventure, the FTP server;-)

October 23, 2005, at 01:55 AM by Kim Sandberg --
Changed lines 36-37 from:

I've searched everywhere for a solution being a total Linux newbie, but i was quite sure that somewhere in this strange OS there had to be some kind of boot files which got loaded. I couldn't find it, and no matter what i did, i wouldn't work.

to:

I've searched everywhere for a solution being a total Linux newbie, but i was quite sure that somewhere in this strange OS there had to be some kind of boot files which got loaded. I couldn't find them, and no matter what i did, it wouldn't work.

October 23, 2005, at 01:54 AM by Kim Sandberg --
Added lines 30-31:
October 23, 2005, at 01:53 AM by Kim Sandberg -- newbie solution
Changed lines 27-47 from:
 export TERM=vt100
to:
 export TERM=vt100

___________________________________________________________________________________________________________________ Unfortunately that didn't work for me.

Here comes a total newbie solution.

I've searched everywhere for a solution being a total Linux newbie, but i was quite sure that somewhere in this strange OS there had to be some kind of boot files which got loaded. I couldn't find it, and no matter what i did, i wouldn't work.

Then i stumbled on the Midnight Commander package, and saw another solution i hadn't seen before.

Instead of setting the TERMINFO like this export TERMINFO=/opt/share/terminfo it should be like this export TERMINFO=/opt/lib/terminfo

and dont forget the path export PATH=$PATH:/opt/sbin:/opt/bin

all that i put in a file called profile in the /etc library, i would rather put it in the /opt/etc library, so it wouldn't get erased in the situation that i upgrade firmware or something like that, but i can't get it to work.

Hope that helps you

;-)

January 08, 2005, at 08:37 AM by ka6sox --
Changed line 3 from:

The Nano editor is described at the http://www.nano-editor.org site.

to:

The Nano editor is described at the http://www.nano-editor.org nano site.

Added line 7:
Added line 11:
Added line 15:
Added line 17:
Added line 19:
Added line 21:
Changed lines 24-25 from:

You can place these variables in your /etc/profile

to:

You can place these variables in your /etc/profile:

January 08, 2005, at 03:08 AM by ByronT --
Changed lines 9-10 from:

You need to also set the TERMINFO variable to /opt/lib/terminfo

 export TERMINFO=/opt/lib/terminfo
to:

You need to also set the TERMINFO variable to /opt/share/terminfo

 export TERMINFO=/opt/share/terminfo
Changed line 19 from:
 export TERMINFO=/opt/lib/terminfo
to:
 export TERMINFO=/opt/share/terminfo
January 08, 2005, at 03:06 AM by ByronT --
Changed lines 9-10 from:

You need to also set the TERMINFO variable to /opt/share/terminfo

 export TERMINFO=/opt/share/terminfo
to:

You need to also set the TERMINFO variable to /opt/lib/terminfo

 export TERMINFO=/opt/lib/terminfo
Changed lines 18-22 from:

You can add these variables to your /unslung/rc.local

 export PATH=/opt/bin:/opt/sbin:$PATH
 export TERMINFO=/opt/share/terminfo
 export TERM=vt100
 return 1
to:

You can place these variables in your /etc/profile

 export TERMINFO=/opt/lib/terminfo
 export TERM=vt100
January 06, 2005, at 04:44 AM by ByronT --
Changed lines 14-15 from:

You haven't set your TERM variable.

to:
Another word in the place of "unknown" indicates that TERM is set incorrectly. Follow direction below.

Set your TERM variable:

December 20, 2004, at 07:30 PM by jake --
Changed lines 17-20 from:

You can add these variables to your /etc/profile

 PATH=/opt/bin:/opt/sbin:$PATH
 TERMINFO=/opt/share/terminfo
 TERM=vt100
to:

You can add these variables to your /unslung/rc.local

 export PATH=/opt/bin:/opt/sbin:$PATH
 export TERMINFO=/opt/share/terminfo
 export TERM=vt100
 return 1
December 20, 2004, at 07:19 PM by jake --
Changed lines 5-9 from:

Installation requires the ncurses package.

to:

Ipkg installer recognizes that it's dependant on ncurses package and will install it if system doesn't already contain ncurses.

 ipkg install nano
December 20, 2004, at 07:18 PM by jake --
Added line 12:
 export TERMINFO=/opt/share/terminfo
Added lines 14-22:

If you get:

 Error opening terminal: unknown.

You haven't set your TERM variable.

 export TERM=vt100

You can add these variables to your /etc/profile

 PATH=/opt/bin:/opt/sbin:$PATH
 TERMINFO=/opt/share/terminfo
 TERM=vt100
October 28, 2004, at 02:47 PM by wiredduns --
Added line 6:
Added line 8:
October 28, 2004, at 02:47 PM by wiredduns --
Added line 5:
Added line 7:
October 28, 2004, at 02:46 PM by wiredduns --
Changed lines 5-8 from:

Installation requires the ncurses package.

to:

Installation requires the ncurses package.

You need to also set the TERMINFO variable to /opt/share/terminfo

October 27, 2004, at 07:18 AM by wiredduns --
Changed lines 1-5 from:

Describe {{Nano}} here.

to:

Nano - Editor

The Nano editor is described at the http://www.nano-editor.org site.

Installation requires the ncurses package.

view · edit · print · history · Last edited by Jim DeLaHunt.
Based on work by slyhne, abe, cyrxi, Per-Einar Dahlen, metamind, calvin, Phil Endecott, Josh, Kim Sandberg, ka6sox, ByronT, jake, and wiredduns.
Originally by wiredduns.
Page last modified on December 28, 2009, at 06:49 AM