Link to home
Create AccountLog in
Unix OS

Unix OS

--

Questions

--

Followers

Top Experts

Avatar of KhalidJ
KhalidJ🇬🇧

AIX - Running SMIT on Putty
I am new to AIX 5.2.  I need to do a simple task such as mount a CD ROM using SMIT.  Everytime I try to run smit command it says that a TERM variable needs to be set.  Can anyone help?  Many thanks

Zero AI Policy

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.


Avatar of gheistgheist🇧🇪

And what is your TERM variable set to?

Avatar of KhalidJKhalidJ🇬🇧

ASKER

i am totally new to AIX, do I find out by running the env command on ksh?

Avatar of gheistgheist🇧🇪

echo $TERM

Reward 1Reward 2Reward 3Reward 4Reward 5Reward 6

EARN REWARDS FOR ASKING, ANSWERING, AND MORE.

Earn free swag for participating on the platform.


Avatar of KhalidJKhalidJ🇬🇧

ASKER

dumb

Avatar of gheistgheist🇧🇪

eval `tset -sQ \?$TERM`

then enter smitty and set your default terminal type to whatever TSET offered.

Avatar of sjm_eesjm_ee🇬🇧

Run the following:

TERM=xterm
export TERM

Then try smitty. You can automate this in your .profile. You can also force putty to send a terminal type to the telnet server, but it sends it in uppercase so you can code your .profile to change the value of TERM to lower case or by checking for a specific value of term as in the attached code snippet, assuming that ksh is your login shell.
TERM=`echo $TERM | tr [A-Z] [a-z]`
 
or
 
if [ "$TERM" = "XTERM ]
then
        TERM=xterm
fi

Open in new window


Free T-shirt

Get a FREE t-shirt when you ask your first question.

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.


Avatar of sjm_eesjm_ee🇬🇧

PS Set the term type string to send in putty -> configuration -> connection -> term-type string to "xterm".

Avatar of sjm_eesjm_ee🇬🇧

I made a mistake in the snippet above.
if [ "$TERM" = "XTERM" ]
then
        TERM=xterm
fi

Open in new window


Avatar of sjm_eesjm_ee🇬🇧

And if F3 doesn't work on smitty, check to see that putty -> configuration -> terminal -> keyboard -> function keys is set to ESC[n~.

Purists like me would prefer to write our own terminfo definition but putty doesn't seem to support 8-bit characters to eliminate the ESC in the function key codes and this needs root to install up to AIX 5.3 and whatever RBAC is necessary under AIX 6 and later.

Reward 1Reward 2Reward 3Reward 4Reward 5Reward 6

EARN REWARDS FOR ASKING, ANSWERING, AND MORE.

Earn free swag for participating on the platform.


Avatar of gheistgheist🇧🇪

What are you talking about? AIX uses termcap, not terminfo.

ASKER CERTIFIED SOLUTION
Avatar of sjm_eesjm_ee🇬🇧

Link to home
membership
Log in or create a free account to see answer.
Signing up is free and takes 30 seconds. No credit card required.
Create Account

SOLUTION
Avatar of gheistgheist🇧🇪

Link to home
membership
Log in or create a free account to see answer.
Signing up is free and takes 30 seconds. No credit card required.

Avatar of sjm_eesjm_ee🇬🇧

Well gheist the question was actually about smitty ... have you tried running smitty with a TERM valid in TERMCAP and not in TERMINFO or it's default? I have.

Avatar of gheistgheist🇧🇪

Smit runs awk etc behind interface, and some oldish cr.p may still lie down there. Its assumption that helps.

Free T-shirt

Get a FREE t-shirt when you ask your first question.

We believe in human intelligence. Our moderation policy strictly prohibits the use of LLM content in our Q&A threads.

Unix OS

Unix OS

--

Questions

--

Followers

Top Experts

Unix is a multitasking, multi-user computer operating system originally developed in 1969 at Bell Labs. Today, it is a modern OS with many commercial flavors and licensees, including FreeBSD, Hewlett-Packard’s UX, IBM AIX and Apple Mac OS-X. Apart from its command-line interface, most UNIX variations support the standardized X Window System for GUIs, with the exception of the Mac OS, which uses a proprietary system.