Solved

Cpu  "runaways"

Posted on 2002-06-25
4
307 Views
Last Modified: 2010-04-20
Since changing from SCO-UNIX to Linux, we noticed that it is easier to produce cpu "runaways". For example, if you start a telnet session to the server, then start the shell utility "top", then ungracefully exit top (by killing the telnet session)...the "top" process continues to run but in what appears to be a race condition (uses all available cpu). I can do this (runaway) also with our propietary app, but some apps/tools do not do this , like netconfig... The "runaways" appear to be pleasent ones, just consiming cpu as it is available (look nasty, but dont seem to load down the system).
0
Comment
Question by:medent
  • 2
  • 2
4 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 7108696
> .. look nasty, but dont seem to load down the system
And what is the question?

Probably your shell is configured to hangup background processes, see:
  bash: huponexit
  csh:  hup, nohup
  ksh:  nohup
  sh:   N/A :-)
  zsh:  NO_HUP
0
 

Author Comment

by:medent
ID: 7110249
That sure sounds like the answer, but it did not work.  I tried adding shopt -s huponexit to /etc/bashrc, and verified it was really on before starting the test app (netconfig). Perhaps huponexit is broke in bash?
Additional Info:
This problem I am having does not effect the root user, regardless of the shopt settings, only regular users and when I su to root (from a regular user).
0
 
LVL 51

Accepted Solution

by:
ahoffmann earned 300 total points
ID: 7111753
does root use bash?
do you do a  su root  or  su - root ?
0
 

Author Comment

by:medent
ID: 7113655
The problem was caused by having "trap" statement in the .bash_profile. The trap was part of a fu-fu to get an extra password to appear when a user was detected as a dialup modem. I will seek an alternative, and post a seperate question. I learned some valuable info from your input, Thank You .
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Setting up Secure Ubuntu server on VMware 1.      Insert the Ubuntu Server distribution CD or attach the ISO of the CD which is in the “Datastore”. Note that it is important to install the x64 edition on servers, not the X86 editions. 2.      Power on th…
Fine Tune your automatic Updates for Ubuntu / Debian
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Learn how to navigate the file tree with the shell. Use pwd to print the current working directory: Use ls to list a directory's contents: Use cd to change to a new directory: Use wildcards instead of typing out long directory names: Use ../ to move…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

23 Experts available now in Live!

Get 1:1 Help Now