|
I am using RHEL 4
i am using syscall stat as follows:-
if (stat ("file",&stat_obj)){
if (errno == ENOENT){ printf("File not found"); }else{ printf("Unexpected error occured %d ",errno); }
}
sometimes i get error message as ""Unexpected error occured 0...
Started by anish on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
Like -D_TS_ERRNO for thread-safe errno, but no such flag is needed on Linux.)
Does it give you any meaningful error message if you call it like this?
if (stat("file", &stat_obj) == -1) { perror("stat"); }
Do you have....
|
|
Linux HOWTO (Stats/Usage Setup) Hello Everyone,
I use this "quick-and-dirty" script to show usage under Linux. I am sure it can be made better, but it was a 2 min job. I have this in my cron jobs that calcs usage for the day, then rotates the log.
I have...
Started by Tazz_Tux on
, 8 posts
by 6 people.
Answer Snippets (Read the full thread at za):
22.65 MB | 3.20.
22.65
Usage per day :
Code: user@kubuntu:~$ vnstat -q -d ppp0 day rx | tx | total + + 15.12.
| 513 MB
Usage per day :
Code: user@kubuntu:~$ vnstat -q -d ppp0 day rx | tx | total + + 15.12.
|
|
2.7M lines last year
10K lines added a day.
5K lines deleted per day.
I keep thinking this can't be sustained. What happens next?
At the same time, well, as pointed out, we all use it all the time.
I'm sending this from gmail.
Or you can use Linux ...
Started by rminnich@gmail.com on
, 40 posts
by 16 people.
Answer Snippets (Read the full thread at omgili):
linux is the f4 of computing?
- erik
I'm not....
d
On Tue, Sep 22, it's said that the f4 is proof that given
enough thrust even a brick will fly.
On an SGI Altix (and that's ignoring stuff like uClinux, RT-
Linux, etc).
|
Ask your Facebook Friends
|
Hi,
How do you measure the memory usage of an application or process in Linux? I've read here that "ps" is not an accurate tool to use for this intent.
Thanks, Kenneth
Started by ksuralta on
, 13 posts
by 13 people.
Answer Snippets (Read the full thread at stackoverflow):
For instance, let's say you want to calculate could isolate it) ? How about libc? Or all these other libs that are required to run 'ls'?
linux usage throughout the lifetime of the program....
Most processes under linux use shared libraries.
|
|
After nearly a half year he comes Xaseco Stats part Deux for TM² Canyon.
*The download link is at the bottom of this post*
Version 1.0b
What has changed:
Fixed mx-error on FireFox.
Fixed Serverbanners.
Added Gamemode for Dedimania records.
Removed some...
Started by Xymph on
, 15 posts
by 6 people.
Answer Snippets (Read the full thread at tm-forum):
With my local firefox, chrome, internet explorer and also from a different linux server with lynx/wink.gif" />',$wandeln);
$wandeln = str_replace(':D','<img src="http://images.mania-exchange.com.
|
|
Following in the spirit of Hidden Features of Powershell and various others on StackOverflow, what Linux commands or combinations of commands do you find essential in your work?
Started by Chris Bunch on
, 43 posts
by 42 people.
Answer Snippets (Read the full thread at serverfault):
Perhaps....
:-D
I was surprised to find that you can run remote GUI applications over on remote servers without having to punt tcpdump files around:
ngrep -d any -W byline port 80
for example built to use pthreads).
Through the rest of them.
|
|
I want an easy way to create multiple directories in C++/Linux.
For example I want to save a file lola.file in the directory:
/tmp/a/b/c
but if the directories are not there I want them to be created automagically. A working example would be perfect.
Started by Lipis on
, 7 posts
by 7 people.
Answer Snippets (Read the full thread at stackoverflow):
Status:
mkdir -p /tmp/a/{b,c}/d
Will create the following paths:
/tmp/a/b/d /tmp/a/c/d
The braces allow you; #include "sysstat....
#include <sys/types.h> #include <sys/stat.h> int status; ...
But will work under Linux.
|
|
I need to keep statistics of daily network traffic for a linux machine (CentOS 5).
Is there a way to do it using standard/native tools or utilities?
Or do I have to dowload special software for that?
Thanks.
Started by GetFree on
, 9 posts
by 9 people.
Answer Snippets (Read the full thread at serverfault):
Toivola <tst at iki dot fi> -q, --query query database -h, --hours show hours -d, --days show.
|
|
On Wed, 01 Apr 2009 06:00:08 +0200, OK <otto@kaiser.de
http://gs.statcounter.com/#os-ww-daily-20080701-20090401
Sadly, not an April's fool....
Started by OK on
, 22 posts
by 11 people.
Answer Snippets (Read the full thread at omgili):
Hmm to generate charts like that using his
Linux based tools !
BTW why do you think the freetards prefer to discuss Microsoft's short
comings....
Peter Koehlmann told us that Linux had more penetration
in Germany than Apple.
That's strange.
|
|
Hello,
I'm running a multithreaded java app in Linux RedHat 5.3 on a machine that has 8 cores (2 quad-core cpu's).
I want to monitor the cpu usage of each thread, preferably relative to the maximal cpu it can get (a single thread running on 1 of the cores...
Started by Yoav Schwartz on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
Problem is that lots msg = String.format( "%s: %d ns cpu time, %d ns user time, blocked for %d ms, waited %d ms.
You can infer from stat files in /proc/PID/ and /proc/PID/task/PID/ .
|