- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Ctrl+C problem
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-15-2008 11:53 PM
тАО05-15-2008 11:53 PM
#stty -a
speed 9600 baud; rows 25; columns 80; line = 0;
intr = ^C; quit = ^\; erase = ^H; kill = ^U; eof = ^D; eol =
eol2 =
lnext = ^V; flush = ^O; min = 1; time = 0;
-parenb -parodd cs8 -hupcl -cstopb cread -clocal -crtscts
-ignbrk -brkint -ignpar -parmrk -inpck -istrip -inlcr -igncr icrnl ixon -ixoff
-iuclc -ixany -imaxbel
opost -olcuc -ocrnl onlcr -onocr -onlret -ofill -ofdel nl0 cr0 tab0 bs0 vt0 ff0
isig icanon iexten echo echoe echok -echonl -noflsh -xcase -tostop -echoprt
echoctl echoke
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-16-2008 12:58 AM
тАО05-16-2008 12:58 AM
Re: Ctrl+C problem
what kind of shell does your general user use?
Robert-Jan
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-16-2008 01:24 AM
тАО05-16-2008 01:24 AM
Re: Ctrl+C problem
thx
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-16-2008 03:09 AM
тАО05-16-2008 03:09 AM
Re: Ctrl+C problem
Why don't you use a real shell to see if cntl-C works at all? (ksh or sh)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-16-2008 06:26 AM
тАО05-16-2008 06:26 AM
SolutionThis does not describe the system very well.
> bash
This does not describe the shell very well.
> [...] general user can't use it
This does not describe the problem very well.
Ctrl/C seems to work as expected on my local
system (PA-RISC, 11.11, bash 3.2 (I
believe)), and on a TestDrive system like
td176.testdrive.hp.com (IA64, 11.23, "GNU
bash, version 3.00.14(1)-release
(ia64-hp-hpux11.23)").
td176> stty -a
speed 9600 baud; line = 0;
rows = 24; columns = 80
min = 4; time = 0;
intr = ^C; quit = ^\; erase = DEL; kill = ^U
eof = ^D; eol = ^@; eol2
stop = ^S; start = ^Q; susp = ^Z; dsusp = ^Y
werase
parenb -parodd cs7 -cstopb hupcl -cread -clocal -loblk -crts
-ignbrk brkint ignpar -parmrk -inpck istrip -inlcr -igncr icrnl -iuclc
ixon -ixany -ixoff -imaxbel -rtsxoff -ctsxon -ienqak
isig icanon -iexten -xcase echo echoe echok -echonl -noflsh
-echoctl -echoprt -echoke -flusho -pendin
opost -olcuc onlcr -ocrnl -onocr -onlret -ofill -ofdel -tostop tab3
It might also help to know where you're
sitting (HP-UX workstation, Windows box with
some mal-configured terminal emulator, a
real VT220, ...), how you're connected, and
what you're doing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-18-2008 11:54 PM
тАО05-18-2008 11:54 PM
Re: Ctrl+C problem
Try commenting out the "trap" commands in
/etc/profile
I never fully understood why in should help but it did !!?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-20-2008 02:29 AM
тАО05-20-2008 02:29 AM
Re: Ctrl+C problem
I tried to remark the line " trap 1 2 3" in /etc/profile , it works, can advise what is the function of this line ? if disable it , what is the impact ?
thx
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-20-2008 03:08 AM
тАО05-20-2008 03:08 AM
Re: Ctrl+C problem
When signals 1, 2 or 3 are issued, it goes to the commands in the trap command. If none, the signal is ignored.
Typically in a real shell, the trap commands in /etc/profile are ignored after the shell is set up. If you remove it, it is possible to break out of the commands that /etc/profile is executing.
You may want to just reset the traps at the end of the script:
trap - 1 2 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-20-2008 11:38 PM
тАО05-20-2008 11:38 PM
Re: Ctrl+C problem
trap - 1 2 3
A similar statement is at the end of my /etc/profile:
# Leave defaults in user environment.
trap 1 2 3