linux

How can I use xargs to copy files that have spaces and quotes in their names?

I'm trying to copy a bunch of files below a directory and a number of the files have spaces and single-quotes in their names. When I try to string together find and grep with xargs, I get the following error: find .|grep "FooBar"|xargs -I{} cp "{}" ~/foo/bar xargs: unterminated quote Any suggestions for a more robust usage of xargs? ...

Which book would you recommend for a Linux Sysadmin?

Linux Administration Handbook by Evi Nemeth, Garth Snyder and Trent R. Hein is the defacto for sysadmins.Any other favorites besides this one. ...

How can I add fonts to netbeans?

I'm using netbeans on ubuntu, I would like to add some fonts to it. Could anyone tell me how this is done ? ...

how do i find which process is leaking memory

I have a system (Ubuntu) with many processes and one (or more) have a memory leak. Is there a good way to find the process that has the leak? Some of the process are JVMs, some are not. Some are home grown some are open source. ...

Recommended IRC server (ircd) for a small site?

The situation: I want to play around with IRC bots as general communications interfaces to other code I am investigating. The server hardware would be old and low-memory, but running on a relatively up-to-date Debian GNU/Linux install. I don't expect more than a hundred users at a time, tops, and probably in the single-digits most of ...

Is the mono .NET project included in latest release of most popular linux distros?

I'm wondering if mono.net is included in the default installation of Ubuntu, Kubuntu, and Fedora, and other popular distros? If so, does anyone have a good reason why NOT to use it to develop a new GUI application targeted mainly for linux? ...

Can you recommend a PostgreSQL Visual Database Designer for Linux?

When I'm in Windows, I use the excellent MicroOLAP Database Designer for PostgreSQL, but its not open source or multiplataform. Do you know or can recommend me an alternative to this software, that I can use in Linux? EDIT: Just to clarify, I don't want to use wine to emulate MicroOlap for PostgreSQL, it doesn't work too well, I would p...

system wide keyboard hook on X under linux

What would be the best approach to install a keyboard hook on Linux (X-windows) in order to trigger some application when some key-combo is pressed?? Is there a way to do this regardless of which window manager is running? The idea is to have an application being called ( or brought to foreground ) when some key is pressed in a way simil...

Best way to sandbox Apache on Linux

I have Apache running on a public-facing Debian server, and am a bit worried about the security of the installation. This is a machine that hosts several free-time hobby projects, so none of us who use the machine really have the time to constantly watch for upstream patches, stay aware of security issues, etc. But I would like to keep t...

DLL-s using C++ on Linux

I have tried to find how to create DLL-s on linux using google, but got very confusing information. Is it possible to write dynamic link libraries on linux? If not, are there other means by which I can call code in another module from several running programs? ...

Tips for speeding up build time on Linux using ANT, Javacc, JUnit and compiling Java classes

We have a large codebase that takes approx 12 minutes on the developer machines to auto-generate some Java 5 classes using JavaCC and then compiles all the classes as well as running the units test. The project consists of multiple projects which can be built in groups, but we are aiming for a full a build in under 10 minutes What tips...

Why do discussions of "swappiness" act like information can only be in one place at a time?

I've been reading up on Linux's "swappiness" tuneable, which controls how aggressive the kernel is about swapping applications' memory to disk when they're not being used. If you Google the term, you get a lot of pages like this discussing the pros and cons. In a nutshell, the argument goes like this: If your swappiness is too low, i...

Writing Color Calibration Data to a TIFF or PNG file

My custom homebrew photography processing software, running on 64 bit Linux/GNU, writes out PNG and TIFF files. These are to be sent to a quality printing shop to be made into fine art. Working with interior designers - it's important to get the colors just right! The print shops usually have no trouble with TIFF and PNGs made fr...

Window short cuts for XFCE4

Hi, This is not a programming question per se, but this is certainly about something which would help increasing my programming productivity. In KDE, one can assign short-cuts to particular windows. This eliminates alt-tabbing completely and, is very very convenient when multiple apps(browser, console, emacs etc) are open. My question ...

Linux configuration file libraries

Are there any good configuration file reading libraries for C\C++ that can be used for applications written on the linux platform. I would like to have a simple configuration file for my application. At best i would like to steer clear of XML files that might potentially confuse users. ...

When should I write a Linux kernel module?

Some people want to move code from user space to kernel space in Linux for some reason. A lot of times the reason seems to be that the code should have particularly high priority or simply "kernel space is faster". This seems strange to me. When should I consider writing a kernel module? Are there a set of criterias? How can I motivate...

Recovery from optical media ignoring read errors

I have backups of files archived in optical media (CDs and DVDs). These all have par2 recovery files, stored on separate media. Even in cases where there are no par2 files, minor errors when reading on one optical drive can be read fine on another drive. The thing is, when reading faulty media, the read time is very, very long, because ...

What IDE would be good for linux kernel driver development

I am using ubuntu 8.04.1 and i am trying to write a character driver in kernel mode. What would be a good ide, ideally with code completion, to do that ? ...

Setting per-file flags with automake

Is there a way set flags on a per-file basis with automake? In particular, if I have a c++ project and want to compile with -WAll all the files except one for which I want to disable a particular warning, what could I do? I tried something like: CXXFLAGS = -WAll ... bin_PROGRAMS = test test_SOURCES = main.cpp utility.cpp utility_o_CXXF...

Interlocked equivalent on Linux

In a C++ Linux app, what is the simplest way to get the functionality that the Interlocked functions on Win32 provide? Specifically, a lightweight way to atomically increment or add 32 or 64 bit integers? ...