Snmp commands dont work once the thread starts

I am using multi-threading. Once my thread starts executing (using the CmtScheduleThreadPoolFunction), I am not able to run simple get and set snmp function, basically they never return. Any suggestions?
Thank you all in advance.

Hi qsa301,
Does your function call work without multithreading?
Is the function documented to be able to be called by multiple threads?
Here are some KnowledgeBases about CVI and multithreading:
Executing LabWindows/CVI Internet Library Functions from Multiple Threads
http://digital.ni.com/public.nsf/websearch/88AC3C540ACFE65186257021005D2084?OpenDocument
Multithreading in LabWindows/CVI
http://zone.ni.com/devzone/cda/tut/p/id/3663
General Information on Multithreading for C Programmers
http://digital.ni.com/public.nsf/websearch/6ECCBAA87476EB22862568950071CCD6?OpenDocument
Sending Parameters to a Thread Callback Function in LabWindows/CVI
http://digital.ni.com/public.nsf/websearch/A50A89929B77EE06862571BF0015F42F?OpenDocument
LabWindows/CVI and Thread Pools
http://digital.ni.com/public.nsf/websearch/F968F9F8B100393786256D25005EAF8A?OpenDocument
Gavin Fox
Systems Software
National Instruments

Similar Messages

  • Working on the same start routine

    Hi
    I just want to know if two people can work on the same start routine using includes at the
    same time.
    Thanks in advance.
    Regards,

    Hi Kate,
        In any case if you enter into update rules in change mode it gets locks by user. So you cant see the start routine or update routine /rules.
        In the Editor for Start/ Update Routine you dont have change display button like you have in SE38, because you select the mode before entering the routine. So after this event a lock object gets created in SM12.
         So you can delete lock object in SM12 then you can use. I think simultaneous usage is not possible.
    Thanks,
    Srinivas.

  • How do you factory reset a iphone 4s if it dont work in the setting

    how do you factory reset a iphone 4s if it dont work in the setting

    vic17santos wrote:
    how do you factory reset a iphone 4s
    1: Connect the device to Your computer and open iTunes.
    2: If the device appears in iTunes, select and click Restore on the Summary pane.
    Restoring  >  http://support.apple.com/kb/HT1414
    Make sure you have the Current Version of iTunes Installed on your computer
    iTunes free download from www.itunes.com/download
    3: If the device doesn't appear in iTunes, try using the Steps in this article to force the device into Recovery Mode.
    Note on Recovery Mode.
    You may need to try this More than Once... Be sure to Follow ALL the Steps...

  • For some reason, I can not delete bookmarks. I did one at a time, then tried 5 or 6 and it worked once then no more. I then tried 1 at a time and it worked once the no more. This is a brand new computer (Win7) and FF just loaded about 3 hours ago.

    # Question
    For some reason, I can not delete bookmarks. I did one at a time, then tried 5 or 6 and it worked once then no more. I then tried 1 at a time and it worked once the no more. Why is this happening? This is a brand new computer (Win7) and FF just loaded about 3 hours ago. Do not know how the bookmarks even got in there. Some were ok, but no order and some that were never bookmarks. Looks like FF tried to import some BM's from the Virtual XP installed, but did not get it any where near right. I need to completely delete all of them and install from a saved .html file.

    Well, I did not see the exact problem that I was having listed in the articles, BUT the problem is solved for now.
    I opened FF and the Bookmarks to Organize again. I deleted all of the folders and entries, ONE AT A TIME, AND IT WORKED. Evidently, for what ever reason, FF did not like "Batch" deletes of ANY amount greater than 1 and the HANG UP would occur.
    Deleting one at a time then importing the good .html from a good file, loaded the wanted Bookmarks. Yea

  • How to show asterisk * effect once the user starts editing the document??

    I wrote a java text editor. I creat a new internal frame and allows to open a document.
    How to have an effect (an asterisk * follows the filename in title bar) once
    the user starts editing the document? And once I save that file, that asterisk * will
    disappear. It seems to me we need to add a listener, but not sure how to change
    the title bar of internal frame??

    just use DocumentListener like
    myTextArea.getDocument().addDocumentListener(new DocumentListenet(){
    public void changedUpdate(DocumentEvent e){
    frame.setTitle( frame.getTitle() + "*" );
    implements two other methods too

  • Why are the threads start and terminate randomly?

    Hi there,
    I got the program below. I am wondering why are the threads start and terminate randomly? Everytime, I run the program, it produces different results.
    I know that these four threads have got same normal priority (should be 5), and under windows there is something called timeslice. Then these four threads rotate using this timeslice. How do we know what exactly the timeslice is in seconds? If the timeslice is fix, then why the results are ramdom?
    Thanks in advance!
    * To change this template, choose Tools | Templates
    * and open the template in the editor.
    package mythreadone;
    * @author Administrator
    public class MyThreadOne implements Runnable {
    String tName;
    Thread t;
    MyThreadOne(String threadName) {
    tName = threadName;
    t = new Thread(this, tName);
    t.start();
    public void run() {
    try {
    System.out.println("Thread: " + tName);
    Thread.sleep(2000);
    } catch (InterruptedException e) {
    System.out.println("Exception: Thread "
    + tName + " interrupted");
    System.out.println("Terminating thread: " + tName);
    public static void main(String args[]) {
    // Why are the threads start and terminate randomly?
    new MyThreadOne("1");
    new MyThreadOne("2");
    new MyThreadOne("3");
    new MyThreadOne("4");
    try {
    Thread.sleep(10000);
    // Thread.sleep(2000);
    } catch (InterruptedException e) {
    System.out.println(
    "Exception: Thread main interrupted.");
    System.out.println(
    "Terminating thread: main thread.");
    1. Firstly, I set in the main function:
    Thread.sleep(10000);
    and I run the program it gives:
    Thread: 1
    Thread: 4
    Thread: 2
    Thread: 3
    Terminating thread: 1
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: 2
    Terminating thread: main thread.
    BUILD SUCCESSFUL (total time: 10 seconds)
    Run it again, it gives:
    Thread: 2
    Thread: 4
    Thread: 3
    Thread: 1
    Terminating thread: 2
    Terminating thread: 1
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: main thread.
    BUILD SUCCESSFUL (total time: 10 seconds)
    And my question was why it outputs like this? It suppose to be:
    Thread: 1
    Thread: 2
    Thread: 3
    Thread: 4
    Terminating thread: 1
    Terminating thread: 2
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: main thread.
    BUILD SUCCESSFUL (total time: 10 seconds)
    Why these four threads start and finish randomly each time I run the program? I use Windows, suppose there is a timeslice (i.e. 1 second), these threads have the same priority. Then the threads should start and finish in turn one by one. Am I right?
    2. My second question is:
    When I change the codes in the 'main' function into:
    Thread.sleep(10000); -> Thread.sleep(2000);
    it gives me the results like:
    Thread: 1
    Thread: 4
    Thread: 3
    Thread: 2
    Terminating thread: main thread.
    Terminating thread: 1
    Terminating thread: 4
    Terminating thread: 3
    Terminating thread: 2
    BUILD SUCCESSFUL (total time: 2 seconds)
    Run it again:
    Thread: 1
    Thread: 2
    Thread: 3
    Thread: 4
    Terminating thread: 3
    Terminating thread: main thread.
    Terminating thread: 4
    Terminating thread: 2
    Terminating thread: 1
    BUILD SUCCESSFUL (total time: 2 seconds)
    I tried several times. The main thread always terminates before or after the first child thread finished.
    My question is why it doesn't output something like:
    Thread: 1
    Thread: 2
    Thread: 3
    Thread: 4
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: 2
    Terminating thread: main thread.
    Terminating thread: 1
    BUILD SUCCESSFUL (total time: 2 seconds)
    or
    Thread: 1
    Thread: 2
    Thread: 3
    Thread: 4
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: 2
    Terminating thread: 1
    Terminating thread: main thread.
    BUILD SUCCESSFUL (total time: 2 seconds)

    user13476736 wrote:
    Yes, my machine has multi-core. Then you mean that if I got a one core machine the result should always be:
    Thread: 1
    Thread: 2
    Thread: 3
    Thread: 4
    Terminating thread: 1
    Terminating thread: 2
    Terminating thread: 3
    Terminating thread: 4
    Terminating thread: main thread.
    BUILD SUCCESSFUL (total time: 10 seconds)
    ???No.
    >
    How to explain my second quesiton then? Why the main thread always terminates before some of the child threads end? Thanks a lot.

  • My iphone home button stopped working and the phone started getting hot. The camera also fogged up. What do I do?

    My iphone home button stopped working and the phone started getting hot. The camera also fogged up. What do I do?

    I'm guessing it's a hardware problem. Your best option is to go to an Apple Store as soon as you can to try and sort this all out. While you're waiting to go visit an Apple Store, however, I'd imagine you still want to use your phone. To circumvent your hardware button problems, try enabling Assistive Touch by going to Settings>General>Accesibility>Assistive Touch. You'll see a small box appear on your screen. Tapping it will bring up several options for you to choose from, like the home button. Clicking the "Device" option will give you several options for controlling your phone that you would normally use hardware buttons for (i.e. volume, lock your phone, etc.) Hope this helps and good luck!

  • Help with broken? macbook. Boot commands dont work.

    I have an old macbook that is from late 2008 and is kinda old. First time it did 3 beeps (ram error) So i exchanged the ram and now it starts. But i get stuck at greyscreen, and sometimes at a flashing folder with a Question mark.
    I did try to go through the community here but i cant use any of the commands people are recommending..
    Command + Alt + R dont work
    Alt during boot dont work.
    Command + alt wont work... No commands do anything except leaving a blank screen and a cursor.
    If i dont hold any keys during boot i eventually get the flashing questionmark folder.
    Any suggestions?
    Can i reinstall it from a USB and how do i do it if i cant use the bootup commands? :S
    (The keyboard seems to work so that cant be the issue)
    Thanks.

    i dont know what the existing OS is.
    Cannot help with troubleshooting since you do not know which OS is installed on your comp.  If you purchased your MBP from a private party, ask them.  Better yet, did the previous owner provide you w/the DVDs that originally came w/the MBP?  If not, you purchased a glorified door stop.
    If none of the suggestions in the KB Article work out, take the MBP to your local AS or an AASP.
    There is nothing more for me to suggest until you determine which OS you are working with and you have possession of the system DVDs that originally came w/the MBP.

  • How do I make a sound play once the .swf starts?

    I have loaded 'Audio.wav' onto the Library, and given it a linkage name of 'Speedcore' without the apostrophes. I ticked the boxes 'Export for ActionScript' and 'Export in First Frame'.
    I want it to start once the .swf begins. I set Audio to Stream.
    This is a code I found but doesn't work
    var mySound:Sound= new Sound(); mySound.loadSound("Speedcore" , true); mySound.onLoad = function() { mySound.start(); }
    Help? =)

    Thanks, I will try it. The only thing I need is to learn global values or whatever. I'm using a money-system and I need to learn how to make it so you can only buy 1 of an item, and all that. But atleast I know the basics. Thanks Kglad!

  • Will a safari webarchive of a webpage still work once the website is taken down?

    I am trying to document a website before it's taken down and want to take full webpage images using Safari webarchive. But once the website is retired, do the webarchives still work (without the links of course)?

    They work here, even with no internet connection - but you might prefer to save from say Firefox, which produces a folder and .html page which can be opened in using any browser.

  • Whats wrong, why doesnt the thread start?

    Below is my code for the part of my program, which creates a thread for every client that connects to a server in an instant messenger program. What the thread does it constantly recieves any data sent to the server, so that it therefore displays it on its own area of the screen. For some reason...this thread does not want to start. Any help would be incredibly appreciated. So heres the code:
    class SocketClient extends JFrame implements Runnable {
         Socket socket = null;
       PrintWriter out = null;
       BufferedReader in = null;
              String text = null;
              Thread getdata;
       SocketClient(){
         public void listenSocket() {
         if ( connected==("2") ) {
    //Create socket connection
         try{
           socket = new Socket("0.0.0.0", 4444);
                        System.out.println("Connected to self");
           out = new PrintWriter(socket.getOutputStream(), true);
           in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
         } catch (UnknownHostException e) {
           System.out.println("Unknown host: host your connecting to");
           System.exit(1);
         } catch  (IOException e) {
           System.out.println("No I/O");
           System.exit(1);
                   connected = "1";
         else {
              try{
                    socket = new Socket("0.0.0.0", 4444);
           out = new PrintWriter(socket.getOutputStream(), true);
           in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
         } catch (UnknownHostException e) {
           System.out.println("Unknown host: host your connecting to");
           System.exit(1);
         } catch  (IOException e) {
           System.out.println("No I/O");
           System.exit(1);
         if (thisclient==(1))
                   System.out.println("in thisserver");
                   Thread getdata = new Thread();
                             getdata.start();
                             thisclient = 2;
         senddata();
    public void senddata() {
         //Send data over socket
         System.out.println("in send data method");
         friendtypingLabel.setText("in send data");
              String text = messageArea.getText();
              out.println(text);
           messageArea.setText(new String(""));
    //Receive text from server
    public void run()
              if(getdata == Thread.currentThread() )
                   System.out.println("running getdata thread");  // if the thread was running this would be written to system but it isnt
                   friendtypingLabel.setText("running get data");
                   getdatamethod();
    public void getdatamethod() {
         //Send data over socket
    //Receive text from server
    while(true) {
           try{
           String line = in.readLine();
              messlistArea.append("Message Client:" + line + "\n");
           } catch (IOException e){
          System.out.println("Read failed");
                 System.exit(1);
              try { Thread.sleep(2000); }
                   catch(InterruptedException e) {}
    }

    k...well ive made it so that the client can see what they have just sent....but i cant seem to make is so that the can see wot the server and wot other clients have sent...here is some update code:
    class SocketClient extends JFrame implements Runnable {
         Socket socket = null;
       PrintWriter out = null;
       BufferedReader in = null;
              String text = null;
       SocketClient(){
         public void listenSocket() {
         if ( connected==("2") ) {
    //Create socket connection
         try{
           socket = new Socket("0.0.0.0", 4444);
                        System.out.println("Connected to self");
           out = new PrintWriter(socket.getOutputStream(), true);
           in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
         } catch (UnknownHostException e) {
           System.out.println("Unknown host: host your connecting to");
           System.exit(1);
         } catch  (IOException e) {
           System.out.println("No I/O");
           System.exit(1);
                   connected = "1";
         else {
              try{
                    socket = new Socket("0.0.0.0", 4444);
           out = new PrintWriter(socket.getOutputStream(), true);
           in = new BufferedReader(new InputStreamReader(socket.getInputStream()));
         } catch (UnknownHostException e) {
           System.out.println("Unknown host: host your connecting to");
           System.exit(1);
         } catch  (IOException e) {
           System.out.println("No I/O");
           System.exit(1);
         if (thisclient==(1))
                   System.out.println("in thisserver");
                   getdata = new Thread(this);
                                                                                                                                                // if this is the client, then start the getdata
                             getdata.start();                                                                           // thread
                             thisclient = 2;
                             getdata.equals(Thread.currentThread());
         senddata();
    public void senddata() {
         //Send data over socket
         System.out.println("in send data method");
         friendtypingLabel.setText("in send data");
              String text = messageArea.getText();
              out.println(text);
           messageArea.setText(new String(""));
    //Receive text from server
    public void run()                                                   // runs the thread getdata
    System.out.println("Thread is " + Thread.currentThread());
              if(getdata.equals(Thread.currentThread()) )
                   getdatamethod();
    public void getdatamethod() {                      // method for the getdata thread
         //Send data over socket
    //Receive text from server
    while(true) {
    System.out.println("Run getdata");
           try{
                     String line = in.readLine();
                        if (line != null) {
              messlistArea.append("Message Client:" + line + "\n");
                             }catch (IOException e){
                              System.out.println("Read failed");
                      System.exit(1);
              try { Thread.sleep(2000); }
                   catch(InterruptedException e) {}
    }

  • SNMP does not work on the standby ASA firewalls

    Hello Everyone,
    I have a pair of 5 pairs of active/standby ASA firewalls running 8.4.4(1)
    All the active firewall respond to the SNMP requests, but the standby firewalls do not. I'm using SNMP v3. The configuration of primary and secondary firewalls is replica of each other, apart from the ip addressess.
    I want the secondary firewall to respond to SNMP requests coming in from the monitoring server. Can someone please help ?
    Thanks,
    Rishi

    Assuming you can ping both firewalls, the problem is that the firewall pair shares the same config and therefore, the same SNMPv3 engineID. Some NMSs (e.g. WhatsUp Gold) do not support this and therefore only 1 firewall in the pair can be queried.
    Doesn't look like this has been fixed yet:
    Bug info: CSCtl88556 - ASA5520 failover pair has duplicate snmp v3 engine id

  • My macbook started running wierd for example if you press anything it would freeze for 10-20 mins so i rebooted it now when it turns on the screen dont work and the fan is really loud???

    help!!!!

    I would reinstall:
    How to Perform an Archive and Install
    An Archive and Install will NOT erase your hard drive, but you must have sufficient free space for a second OS X installation which could be from 3-9 GBs depending upon the version of OS X and selected installation options. The free space requirement is over and above normal free space requirements which should be at least 6-10 GBs. Read all the linked references carefully before proceeding.
    1. Be sure to use Disk Utility first to repair the disk before performing the Archive and Install.
    Repairing the Hard Drive and Permissions
    Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When the menu bar appears select Disk Utility from the Installer menu (Utilities menu for Tiger, Leopard or Snow Leopard.) After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list. In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive. If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the installer. Now restart normally.
    If DU reports errors it cannot fix, then you will need Disk Warrior and/or Tech Tool Pro to repair the drive. If you don't have either of them or if neither of them can fix the drive, then you will need to reformat the drive and reinstall OS X.
    2. Do not proceed with an Archive and Install if DU reports errors it cannot fix. In that case use Disk Warrior and/or TechTool Pro to repair the hard drive. If neither can repair the drive, then you will have to erase the drive and reinstall from scratch.
    3. Boot from your OS X Installer disc. After the installer loads select your language and click on the Continue button. When you reach the screen to select a destination drive click once on the destination drive then click on the Option button. Select the Archive and Install option. You have an option to preserve users and network preferences. Only select this option if you are sure you have no corrupted files in your user accounts. Otherwise leave this option unchecked. Click on the OK button and continue with the OS X Installation.
    4. Upon completion of the Archive and Install you will have a Previous System Folder in the root directory. You should retain the PSF until you are sure you do not need to manually transfer any items from the PSF to your newly installed system.
    5. After moving any items you want to keep from the PSF you should delete it. You can back it up if you prefer, but you must delete it from the hard drive.
    6. You can now download a Combo Updater directly from Apple's download site to update your new system to the desired version as well as install any security or other updates. You can also do this using Software Update.

  • The danish letters æ ø å dont work in the blog

    If the letters æ ø å are used in the titleline in the blog funktion, the link will not work.
    the retun message looks like this:
    The requested URL /TikkeTakke/Tikke_Takke_._Nyhedblog/Optegnelser/2007/10/18Ã…bningsreceptionen.html was not found on this server.
    Even if the letter are cut away it will not work.
    anyone have a solution to the problem?

    I'am using fetch version 5.2.1 as FTP program
    It seems like fetch dont offer any setup to UTF-8
    i'll try to use Cyberduck
    (yes - i dont use .mac it is wery wery slow if you try to use i from denmark :o) so - i miss the function password etc)

  • [REOPEN] netcfg wireless connection works on the second start only

    Hi,
    subject tells most of it. I have a HP 8510w with a fresh installed arch setup. I migrated the default network connection to a netcfg-based setup. I set my home wifi settings (WPA128bit), and start netcfg. It fails after a timeout with 'Wireless association failed', and right after a quick netcfg restart connects without any problems.
    Any idea how to get around this problem?
    Last edited by kjozsa (2008-09-18 13:43:07)

    I can reproduce this here and started experiencing this myself recently. I'll see what I can do...
    In the meantime, update to netcfg 2.1 (core) and see if the quirks on the wiki help.
    Last edited by iphitus (2008-09-17 14:28:18)

Maybe you are looking for

  • How to install weblogic and froms compiler in redhat 6

    Dear gurus, I have oracle db Version 11.2.0.1 on redhat 6 and i develop forms/reports (Forms [32 Bit] Version 11.1.1.2.0 (Production)) in windows, all the operations are working fine till I access the form through Internet explorer. Now I want to shi

  • AppleWorks 6.0 Files Listed As Unix Executable Files. Unable To Open.

    A client of mine backed up a number of AppleWorks 5 & 6 files last week on a PowerMac w/ OS X 10.3. I reformatted the HD, upgraded the OS to 10.4 and attempted to reinstall AppleWorks 6.0. It would not allow installation. So, I installed OS 9 Classic

  • Analog distortion and digital's lack thereof

    Djokes wrote: "analog is distorting - without a doubt - tape decks were like compressors in a way and that is what being simulated by e.g. mcdsp or crane song... However, using no eq or tape deck - the distortion is minimal.... but analog is distorti

  • Include jsp page in servlet

    Hi, How an external jsp or html page can be included within a servlet. like, One servlet is including different pages within it's body based different condition and arggument passed to it. Hope for your help. Thank you.

  • Is it possible to add placeholders in Localized Resource text?

    Hi, I am writing a script for validating the file type of attachment file in an Attachment extension field. We have to restrict users from selecting any file other than the allowed types. If user selects a different file, I want to display an error m