Sponsored Content
Top Forums UNIX for Beginners Questions & Answers 1000 sleep commands on a Linux Server impact? Post 303035546 by MadeInGermany on Tuesday 28th of May 2019 04:46:49 AM
Old 05-28-2019
I mean a 1000 sleeping processes is no problem, but you should wake them up one by one, at least a small quantity (say 10) at a time.
 

7 More Discussions You Might Find Interesting

1. Solaris

Remove Server Sleep Mode

Hi All, Need some help here. Can anyone tell me how to set or which start up script to edit in order not to set the server to sleep mode after a while of inactivity. My Unix server will go to sleep mode and then i always end up with a OK Prompt and have to reset the server. My Server is a V120... (16 Replies)
Discussion started by: alvintai
16 Replies

2. UNIX for Dummies Questions & Answers

unix sleep and date commands

please help me to fix my script trying to use sleep 2 minutes while the system is sleeping i want to print out same message every 5 seconds thanks t=`date +%S` while do sleep 5 echo "this program will end in 2 minute" done (1 Reply)
Discussion started by: fanco
1 Replies

3. Hardware

Deskjet 1000 hp- commands

I have installed an HP Deskjet 1000 j110 on my Slackware system (13.37). I am trying to print more than 1 page out of 2 or more. No luck so far. Found that there are about 30 odd commands like hp-linefeedcal, -print, -pkservice, -printsettings, -devicesettings, -systray, -check, -align, and... (0 Replies)
Discussion started by: slak0
0 Replies

4. Shell Programming and Scripting

Script to pull uid greater than 1000 from remote server

Hello, I am trying to get UID # greater than 1000 from all linux server, I tried this script getting this error message, someone please suggest. $for i in `cat hostlist.0709.org` ; do ssh -t $i 'awk -F':' "{ if($3 >= 1000) print $0 }" /etc/passwd ' >> output ; done $ cat output hostname1... (4 Replies)
Discussion started by: bobby320
4 Replies

5. Shell Programming and Scripting

Running Commands on a Remote Linux Server over SSH

Hello, I'm trying to create a ksh script to ssh to a remote server, enter the password and a couple commands. For security reasons I have changed the login, password and ip in my example. #!/bin/ksh ssh -t -t username@12.5.5.3 << EOF password cd bin pwd EOF When I run it. It... (5 Replies)
Discussion started by: seekryts15
5 Replies

6. Red Hat

Red Hat 6.5: Leap Day 29.02.2016 Impact on the Linux Machine

Hi Experts Is there any impact on the Linux Machine with respect to the Leap Day {29.02.2016}, which would be introduced next year as part of the Leap Year {2016}. From my application scope, I see no problems. Please comment. Regards Navkanwal (5 Replies)
Discussion started by: navkanwal
5 Replies

7. UNIX for Beginners Questions & Answers

BSD Unix Toolbox: 1000+ Commands for FreeBSD, OpenBSD, and NetBSD

Usually when I on the evening go to bed I take some interesting book with me. I read it for a while to get me down to sleep. Probably most people seek information from the Nett by googleing but I am so oldfashioned I prefer a real book ;) But what a book. The one I found and ordered is BSD Unix®... (0 Replies)
Discussion started by: fossiili
0 Replies
LTSLEEP(9)						   BSD Kernel Developer's Manual						LTSLEEP(9)

NAME
ltsleep, tsleep, wakeup -- process context sleep and wakeup SYNOPSIS
#include <sys/proc.h> int tsleep(wchan_t ident, pri_t priority, const char *wmesg, int timo); void wakeup(wchan_t ident); DESCRIPTION
The interfaces described in this manual page are obsolete and will be removed from a future version of the system. The ltsleep() interface has been obsoleted and removed from the system. Please see the condvar(9), mutex(9), and rwlock(9) manual pages for information on kernel synchronisation primitives. These functions implement voluntary context switching. tsleep() is used throughout the kernel whenever processing in the current context can not continue for any of the following reasons: o The current process needs to await the results of a pending I/O operation. o The current process needs resources (e.g., memory) which are temporarily unavailable. o The current process wants access to data-structures which are locked by other processes. The function wakeup() is used to notify sleeping processes of possible changes to the condition that caused them to go to sleep. Typically, an awakened process will -- after it has acquired a context again -- retry the action that blocked its operation to see if the ``blocking'' condition has cleared. The tsleep() function takes the following arguments: ident An identifier of the ``wait channel'' representing the resource for which the current process needs to wait. This typically is the virtual address of some kernel data-structure related to the resource for which the process is contending. The same identifier must be used in a call to wakeup() to get the process going again. ident should not be NULL. priority The process priority to be used when the process is awakened and put on the queue of runnable processes. This mechanism is used to optimize ``throughput'' of processes executing in kernel mode. If the flag PCATCH is OR'ed into priority the process checks for posted signals before and after sleeping. wmesg A pointer to a character string indicating the reason a process is sleeping. The kernel does not use the string, but makes it available (through the process structure field p_wmesg) for user level utilities such as ps(1). timo If non-zero, the process will sleep for at most timo/hz seconds. If this amount of time elapses and no wakeup(ident) has occurred, and no signal (if PCATCH was set) was posted, tsleep() will return EWOULDBLOCK. The wakeup() function will mark all processes which are currently sleeping on the identifier ident as runnable. Eventually, each of the pro- cesses will resume execution in the kernel context, causing a return from tsleep(). Note that processes returning from sleep should always re-evaluate the conditions that blocked them, since a call to wakeup() merely signals a possible change to the blocking conditions. For example, when two or more processes are waiting for an exclusive-access lock (see lock(9)), only one of them will succeed in acquiring the lock when it is released. All others will have to go back to sleep and wait for the next opportunity. RETURN VALUES
tsleep() returns 0 if it returns as a result of a wakeup(). If a tsleep() returns as a result of a signal, the return value is ERESTART if the signal has the SA_RESTART property (see sigaction(2)), and EINTR otherwise. If tsleep() returns because of a timeout it returns EWOULDBLOCK. SEE ALSO
sigaction(2), condvar(9), hz(9), lock(9), mutex(9), rwlock(9) HISTORY
The sleep/wakeup process synchronization mechanism is very old. It appeared in a very early version of Unix. tsleep() appeared in 4.4BSD. ltsleep() appeared in NetBSD 1.5. BSD
January 28, 2012 BSD
All times are GMT -4. The time now is 07:09 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy