Set up TTL on process


 
Thread Tools Search this Thread
Operating Systems Solaris Set up TTL on process
# 1  
Old 09-24-2010
Set up TTL on process

Is there a way to setup the TTL (Time To Live) on a process. We have many ssh processes that seem to just stack up. These processes do not need a static connection all the time and it might cause problems on our servers. Does anybody know how to setup the TTL on a process?
# 2  
Old 09-24-2010
There is "ulimit -t" but it uses CPU time, not clock time. Using it is however likely a wrong approach. You might first try understanding why these ssh processes do stack up in the first place.
This User Gave Thanks to jlliagre For This Post:
# 3  
Old 09-27-2010
I'm new to Solaris, how do I setup the "ulimit -t"?
# 4  
Old 09-27-2010
"ulimit -t" is not Solaris specific. You set it that way:

Code:
$ ulimit -t 60

That would mean the process cannot exceed 1 minute of CPU time.

Note that it affects the shell where you set it and all its children processes.
# 5  
Old 09-28-2010
This would affect all processes? Is there a way to just affect one process?
# 6  
Old 09-28-2010
I didn't wrote that would affect all processes, only the shell where you set it and its own children processes. Another clarification: the limit is per process, not shared.
# 7  
Old 09-28-2010
I'm a little confused. I need to set the value for just ssh processes in the shell. How would I do that?
Login or Register to Ask a Question

Previous Thread | Next Thread

9 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Htop process viewer - set column width

I try to enlarge the htop column's width. I've found a solution, but it seems very specific and also too difficult. Is there any simpler way to make all the characters in a column visible? (0 Replies)
Discussion started by: plaidshirtuser
0 Replies

2. UNIX for Advanced & Expert Users

How to set postgres process in monit file?

Dear Friends, I need to add the postgres process in monit file ( Debian machine ). How to add that process in monit?. If anyone know the solution for this, pls let me know. ---------- Post updated at 02:27 PM ---------- Previous update was at 12:21 PM ---------- I have found the... (0 Replies)
Discussion started by: rekha_sri
0 Replies

3. Solaris

Child killing parent process and how to set up SMF

Hello, A little background on what we are doing first. We are running several applications from a CLI, and not all of them are fully functional. They do on occasion core dump, not a problem. We are running a service that takes a screen scrape of those apps and displays them in a more user... (5 Replies)
Discussion started by: Bryan.Eidson
5 Replies

4. Red Hat

process fails if setuid bit is set

Hi, OS : Linux I have an executable (P1) owned by user say "abcd" and the setuid bit is set. And there is another executable (P2) which brings up the process (P1). When the setuid bit is set, the process P1 is failing, if the setuid bit is not set there is no issue. I was wondering if... (6 Replies)
Discussion started by: ahamed101
6 Replies

5. Shell Programming and Scripting

How to get and process mysql result set in shell script

Hi All, I am in a problem here is the description, Actually in my shell script i am firing a mysql query which returns multiple records and i have to process each record one by one. So could any one please suggest me how to solve my problem? Thanks in Advance Ashok Sharma (4 Replies)
Discussion started by: ashok1979
4 Replies

6. IP Networking

TTL for IP addr from DNS through C code

Hi All, I know that getaddrinfo() return the multiple IP addresses (if present) for a hostname. But, I want to know how to get the TTL value for this list from DNS. I want to get this TTL value and cache this IP address list for that much time and then again go for DNS resolution if TTL expires. ... (2 Replies)
Discussion started by: softindia
2 Replies

7. AIX

3004-505 Cannot set process environment

Guys I have an AIX 5.3 box.I am getting following messages if i try to switch to any non root user. bash-3.00# su - sys 3004-505 Cannot set process environment. bash-3.00# su - daemon 3004-505 Cannot set process environment. bash-3.00# su - adm 3004-505 Cannot set process environment.... (4 Replies)
Discussion started by: ak835
4 Replies

8. UNIX for Advanced & Expert Users

login error(can not set process env.)

I have created user in AIX 4.3.3 which the member of staff group. but during login ( with su command) it gives the error "can not set process environment " but when it is member of another group -dba -which is the group for oracle database- it works properly. Pls let me know the solution. ... (5 Replies)
Discussion started by: amit
5 Replies

9. UNIX for Advanced & Expert Users

TTL field???

Hi all, I wonder, how I can change Time To Live field for icmp packet in Redhat 7.1, kernel 2.4.2-2? I looked up in /proc/sys/net/ipv4 and did find this field in there. There should be a way to change TTL. If it's in header file, in which one? Thank you all :p (11 Replies)
Discussion started by: solvman
11 Replies
Login or Register to Ask a Question