LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 08-25-2016, 11:54 AM   #1
rocaflqu
LQ Newbie
 
Registered: Jun 2016
Posts: 11

Rep: Reputation: Disabled
Command Error in SSH connection


Hi guys,

I have problem when use clear command in ssh connection with chroot, example
i create test user and jail in /home/test, and use the next command:

- cp -v /usr/bin/clear /home/test/bin
- l2chroot /home/test/bin/clear

ssh test@server.com
test# clear
'xterm-256color': unknown terminal type.

But use the same way for ls, grep, find, and work fine.

Note: in server command clear work fine.

Please help me. Thanks guys.
 
Old 08-25-2016, 01:19 PM   #2
HMW
Member
 
Registered: Aug 2013
Location: Sweden
Distribution: Debian, Arch, Red Hat, CentOS
Posts: 773
Blog Entries: 3

Rep: Reputation: 369Reputation: 369Reputation: 369Reputation: 369
Try this:
Code:
export TERM=xterm
In your ssh session.

Best regards,
HMW

Last edited by HMW; 08-25-2016 at 01:21 PM.
 
Old 08-25-2016, 01:28 PM   #3
rocaflqu
LQ Newbie
 
Registered: Jun 2016
Posts: 11

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by HMW View Post
Try this:
Code:
export TERM=xterm
In your ssh session.

Best regards,
HMW
Yes i try, but the error change to 'xterm': unknown terminal type.

Thanks.
 
Old 08-25-2016, 03:31 PM   #4
rocaflqu
LQ Newbie
 
Registered: Jun 2016
Posts: 11

Original Poster
Rep: Reputation: Disabled
Hi guys;

I solved, thanks for your helps anyway

Solution:

cp -v /user/share/terminfo/x/xterm-256color /home/test/usr/share/terminfo/x/xterm-256color

Regards.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
error in connection of ssh nivetha Linux - Server 1 08-02-2011 11:34 AM
ssh connection error nima0102 Linux - Server 2 04-11-2010 02:33 PM
ssh error connection refused immortaltechnique Linux - Software 4 07-25-2008 02:52 AM
Possible to call a client side command from a script on server, via SSH connection. a2brute Linux - Networking 7 04-07-2008 12:11 PM
SSH Connection Error stellabinich Linux - Networking 4 07-29-2005 09:22 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 03:09 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration