General :: Make A Thread With A Poll?

Feb 25, 2010

Is there a way for members to make a thread with a poll? I've looked around and havent found how, but thought it is around here somewhere.

View 2 Replies


ADVERTISEMENT

General :: How To Make A Runnable Thread?

Feb 11, 2011

I wrote a code .sh I want to make it a runnable thread.
Q1: How can I do that in Ununtu?

Q2: I put that file (x.sh) in the "Auto start" program.I choose start at "start up" but it open the code editor page.I want it to be run behind backgroun...Have I convert it to .exe firstly ?!

View 17 Replies View Related

Programming :: How To Make Thread Nicer?

Feb 16, 2010

Kernel: 2.6.24.2
System: Embedded System

I have a process and two threads running in it. Thread1 is my GUI-Thread (using FLTK) and Thread2 is running at the first 10 sec. after start.Now, I would like to make Thread2 "nicer" to Thread1, because otherwise GUI stucks sometimes. But I didn't find a solution.Is it possible to define the "niceness" of threads inside a process (to each other)? And if so, how do I have to do this?

View 2 Replies View Related

Programming :: Which Is Scheduling Algorithm Which Will Make Thread O?

May 4, 2011

I have a timer thread, and when it expires, it sets a flag. The only problem is, if any higher priority thread comes in between, then the timer is not expired in real time.Thus i want to set a highest priority to my thread. Now, i know 2 algos, which can make my thread in real time are: SCHED_FIFO and SCHED_RR.

So, here are my queries: 1) Which scheduling algo is best suited for this purpose? 2) Is it guaranted to work in real time if i use that algo (you suggest in 1) and set the max_priority by getting the maximum settable priority for that particular algorithm using, int sched_get_priority_max(int policy);

View 2 Replies View Related

Programming :: How To Bind Thread To Specific Thread In Multithread Application?

Dec 25, 2010

I am going to use "pthread_setaffinity_np" to bind a thread to a specific core. My application has two threads. I have used mutex to assign a specific id to each thread and then bind that thread to a core different from another core. but it seems that the os assigns both thread to one core.What should I do to bind each thread to a specific core?

View 4 Replies View Related

Programming :: How To Poll For A Page In PHP

May 27, 2010

How do I poll for a page on a server using PHP?

If a user wanted a page that does not yet exist - but is being made at request - I'd like the script to "poke" the server to see if the page is ready to be displayed. If so, it would then transfer to that newly made page.

I read about "http_get", but do not seem to get it to work

Quote:

Ok, there might be a simple way out, but I don't see it.

My info came from [url]

More specific:

Quote:

Returns the HTTP response(s) as string on success, or FALSE on failure.

View 3 Replies View Related

Ubuntu Installation :: Xp Not Working After Upgrade Poll?

May 4, 2010

Just trying to analyse why there are so many issues with dual boot after the upgrade.

My story is,

1. I had only Windows xp on my computer

2. I installed Windows 7 RC on a partition

3. I uninstalled Windows 7 RC around april

4. Removed Windows 7 bootloader using [DVD Drive Letter]:ootootsect.exe /nt52

5. Installed ubuntu 9.10 into a new partition with grub as dual-boot

6. Upgraded to 10.04 and XP was not working using dual boot

Want to know how many people used Windows 7 bootsect to clean up the bootloader on their machines, maybe that has something to do with why XP is not clean.

View 1 Replies View Related

Ubuntu :: Claws Mail - How To Change Account Poll Order

Nov 9, 2010

I want to change the polling order of my two email accounts, but I can't figure it out. I have two IMAP accounts in Claws-Mail, one for work and one for 'other'. The work account is set as default. It is uppermost in the left pane. It is marked 'MH', which I think is to do with storage of the downloaded emails. Claws-Mail always polls my 'other' account first. This takes ages and prevents me getting my work email. How can I make sure the work account is polled first?

View 2 Replies View Related

Programming :: Poll() System Call Not Returning When The Socket Is Closed Locally?

Sep 29, 2010

we have a multi threaded program on Linux where one thread is waiting on poll() system call with event set to POLLIN, & another thread has closed the same socket fd (which is passed to poll) , but the poll() did not return, is this the expected behavior? From man page of poll we found that the poll should return POLLNVAL if the socket fd is closed, is my understanding correct or is there any bug in the poll()?In Solaris we observed that the poll system call is returning with POLLNVAL if the socket is closed.

View 3 Replies View Related

General :: Contact Admins - Remove The Thread

Jul 2, 2010

remove the thread after some one tells me.

View 2 Replies View Related

General :: Difference Core And Thread In Processor?

Jun 1, 2011

Can someone explain to me about the "core" and "thread" in the processor.

1. What is core?
2. What is thread?
3. What's the difference between core and thread?

View 8 Replies View Related

General :: Will Proc / Cpuinfo Gives CPU Info Per Core Or Per Thread?

Jul 18, 2011

My CPU has 2 cores, so I can see two parts in /proc/cpuinfo.But, I want to know if CPUs that support Hyper-Threading (or similar tech), will /proc/cpuinfo give CPU info per core or per thread (or call it sibling)?I only know that Windows Task Manager will give CPU usage statistics per thread if the CPU supports HT.

View 2 Replies View Related

General :: Get List Of Thread Of Running Process Using C Api (in That Code)?

Jan 29, 2010

In short our required is that we are creating a share library which can be loaded by a process and that share library analysis the process which load it. Since share library is in address space of the process so I need to find out how many threads created by the process and what is status of their stack trace etc.

So I am looking for a way to get list of threads in running process.

View 1 Replies View Related

General :: Find URL Of Screenshot To Insert Into New Thread Or Post?

Mar 15, 2010

I know what the URL of a webpage is and how to find it, but can't figure out how to do it with the screenshot accessory in Ubuntu 9.10. It is easy to use the tool to capture the image of a desktop, but won't let me do anything with the URL to insert it into anywhere!

View 5 Replies View Related

General :: 1:1 - What's Meant By There Is Kernel Level Thread For Each Pthread Created

Mar 11, 2011

I have gone thorugh some documents about pthread (NTPL ) in linux 2.6 kernel. As per that linux uses 1: 1 threading model and for each user level thread there is kernel level thread. Pthread_create uses clone system call to create a LWP and the kernel could treat that as a LWP and do scheduling and all .( different from linuxthread). My question is what's meant by there is kernel level thread for each pthread created. Can I see the kernel level thread if I call pthread_create using ps .

What exactly meant by 1:1 .I mean for each user level thread there is kernel level thread . If I make a system call from a thread does the OS services that action via kernel thread ( created using kernel_thread () or some other way ) internally ..

View 1 Replies View Related

General :: Stop Thread By Using Commands - Process Shouldn't Disturbed

Feb 12, 2010

How to stop a thread by using commands? Other threads in that process shouldn't disturbed. Is it possible to do the same?

View 2 Replies View Related

General :: Create A Signal Handler Thread To Handle SIGALRM Signals?

Jan 19, 2010

I'm trying to create a signal handler thread to handle SIGALRM signals. The main thread calls the following function before creating any other threads

Code:

pthread_t Timer::Init(long _clock_interval_musec)
{
// Set interval.
clock_interval = _clock_interval_musec;
// This is called while in a single threaded environment.

[code]....

clock_interval is 50.

Is the timer not firing? Did I not set my interval correctly? Did I not proper block the signals ensuring the that the default handler would not take care of them?

View 7 Replies View Related

General :: Make Error - Make[2]: *** No Rule To Make Target

Oct 7, 2010

I am getting an error as below.

How do I resolve the error: make[2]: *** No rule to make target `', needed by `mpg123'.

How can I resolve this error.

View 4 Replies View Related

General :: Difference Between Child THREAD And Child PROCESS?

Jul 30, 2009

I am troubleshooting something and I got this problem.

If I do "pstree -p"

It shows,

Code:

[code]....

However, it does NOT show up in "ps -elf"

Code:

ps -elf | grep soffi
0 S whho 7734 1 0 80 0 - 36435 - 11:14 pts/2 00:00:03 /usr/lib/openoffice/program/soffice.bin -splash-pipe=5
0 S whho 7833 7759 0 80 0 - 751 - 11:21 pts/3 00:00:00 grep soffi

I was wondering if 7735, 7736, 7737, 7743 were really processes. Then I checked /proc, I could cd to /proc/7735, /proc/7736, etc, but I could not ls them out. I looked at the man page of "pstree", it says,

Code:

Child threads of a process are found under the parent process and are shown with the process name in curly braces, e.g.

icecast2---13*[{icecast2}]

So, what does all this mean? Does it mean that 7735, 7736, 7737, 7743 are just threads but not processes? If so, why could I cd to /proc/<id> but not see them in "ps -elf".

View 10 Replies View Related

General :: 'make Menuconfig' To Make These Files Modules Rather Than Compiled Elements?

Feb 25, 2011

I need to modify fs/open.c and fs/read_write.c to make my modifications. I cannot find any options in 'make menuconfig' to make these files modules rather than compiled elements. I'm thinking these cannot be modules because the file system won't work without open.c and read_write.c. Is this correct - I cannot compile fs/open.c and fs/read_write.c as modules, only as compiled elements? Or, is there some way for a module to overwrite these routines when the module is installed and re-enable the routines when the module is removed?

View 3 Replies View Related

General :: Difference Between Make And Make BzImage Commands?

Feb 23, 2010

difference between make and make bzImage commands as both are used to build source code.

View 1 Replies View Related

Programming :: Quickest Way To Get Thread Id

Jun 24, 2010

What is the quickest way to get the thread id(tid) of the current thread in linux? Specifically I use fedora 13. ...and I am talking about inside a C++ program.

View 2 Replies View Related

Programming :: Determine What CPU Thread Is On?

Jul 2, 2010

Is there a library/system call that will return to me what CPU core a thread of execution is running on? I've looked for a bit on the net already and also in /usr/include and couldn't find one.

getcpu() and sched_getcpu() are two that I found, but when I include the appropriate header files (linux/getcpu.h, and sys/sched.h respectively), gcc says getcpu.h doesn't exist and the linker complains it cannot find the implementation in sched.h.

I'm sure I'm doing something really stupid or overthinking...

What I am doing is running an OpenMP application and specifying a list of cpu cores to run on with GOMP_CPU_AFFINITY. I want to make sure that each core is getting the same number of threads.

**UPDATE**

It seems that this code works, but only with glibc >= 2.6, and my machine has 2.5:

Code:
#define _GNU_SOURCE
#include <stdio.h>
#include <utmpx.h>
int main( void )

[Code].....

View 3 Replies View Related

Debian :: Mark A Thread As Solved?

May 5, 2011

How do you mark a thread as solved?

View 5 Replies View Related

Fedora :: Cannot View Posts To Thread ?

Nov 16, 2010

For some reason I cannot view my own postings to the thread I started here: [url]

I can only view the reply to it by jbuckley2004.

View 2 Replies View Related

OpenSUSE :: Compile QT With Thread Support

Nov 1, 2010

I am trying to install an Open GL screen saver "EulerTop-1.2" and I get the following error message when I run configure - "checking for perl /usr/bin/perl checking for Qt... configure: error: Qt (>= Qt 3.2) (library qt-mt) not found. For more details about this problem, look at the end of config.log. Make sure that you have compiled Qt with thread support!" It appears to be installed -

vance@linux-i4xo:/> rpm -q qt3
qt3-3.3.8b-93.1.x86_64

how does one enable thread support? I have looked around the web but cannot find a solution.

View 9 Replies View Related

OpenSUSE Hardware :: CDs Not Reading, Thread #2?

Jan 7, 2011

Same problem as someone else below- my optical drive will not read CDs in SuSE 11.3 (all the latest patches). CDs read fine in Windows, DVDs fine in both.This is a brand new drive, since my old one gave up the ghost last Tuesday (no longer appeared in BIOS)Drive is Samsung SH-S223L, and dmesg gives the following errors:

[ 64.952304] Buffer I/O error on device sr0, logical block 158968
[ 71.651194] sr 6:0:0:0: [sr0] Unhandled sense code
[ 71.651198] sr 6:0:0:0: [sr0] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE

[code]....

View 7 Replies View Related

Ubuntu :: When Does The POSIX Thread Start

Feb 3, 2010

i'm trying to understand the POSIX threads and i can't understand when does the thread start: does it start when i do

pthread_create()
or when i do
pthread_join()

or maybe i'm missing something. i do understand that pthread_join() causes the calling thread to wait till the called thread is finished.

View 2 Replies View Related

Ubuntu :: Test - How To Delete Thread

Jan 6, 2011

Just a test, how to delete the thread...

View 3 Replies View Related

Ubuntu Installation :: Looking For A Grub2 Thread?

Feb 10, 2011

i know i should look more through the forum, but i've been stuck on installing ubuntu on my computer for 3 days now, reinstalling, manual grub installing and so on, but no go. but i found a good thread on my still no fully functional ubuntu computer that explained very well for a complete linux noob how to install grub2 on ubuntu via the livecd. but since i was booting from the live cd meant that i couldn't bookmark it, and very little on this forum, as far as i can see, gets sticky, makes it very hard to find.

the basic problem is, i completly reinstalled ubuntu 10.10, and the bootloader (that i now know is named grub2) could not be installed. so i've found several guides, including the wiki, but it haven't really worked. now instead of explaining all of this over again, like all of you have probably done a million times, can you just post the most informative links here, so i can pick and choose,

View 9 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved