Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[SOLVED] cant edit files via ssh from suckless terminal
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
vcmota
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2017
Posts: 131

PostPosted: Mon Feb 05, 2018 5:32 pm    Post subject: [SOLVED] cant edit files via ssh from suckless terminal Reply with quote

I have a recent gentoo install and for the first time I needed to access and edit some files located in another machine which I can only access via ssh. I can connect perfectly via ssh and locate the files, but when I try to open them I get the following error


Code:

vinicius@mossadegh ~ $ ssh jack@servidorbom
jack@servidorbom's password:
Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 4.4.0-57-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

300 packages can be updated.
233 updates are security updates.

Your Hardware Enablement Stack (HWE) is supported until April 2019.
Last login: Mon Feb  5 15:13:03 2018 from 182.40.77.777
vinicius@wkst15:~$ cd hco/c-ho/
vinicius@wkst15:~/hco/c-ho$ vi c-ho.5z.mrci.allelectron.0.1.4324.Cs.inp

E558: Terminal entry not found in terminfo
'st-256color' not known. Available builtin terminals are:
    builtin_ansi
    builtin_xterm
    builtin_iris-ansi
    builtin_dumb
defaulting to 'ansi'


I suspected that this could be something related with the fact that I am using st terminal, and so I installed xfce4-terminal. And in fact everything works fine from xfce4-terminal: I can connect via ssh, locate and edit the files flawlessly. So why is that I cannot do those things via st terminal? I get no errors at all when compiling either st terminal or dwm, and all patches that I have regarding st terminal have also been compiled flawlessly. I first thought that it could be a missing patch, something that I needed to install to enable such functionality, but there is nothing like that in the upstream webpage here. Thank you all.
[/code]


Last edited by vcmota on Mon Feb 05, 2018 6:57 pm; edited 1 time in total
Back to top
View user's profile Send private message
eccerr0r
Watchman
Watchman


Joined: 01 Jul 2004
Posts: 7048
Location: almost Mile High in the USA

PostPosted: Mon Feb 05, 2018 6:00 pm    Post subject: Reply with quote

Despite the 'uniformity' of un*x, there are so many flavors and versions out there, and this is one of those problems.

One fix: upgrade or upgrade to ncurses on the remote machine. Chances are this is impossible.
Another fix: change st such that it doesn't set the TERM to custom values. This is likely also ugly.

You can easily work around this problem by manually setting TERM=ansi or TERM=xterm just after ssh'ing into that machine. You can do it before too if you want, but it would affect your working setup albeit it should still work just fine.
_________________
Intel Core i7 2700K@ 4.1GHz/HD3000 graphics/8GB DDR3/180GB SSD
What am I supposed watching?
Back to top
View user's profile Send private message
vcmota
Tux's lil' helper
Tux's lil' helper


Joined: 19 Jun 2017
Posts: 131

PostPosted: Mon Feb 05, 2018 6:57 pm    Post subject: Reply with quote

Thank you eccerr0r for your reply.


Code:

You can easily work around this problem by manually setting TERM=ansi or TERM=xterm just after ssh'ing into that machine.


Yes, that worked just fine!

Code:

One fix: upgrade or upgrade to ncurses on the remote machine. Chances are this is impossible.


There is some hope since I know personally the admin. Also, since your reply I started to suspect it is all due to a lack of whole system update on the remote machine, since this is show up just after login via ssh:

Code:

Welcome to Ubuntu 14.04.5 LTS (GNU/Linux 4.4.0-57-generic x86_64)

 * Documentation:  https://help.ubuntu.com/

300 packages can be updated.
233 updates are security updates.



Thank you again!
Back to top
View user's profile Send private message
Ant P.
Watchman
Watchman


Joined: 18 Apr 2009
Posts: 5588

PostPosted: Tue Feb 06, 2018 6:51 pm    Post subject: Reply with quote

Another option would be to scp /usr/share/terminfo/s/st-256color over. That should work better, since st has slightly abnormal escape strings for some keys.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum