Maximum number of threads can be created in solari

Dear All,
This is Amarnath.E, I'm working on high-end server program. As per my requirement i have to create many threads in my program.
1.Is there any limitation in solaris on creating the no. of threads?
2. If so how to increase the no. of threads that can be created?
3.Whether the No. of Threads can be created can vary based on the system configuration?
Please
ThanX in advance
Amarnath.E

Hello there,
I believe the previous answer is given correctly. There is no specific
kernel limit to be set. You will eventually run out of virtual address space
(after about ~3000 threads). Out of 4 GB virtual address space, kernel
base address (ie., F0000000) and beyond is reserved for kernel (except
for Ultra boxes where you can practically get almost 4GB each for
kernel and process's virtual address spaces). Thus you have about
3.75GB Sparc (3.5GB on X86 where the kernel base is E000000). It is
not recommended to reduce the thread stack size (just be sure your new
stack size will be able to handle the stack growth it needs per thread)
but, if you are sure it is safe for your purpose, this can be done as an
argument to a thread creation. Please see also manpage on thr_create.
hope this helps.
hae
Sun Developer Technical Support

Similar Messages

  • Maximum number of threads that can be spawned

    Hi
    What is the maximum number of threads that can be spawned from a 64-bit jvm with jdk 1.5? The application runs on
    SunOS 5.10 Generic_118833-24 sun4u sparc SUNW,Sun-Fire-480R
    Thanks

    Somewhere between about 10 and several hundred billion.
    A specific answer can be easily determined by you by actually writing a very small apps that spawns them and counts them.
    You might note that modern OSes limit the number of threads per app. In most or perhaps all unix variants you can change that limit. You can't increase that limit in java.
    Running the maximum number is very unlikely to be good idea however. Requiring that would suggest that the design is broken.

  • Limiting the number of threads that are created

    I am trying to write a web crawler as a way of learning about multi-threading and I have hit a stumbling block (probably my design). The way the application I have started works is that I provide a single URL, which is passed to a thread and that thread then parses the web page building a list of links (If the links are not already held in a 'visited' list then they are saved in a list in the Runnable object that is parsing the html page).
    When the page has been parsed the list of links are then passed to a method in a Utilities class that creates a new group of threads, 1 for each link and each of these threads then does the same thing. The problem I have is that as more and more links are captured more and more threads are created eventually I either get a out of memory exception or I get an operating system 'cannot create native thread' message. I am not sure if the threads are staying in memory after they have done their tasks, I am not sure why I am running out of memory so quickly.
    What I would like to try and do is to set a limit for the maximum number of threads created and then only create new threads if the limit is not breached. If someone could point me in the right direction that would be good, I have googled around but cant find an example of what I want to do.
    Thanks

    Thanks for that, that has given me a lot to read up on and I can already see where I went wrong.... I think implementing a thread pool and also a work queue is probably the way I will go from now on.

  • Maximum number of threads

    I have an application for which I am interested in obtaining as many simultaneous
    threads as possble (e.g. 10's and possibly 100's of thousands of threads).
    More specifically I have developed a simulation language formalism in which the
    dynamics of each "entity" moving through a network of queues is coordinated by
    a separate thread of execution.
    This is not a traditional application where all or even some small number are
    intended to run concurrently. A single executive thread is responsible for alternately
    activating and deactivating individual threads to reflect the time ordered sequencing
    of events corresponding to each entity's movement through the system of queues.
    As a result, only a single thread is executing at one time.
    Using a separate thread for each entity off-loads the task of managing each's
    execution context to the JVM. The resource contention issues that arise in a
    standard multi-threaded application don't apply here.
    For "large" systems though (ones populated by many entities simultaneously) I
    need many threads.
    I'm using JRockit's thin thread model on a Windows XP machine and am "only" able
    to get approximately 25000 threads at which point the JVM hangs with no diagnostic.
    I say "only" because at that point there seems to be plenty of heap space left
    as well as Page File space left in the XP's Virtual Memory system.
    I'm using the following JVM command line:
    java -Xthinthreads -Xss32K -Xms256M -Xmx256M -Xallocationtype:global
    Surprisingly, by altering the heap size upward from 256MB to 512MB acutally causes
    the VM to hang with fewer threads (only 20000 or so)
    Using allicationtype:global and altering the stack size of the threads seems to
    have little effect on the maximum number attainable.
    It seems the maximum number of threads attaible should be a function of the size
    of the heap space, and the amount of physical and virtual memory limits on the
    system.
    My empirical evidence, however, seems to indicate there is some internal VM limit.
    Can someone explain for me the implementation of the thin thread model and its
    limitations w.r.t. the number of threads it can support?
    Thanks in advance for you help.

    You might try to use the new java.util.concurrent.* api available in j2se
    1.5.0 as
    a base for your implementation instead.
    /Robert
    "Staffan Larsen" <[email protected]> wrote in message
    news:40f63c6b$1@mktnews1...
    The reason for the "artifical" limitation of 32767 is that each thread
    needs to have it's own id. The way the object synchonization algorithm
    works, there has to be space for this id in the header of each object.
    The header has a very limited amount of space (currently 2 words) and
    thus there is not space for a larger thread id than 32767.
    You may be interested (but sad) to know that the thinthreads model has
    been removed from later versions of JRockit. The reason was the overhead
    of maintaining and supporting multiple threading systems was just too
    much work for a small return. Although, for very specialized systems
    (like yours) it would give a higher return.
    About your calculation. You said in you first post that you set -Xss32k
    which means that each thread will take at least 32k memory, more likey
    40k with other overhead. That means about 25 threads per MB or 25000 per
    GB, given that everything scales linearly.
    Regards,
    /Staffan
    Kevin Healy wrote:
    Staffan,
    Thanks for your response. Certainly in a traditional multi-threaded
    applications
    where there exist many runnable threads competing for resources, thepoint of
    diminishing returns is usually on the order of 10's of threads; but, asI mentioned,
    this is not a traditional application. In this case, the threadingframework
    is used as a natural and convenient way to manage the execution contextof the
    (many) entities in the system. Since I'm not interested in trueconcurrency or
    exploiting parallelism, I view threads as just data and it strikes methat I should
    be able to get as many as I have room for. In fact the green threadsmodel of
    the pre JDK 1.4 JVM's was well-suited to this kind of application but itseems
    the JVM implementors have not considered this in removing support forgreen threads
    in their newest releases. The thin threads model of JRockit is the nextbest
    thing but the 32767 limit seems entirely artificial.
    Do you know of any way to bump up that limitation or who I might contactat BEA
    about the matter?
    I'm aware that stack space and other context specific data must beallocated for
    each thread so let's say for the sake of argument that each thread takes10KB
    of data. That means I get 100 threads per 1MB and it would take 1GB toget my
    100,000 threads. That is not an unusually large amount of data ontoday's desktop
    computer. Furthermore, with the advent of 64bit computing on thedesktop, we'll
    see machines supporting much more than 4GB.
    Staffan Larsen <[email protected]> wrote:
    First: which version of JRockit is this with?
    With thinthreads the limit is 32767 threads. But you may run into other
    limits before that. When you increase the heapsize you "steal" memory
    from the system (which would otherwise be used for stacks and other data
    structures) and that is why you can run fewer threads with a larger
    heap.
    >>>
    I don't think it is realistic to run 100's of thousands of threads in
    one single system.
    Regards,
    /Staffan
    Kevin Healy wrote:
    I have an application for which I am interested in obtaining as manysimultaneous
    threads as possble (e.g. 10's and possibly 100's of thousands of
    threads).
    >>>>
    More specifically I have developed a simulation language formalismin which the
    dynamics of each "entity" moving through a network of queues is
    coordinated
    >>>
    by
    a separate thread of execution.
    This is not a traditional application where all or even some smallnumber are
    intended to run concurrently. A single executive thread is responsiblefor alternately
    activating and deactivating individual threads to reflect the timeordered sequencing
    of events corresponding to each entity's movement through the systemof queues.
    As a result, only a single thread is executing at one time.
    Using a separate thread for each entity off-loads the task of managingeach's
    execution context to the JVM. The resource contention issues thatarise in a
    standard multi-threaded application don't apply here.
    For "large" systems though (ones populated by many entities
    simultaneously)
    >>>
    I
    need many threads.
    I'm using JRockit's thin thread model on a Windows XP machine and am"only" able
    to get approximately 25000 threads at which point the JVM hangs withno diagnostic.
    I say "only" because at that point there seems to be plenty of heapspace left
    as well as Page File space left in the XP's Virtual Memory system.
    I'm using the following JVM command line:
    java -Xthinthreads -Xss32K -Xms256M -Xmx256M -Xallocationtype:global
    Surprisingly, by altering the heap size upward from 256MB to 512MBacutally causes
    the VM to hang with fewer threads (only 20000 or so)
    Using allicationtype:global and altering the stack size of the threadsseems to
    have little effect on the maximum number attainable.
    It seems the maximum number of threads attaible should be a functionof the size
    of the heap space, and the amount of physical and virtual memory limitson the
    system.
    My empirical evidence, however, seems to indicate there is some
    internal
    >>>
    VM limit.
    Can someone explain for me the implementation of the thin thread modeland its
    limitations w.r.t. the number of threads it can support?
    Thanks in advance for you help.

  • Maximum number of aggregates that are created on infocube

    Hi,
    Can anyone tell how many Maximum number of aggregates that are created on infocube.
    Regards@thanks

    HI,
    I don't think there is any limit to the no. of aggregates. But it basically depends upon the volume of data and the reporting needs.
    Regards
    Rajesh

  • Task Manager Not loading Properly. Giving Error No more threads can be created in the System.NAPStatus UI and Some other Task related Errors

    I have a problem with the Task Scheduler. It is not opening properly it is giving Error Message box at this time i am unable to post. The Tasks Scheduler is starts with a error alert "No more threads can be created in the System.NAPStatus UI".
     I am unable to view the history of the tasks schecduled.It is giving message as 
    "The user account does not have permission to Access the Task History."
    How to fix it. It is frustrating as can't able to track my Tasks and Create new Tasks. Any Suggestions helpful.
    Thanks in Advance.
    RehaanKhan. M

    Hi,
    Thanks for your post.
    Please check event viewer if there are some error logs?
    Meanwhile, there is a similar thread has been discussed:
    Receiving error about "no more threads"
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/9a9e22e4-d947-4d19-b06c-aaadda624dbc/receiving-error-about-no-more-threads?forum=winservergen
    Regards.
    Vivian Wang

  • QM error "The user profile service service failed the logon. No more threads can be created in the system."

    Hi,
    I've a client running QM 8.x. QM is working and all recordings are present, it's just that when logging into the server, following error mesasge is displayed:
    The user profile service service failed the logon.
    No more threads can be created  in the system.
    Any suggestions on this issue will be greatly appreciated.
    thanks,
    Kapil

    Hi,
    Thanks for your post.
    Please check event viewer if there are some error logs?
    Meanwhile, there is a similar thread has been discussed:
    Receiving error about "no more threads"
    http://social.technet.microsoft.com/Forums/windowsserver/en-US/9a9e22e4-d947-4d19-b06c-aaadda624dbc/receiving-error-about-no-more-threads?forum=winservergen
    Regards.
    Vivian Wang

  • Maximum number of NI-CAN Objects

    Hello Folks,
    What is the maximum number of Ni-CAN objects supported by Ni - CAN boards ?
    What is the maximum size of the write queue buffer supported by the boards ?
    It seems there is a problem.
    I am not able to open more than 32 CAN objects, with a write Queue length of 60 arbitration IDs
    Note: I don´t what to use Frames !!!

    I could be thinking of something else here, but it seems the maximum number of Objects is dependent on timing of the writing.
    I think there needs to be a 2ms 'pause' between writes according to the CAN spec. So you could have 1 Object writing ever 2ms, 20 Objects writing every 10ms, 32 Objects every 16ms...
    I couldn't find anything in the documentation to support this, so I may be totally off base.
    On the ncConfigCANObj.vi, the Write Queue Length control has a maximum value of 1000 set in it's properties, so I would think that's the max write queue buffer.
    Hope this helps.
    Ed
    Ed Dickens - Certified LabVIEW Architect - DISTek Integration, Inc. - NI Certified Alliance Partner
    Using the Abort button to stop your VI is like using a tree to stop your car. It works, but there may be consequences.

  • What is the maximum number of recipients can I email in one email?

    Using 10.9.3 what is the maximum number of recipients can I email in one email from a MacBook Pro?

    Sending limit for a single email is 100 recipients.
    Sending limit for a 24 hour period is 200 emails.
    Maximum recipients for a 24 hour period is 1,000.
    Attachment size limit for outbound or inbound emails is 20mb.
    If You Exceed Limitations – You’ll see an error message and your account will not function for 24 hours.

  • How many threads can be created in a java swing program?

    At first, I intend to use Timer to create a 2D plot repeatedly after a certain number of milliseconds. This is for an animation. However, I discover that it takes a lot of time to generate each 2D plot frame ( about 700 milliseconds on a 1.13 MHz computer, this is a complicated plot requiring a lot of computations). So I think I should use SwingWorkers, that means a new thread for each generated graph image. There might be 1000 images to be created, and thus there might be thousands of threads in my programs. I would like to know if there is any limitation on the number of threads generated in a program so that it will be safe, or is it ok to generate as many threads as you want, as long as you follow strictly the syntax of creating threads?
    I would be thankful if someone can give me some advice.

    as there is no restriction in the Language Specification (http://java.sun.com/docs/books/jls/second_edition/html/memory.doc.html#28457) i would think it's theoretically indefinit. of course, it has a maximum because of your memory. ;-)

  • Maximum Number of Report can BI Publisher burst per day

    Hi Experts,
    I have a requirement to burst 2 different reports to 10000 users on a daily basis.
    Can this be handled by BIP 11g.?
    What is the maximum number it can handle.?
    Thank You.

    Check these
    https://blogs.oracle.com/xmlpublisher/entry/dynamic_grouping_and_columns
    Dynamic Columns, using the element name as the column header name
    If helps pls mark
    BTW: There is another area for BIP ( use link
    BI Publisher )
    there you may find core BIP Gurus :)
    Edited by: Veeravalli on Nov 21, 2012 9:22 AM

  • In my I pad air I cloud has been set up but when I try to log in it shows me a dialog box that maximum number of accounts have been created and home screen appears.      So what should I do to open an account in I cloud?

    Suggest me some ideas guys.

    There is a limit to how many free accounts can be created on a device - you will either need to use of the accounts that's already been created on it, or create another one on a different device/computer

  • What is the maximum number of Fibre Channel LUNS visibile in Solaris 11.2

    I have SPARC T4-4's with 4 emulex HBA ports. What is the maximum number of LUNS I can have exported to that server?

    Hi Jim,
    MOS doc 1018739.1 describes maximum Solaris SCSI and FC targets, LUNs, and device instances.
    The FC limit for maximum LUNs is either 65535 or unlimited.
    Thanks, Cindy

  • OutofMemoryError: no new native threads can be created

    Hi,
    I need run over 10,000 threads concurrently, but got OutofMemoryError. I know this problem can be fixed by increasing heap size. But how to do that?
    Any ideas or other solutions on that?
    Thank you very much.
    Henry

    I doubt that will fix it. Last time I tried it the maximum was around 2,000 threads. Might be more now though.
    The javadocs provide all of the command line information...
    http://java.sun.com/j2se/1.5.0/docs/tooldocs/windows/java.html#options

  • How many thread can I create?

    I wrote a multithread program. I use Excutors class and newCachedThreadPool method to create a thread pool.
    I want to create max threads that i can. In some where, I saw Max thread that is allowed, depends on OS, availabe memory, JVM.
    I use SUSE 11.1 as operating system, have 3.75 GB RAM & 7.5 GB swap & use jdk 1.6
    I want to create max threads that i can. I don't know how many i can create.
    please help me.

    Hi _Security, Mutli-Threading isn't always a good thing, because of the constant switching the processor has to do, causing it to be slower then it could be if you properly queued your tasks instead of threading each one. Each thread you create is another thing your processor has to execute each cycle, so if you have tons of threads, your processor will have to execute and switch through each one every cycle, making it bog down performance by a long shot.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

Maybe you are looking for

  • Retry recovery action is taking long time to complete

    Hi, I am in the process of testing error handling for my BPEL process. As part of it, I have given the default recover action in the fault policy of the process as retry with a retry count of 3 times with retry interval as 2. To test this, i have cha

  • HTMLB TableView: Edit first Line

    Hi, I have implemented an HTMLB TableView with the attribute selection mode 'singleselect'. The users can mark one row to edit. This works so far. But as the users have to maintain at least one row, the first row should initially be editable <b>witho

  • To select columns based on user's input

    hi all.. i am beginner in oracle forms 6i.. i want to select columns in my query according to user's input? how can i do it in my oracle forms 6i? i am using a graph in my oracle form and i want to plot graph according to user input? in my graph i ha

  • How to get Current Year

    Dear Friends I am writing a fast formula for medical reimbursement. My fiscal year start will be 01-mar every year and end date will be 30apr every year. Every year I need the current start date and end date like Accruals. Can anyone please suggest m

  • How do you send an email to undisclosed recipients?

    do i put my recipients in the BCC field? and to whom do i address the email to?