I am writing a python script that needs to make a log entry whenever it's invoked. The log created by the script must not be changeable by the user (except root) who invoked the script. I tried the syslog module and while this does exactly what I want in terms of file permissions, I need to be able to put the resulting log file in an arb...
Is there any way to store file creation time in linux? May be filesystem that supports that. I mean CREATION TIME not mtime or ctime.
...
I've been tasked with porting an existing Windows GUI app to Linux. Ideally, I'd like to do this so the same code base can be used to build either the Windows version or the Linux version. I'll be doing my work on Ubuntu 9.04. After searching around, it's unclear to me what tools are best suited to help me with this.
A list of loos...
You usually invoke the following commands to build a ./configured product:
make
make install
Okay, the product is in the system now. Then you change some source code files and invoke only make install. The question is, does the conventional implementation of install target requires the executables to be recompiled, or just the old o...
I can't figure this out. I try to import a new project into a svn repository from Netbeans and get 403 Forbidden. I just setup svn on my serverbox today. I can get to it through a browser just fine, though its empty as I haven't imported my project yet.
Apache's path for html files is /var/www
I setup the svn repo in /var/svn
This is t...
I have an application running on Linux, and I find myself wanting windows (!).
The problem is that every 1000 times or so I run into concurrency problems that are consistent with concurrent reading/writing of files. I am fairly sure that this behavior would be prohibited by file locking under Windows, but I don't have any sufficiently f...
I would like to add some interactive capability to a python CLI application I've writen that stores data in a SQLite3 database. Currently, my app reads-in a certain type of file, parses and analyzes, puts the analysis data into the db, and spits the formatted records to stdout (which I generally pipe to a file). There are on-the-order-...
Can someone point me to a decent RPC tutorial for (or books) linux, like in this post. I tried looking around myself, I've only found tutorials that are really old.
Thanks
...
I'm trying to test a single file if it is open using lsof. Is there a faster way than this?
$result = exec('lsof | grep filename | wc -l');
if($result > 0) {
//file is open
}
I'm thinking their must be a way to just test for one file if you know the filename. All I really need is a true or false.
...
I have a ARM based machine with ubuntu distro on it and it often feeds me with this while running various commands:
Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "pl_PL.UTF-8"
This is output of the locale command
locale: Cannot set LC_CTYPE to default locale: No such file or directo...
I want to be able to distribute bundles of files, about 500 MB per bundle, to all machines on a corporate "extranet" (which is basically a few LANs connected using various private mechanisms, including leased lines and VPN).
The total number of hosts is roughly 100, and the goal is to get a copy of the bundle from one host onto all the ...
Hi,
I want to install this python package:
http://pypi.python.org/pypi/netifaces/0.5
But I don't know how and I know nothing about python. Still, I guess there is a standardized way to install it. Am I right?
Thanks in advance
...
I would like to dynamically allocate memory from the machine_init function in my arm linux kernel. Calling kalloc can result in a complete failure of the system to boot.
My debugging tools are very limited so I can't give much more information regarding the failure.
Simply put, is it legal to call kalloc from a machine_init function in...
Hi, I'm trying to use the SDL_Image library and I've added the .so to the link libraries list for my project (I'm using Code::Blocks, by the way).
After doing this, when I go to compile, I get this error:
Linking console executable: bin/Debug/ttfx
/usr/lib32/libSDL_image-1.2.so: could not read symbols: File in wrong format
What does ...
In OpenSolaris OS, when I run makefile generated by Eclipse CDT on the Linux OS, I get an error on the first -include line.
The same error was in FreeBSD, and was solved by executing gmake instead of make. In OpenSolaris (just installed) gmake doesn't work (command not found).
What package should I install and how exactly, to build L...
I have the following directory structure:
+-archive
+-a
+-data.txt
+-b
+-data.txt
+-incoming
+-a
+-data.txt
+-c
+-data.txt
How do I do the equivalent of mv incoming/* archive/ but have the contents of the files in incoming appended to those in archive rather than overwrite them?
...
Why is it necessary though everything is specified in a makefile?
...
Hi I have 64 bit .deb file of an application. I want to convert the same file into 32 bit .deb file.
So how to convert 64 bit .deb file into 32 bit .deb
...
What is the proper way to get a list of all available serial ports/devices on a Linux system?
In other words, when I iterate over all devices in /dev/, how do I tell which ones are serial ports in the classic way, i.e. those usually supporting baud rates and RTS/CTS flow control?
The solution would be coded in C.
I ask because I am us...
OS: Linux, Language: pure C
I'm moving forward in learning C progpramming in general, and C programming under UNIX in a special case :D So, I detected a strange (as for me) behaviour of the printf() function after using a fork() call. Let's take a look at simple test program:
#include <stdio.h>
#include <system.h>
int main()
{
int...