Avatar of Los Angeles1
Los Angeles1
 asked on

AIX, delete key

In AIX, how do I disable the delete key from being recognized in command mode

(In other words, in the default AIX configuration, if you type a command, and hit the delete key a few times to delete a typo, the command processor apparently thinks the delete character is a character (instead of erasing the previous keystroke) )

How do I disable this feature ?

Thanks
Unix OS

Avatar of undefined
Last Comment
Los Angeles1

8/22/2022 - Mon
woolmilkporc

If you really mean the "delete" key ( <DEL> ) - this key does not work in a ksh terminal, and can't be forced to work and it is not possible either to keep this key from sending a character (mostly the tilde "~") to the screen.

Sorry, no better news.
Los Angeles1

ASKER
What about the 'backspace' key

(I am using skh)

# echo $0
-ksh
#

Open in new window

woolmilkporc

This depends on which terminal emulator you're using.

With PuTTY and ksh/AIX you should set the Backspace key to "Control-? (127)" in

"Configuration -> Keyboard -> Options controlling the effect of  keys"

and it should work.
Experts Exchange is like having an extremely knowledgeable team sitting and waiting for your call. Couldn't do my job half as well as I do without it!
James Murphy
Los Angeles1

ASKER
I am using Putty

VT100 emulation

Backspace set to Control 127

 Standard Home

Still have a problem
woolmilkporc

I always use Xterm R6 and Backspace works just fine. But vt100+ should work as well.

What exactly is your problem? What do you see with

termdef

?
Los Angeles1

ASKER
In this case I simply enter 'cd /home'

# cd /home
#

Open in new window


In this situation, I enter 'cd/home<backspace><backspace><backspace><backspace>home

# cd /home
ksh: /home^?^?^?^?home:  not found.

Open in new window

Get an unlimited membership to EE for less than $4 a week.
Unlimited question asking, solutions, articles and more.
woolmilkporc

Sorry,

I really can't reproduce your problem.

Please let's examine your setup.

Please post the results of

termdef

and

echo $TERM

and

stty

(the "erase" setting)

What exactly are your PuTTy settings for

Terminal -> Keyboard -> Backspace key ?

Terminal -> Keyboard -> Function  keys ?

Terminal -> Features -> Disable destructive backspace ? (should not be ticked)
sjm_ee

stty erase ^?

ie type "stty" a space "erase" another space then press backspace and then press return - that will set the command line to do "backspace" when you press "backspace".
woolmilkporc

Not quite, sjm_ee.

... type "stty" a space "erase" another space then a backslash "\" then press backspace and then press return ...

But it must work without having to run stty, that's why I keep asking for information about the current setup.
I started with Experts Exchange in 2004 and it's been a mainstay of my professional computing life since. It helped me launch a career as a programmer / Oracle data analyst
William Peck
Los Angeles1

ASKER
Here is the info:

# termdef
xterm
# echo $TERM
xterm

Open in new window


Finction Keys:  VT100
Backspace Key:  Control 127
Destructive backspace turned off (disabled)

The following does fix the problem:

stty + space + backspace + return

Open in new window

ASKER CERTIFIED SOLUTION
woolmilkporc

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
or
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question
Los Angeles1

ASKER
I tried it and it worked

Apparently Control H works better with VT100