linux

Apache Tomcat server on linux

Hi, I have installed java and tomcat appache server on linux. When i am going to start tomcat using ./startup.sh command on linux server, it gives output as Using CATALINA_BASE: /usr/src/apache-tomcat-5.5.28 Using CATALINA_HOME: /usr/src/apache-tomcat-5.5.28 Using CATALINA_TMPDIR: /usr/src/apache-tomcat-5.5.28/temp Using JRE_HOME: ...

Linux vs Win runtime timings.

Hi, I have an application which was ported from Windows to Linux. Now the same code compiles on VS C++ and g++, but there is a difference in performance when it's running on Win and when it's running on Linux. The scope of this application is caching. It's a node between a server and a client, and it's caching client requests and server...

Developing a fullscreen "media player" on linux

Hi all, I'm a Windows developer and I need to develop a Linux application. The goal is to have a fullscreen application being able to display different media types (images, videos, flash). There might be multiple media files being displayed at the same time on the screen (if the screen is split in multiple zones). Can someone point me ...

How reliable are unix domain sockets?

I'm trying to figure out a protocol to use with domain sockets and can't find information on how blindly the domain sockets can be trusted. Can data be lost? Are messages always received in the same order as sent? Even when using datagram sockets? Are transfers atomic? When reading the socket, can I trust that I get the whole message o...

Tomcat on Linux (centos). Incorrect java version.

I have installed Tomcat5 on CentOS 5 using the yum configuration tool. My java web application requires java 1.6 to run without errors. However, my tomcat install appears to be using java 1.4. This is confirmed when I navigate to the tomcat manager page: Tomcat Version JVM Version Apache Tomcat/5.5.23 1.4.2 At the linux prompt...

ld cannot find library that is installed

I'm sitting on an OpenSuse 11.1 x64 Box and I have a module that uses sigc++. When linking like this: g++ [a lot of o's, L's and l's] -lsigc-2.0 I get /usr/lib64/gcc/x86_64-suse-linux/4.3/../../../../x86_64-suse-linux/bin/ld: cannot find -lsigc-2.0 However the library is there. In the filesystem: $ sudo find / -name "libsigc-2.0*"...

thread level memory consumption of process

How do I get per thread based memory consumption of a process in Linux? I understand that we can use /proc/pid/task/tid/statm, but thats not helping my case. All the threads show same value and its same as PID's statm. We can do valgrind but I am not looking for any invalid read/write or leaks. Valgrind will not tell me any thread leve...

RSS Works fine on my Development Server, not on my Live one.

Ok, here's the specs: Dev Server: Windows, WAMP, PHP 5+, Codeigniter Live Server: Ubuntu Linux, PHP, CodeIgniter, LAMP I get the following error in Firefox from my Live Server: XML Parsing Error: junk after document element Location: http://www.mysite.com/feed/rss2/ Line Number 2, Column 1: *syntax error, unexpected T_STRING in ...r...

Fork before or after accepting connections?

The following snippet of code creates 4 processes, all sharing the same listening socket. Is there any danger in doing this? Should I always have one listening process and fork after connections are accepted, in the conventional manner? for (p = 0; p < 3; p++) { pid = fork(); if (pid == 0) break; } while (1) { unsigned int cl...

choose Linux distribution for Haskell development

Which Linux version is the most comfortable for haskell development? I want to install ghc and compile Leksah in it. I'm using CentOS now but it's repository is not rich and fresh enough. ...

Information about RAM management in OS Linux, protection programs

I'm writing a report and presentation for my college titled "Protection runtime program in RAM. Examples of work with the protected program." I'm using Linux. I divided my report into two parts: Description of technology managed RAM OS Linux - Allocated memory for applications - Protection stack for one application from other applica...

Any good C++/C NNTP libs?

I came across some crusty and limited efforts awhile back but I was wondering if there was something truly functional that I missed, preferably in C++ but C is better than nothing. ...

How to start a gtk application after booting up without logging in?

Hi, I have got a gtk application. I want it to start automatically when I boot up the system, such that instead of getting usual login screen, my application greets the user. My application is a sort of cash dispensing application. So user should not even see the login screen of linux. Whenever machine in boot up, after loading servic...

shell - get exit code of background process

Hi, I have a command CMD called from my main bourne shell script that takes forever. I want to modify the script as follows: Run the command CMD in parallel as a background process ($CMD &). In the main script, have a loop to monitor the spawned command every few seconds. The loop also echoes some messages to stdout indicating progr...

Create a user-group in linux using python

I want to create a user group using python on CentOS system. When I say 'using python' I mean I don't want to do something like os.system and give the unix command to create a new group. I would like to know if there is any python module that deals with this. Searching on the net did not reveal much about what I want, except for python ...

wget-like bittorrent client or library?

Is there any bittorrent client or (Java|Python|Ruby|Perl) library that I can use like wget or curl? I would like to use simply as a step in a script, like you would use wget. EDIT: Sorry, I should have mentioned I'm using Ubuntu. ...

Get the child PID after system()

Hi, As far as I understand, the system() call uses internally fork() and exec() but encapsulates them for a easier handling. Is it possible to get the PID from the child process created with the system() call? Aim: I want to be able to SIGINT any child process after a certain timeout. I could rebuild the system() function by using fo...

System Wide I/O Statistics

Hey, In earlier versions of "vmstat", the device minor version was used to determine whether it was a partition or a disk (0 => disk and >0 => partition)). Am I not correct? Then, from kernel version 2.6.x some metrics were measured only at the disk-level, and hence the parsing algorithm was based on the number of metrics associated wi...

Get only a part of the line using awk

I have a log file and i use awk to extract the required columns. My command is awk '{ print $2" "$5" " $6}' log.txt The $5 column contains the servername and the format can be like @:server1@:@:@:, server2@:@:@:@:@:, @:@:Server3 with no fixed amount of @: symbols. How do I modify my statement so that I remove all the '@:' from the c...

Best Internet community for porting Adnroid/linux to LG Env Touch

I am trying to port Android to the LG vx11000 (env touch) and am wonder what the best website to use for development, a community of users to work on the project and resources such as git and a wiki. I have seen http://htc-linux.org/ and hack&dev community. I may just start up a wiki on the htc-linux since it uses the same chipset as th...