linux

how to compile QVFB for embedded-linux-QT4.5 development on PC ?

Hi Friends, How can I compile QVFB for embedded-linux-QT4.5 ? Thanks, Sunny. ...

Deep dark secrets of Emacs?

Possible Duplicate: The single most useful Emacs feature So, there is this question for Vim users that keeps popping up in my feed reader, but I'm an Emacs person. So, what are some of the cool little hacks and tricks you've come up with using Emacs? And like the Vim thread, I'm talking about the things that only a very few ...

Crosss platform VNC Client Library?

Does anyone know of a good cross platform VNC client library (the viewer end)? I'm not terribly picky about language, but I would prefer something with C++ or Python. I would need it to work on Linux, Mac, and Windows. ...

Auto executable python file without opening from terminal?

Sorry if this is on the wrong site ( maybe superuser ) but I'm trying to make my python.py file executable so I can click on it and it automatically does its thing, without me specifying it to open in the terminal by that default prompt, and I already have 'chmod +x' for its permissions. Clarification: I want to run it by clicking on ...

sed not retrieving all values for second parameter

I am trying to have the command run to extract a range of dates from a file and print them ex: sed -ne '/^2009-08-20/,/^2009-08-26/p' Yet I have multiple occurances of 2009-08-26 in the file, I want all of them to return, yet it only returns the first one. Is it possible to have ALL return? Thanks! ...

C++ Executable distribution strategy

Recently I have asked a question about what I should use to create self-contained executables that would be deployed under a number of Linux distribution. I got very scared at first, but after reading about C++ a little, I managed to get the first version of my executable going. After a day full of joy, I just hit the wall again with an...

loopback mounting individual partitions from within a file that contains a partition table on linux

Is there any new/better way of loopback mounting individual partitions from within a file that contains a partition table on linux? I see the following but they are somewhat dated. http://linux.derkeiler.com/Mailing-Lists/Kernel/2005-01/7183.html http://lists.gnu.org/archive/html/grub-devel/2005-01/msg00077.html ftp://ftp.hq.nasa.gov...

What does readlink systemcall do?

I can't understand the operation of the "readlink" systemcall in Linux. Can anyone explain about it with simple example on it? ...

Grant capabilities to a running process

An already running process needs a privileged instruction, like using the SO_RCVBUFFORCE socket option. This process is running as a normal user process. How to give capability/permission to this process? File-based capability settings are still a dream? I have tried the /usr/sbin/setpcaps utility from libcap package and the cap_set_pr...

Calculating CPU usage of a process in Linux

Hi I want to programatically [in C] calculate CPU usage % for a given process ID in Linux. How can we get the realtime CPU usage % for a given process ?? To make it further clear - I should be able to determine the CPU usage for the provided processid or process. The process need not be the child process. I want the solution in...

Can't connect to MySQL server error 111

I installed mysql server on linux box IP = 192.168.1.100 but when i try to connect to this IP it alway error(111). but use localhost and 127.0.0.1 is OK. beer@beer-laptop# ifconfig | grep "inet addr" inet addr:127.0.0.1 Mask:255.0.0.0 inet addr:192.168.1.100 Bcast:192.168.1.255 Mask:255.255.255.0 beer@beer-lapto...

Deploy repository code to multiple machines at once

My question is: How do you guys deploy the same code from whatever [D]VCS you use on multiple machines? Do you have an automated deployment system and if so what's that? Is it built in-house? Are there out there any tools that can do this automatically? I am asking because I am pretty bored updating up to 20 machines every time I make s...

linux gedit: I always get "GConf Error: failed to contact configuration server ..."

How come I always get "GConf Error: Failed to contact configuration server; some possible causes are that you need to enable TCP/IP networking for ORBit, or you have stale NFS locks due to a system crash. See http://projects.gnome.org/gconf/ for information. (Details - 1: Failed to get connection to session: Did not receive a reply. P...

Erlang: daemon 'init.d' script fails to start

I have a python script which manages an Erlang daemon. Everything works fine when used through a shell once the system is initialized. Now, when I included the same script under "/etc/init.d" and with the symlinks properly set in "/etc/rcX.d", the python script still works but my Erlang daemon fails to start and leaves no discernible tr...

fcntl substitute on Windows

I received a Python project (which happens to be a Django project, if that matters,) that uses the fcntl module from the standard library, which seems to be available only on Linux. When I try to run it on my Windows machine, it stops with an ImportError, because this module does not exist here. Is there any way for me to make a small c...

How to search for a pattern inside a file and delete the lines in Unix on the command line?

I need to search for a pattern in files. For example the content of the file is below: 3555005!K!00630000078!C!20090805235959!47001231000000!16042296!336344324!A!1!ENG!0!00630000078!NO!00630000078! 3555005!K!204042880166840!I!20090805235959!47001231000000!16042296!336344324!A!1!ENG!0!00630000078!NO!00630000078! 3555005!D!16042296!DUMMY...

Linux/Unix Experience

When I look at job descriptions for Google, Amazon etc, they all require C++ and Linux/Unix experience. Could someone please define what this usually means in the context of job qualifications? Do I know how to browse the file system in Linux? Do I know how to run commands? Is C++ coding completely different for Linux/Unix envs(compi...

Is there a rebase (dll) command in linux/gcc?

On Windows, rebase changes the preferred load location for a dll and (I've read) can dramatically decrease application load time. Is there a similar concept on Linux and/or gcc? ...

How do I extract a single chunk of bytes from within a file?

On a Linux desktop (RHEL4) I want to extract a range of bytes (typically less than 1000) from within a large file (>1 Gig). I know the offset into the file and the size of the chunk. I can write code to do this but is there a command line solution? Ideally, something like: magicprogram --offset 102567 --size 253 < input.binary > outpu...

Bash Script - Running current or new instance of an application

I added a shortcut to an application in ubuntu. Each time i press shortcut keys, a new instance of application is created. I need only one instance, what script i can use to open the existing instance of application or creates a new one if the application is not running? ...