07-27-2006
Sync the settings to be the same. Full duplex will give more throughput if possible in your environment.
9 More Discussions You Might Find Interesting
1. UNIX for Dummies Questions & Answers
I am using the Linksys router as my hub to network my Win 2000 PC and Unix box to the cable modem. However, I can only get connection for my Win 2000 PC. The Unix box was able to get connection initially (yesterday) but when I reboot the machine this morning, the network went dead. What did I do... (6 Replies)
Discussion started by: conflansun
6 Replies
2. UNIX for Advanced & Expert Users
If I want to access unix box via VPN tunnel,from windows box.
What sould I configure on the windows client PC, and what should I enable on the Unix Server box ?
I am using Solaris V10 intel platform, and I am using windows XP, and 2003 for client (0 Replies)
Discussion started by: zillah
0 Replies
3. UNIX for Advanced & Expert Users
Hi all,
I am generating a file on the Unix machine , now i want to FTP the same file to the NT machine.
how can i do that and the application currently upon which i am working is a JAVA based application.
I need your help.
regards
Ruchir (2 Replies)
Discussion started by: Ruchir
2 Replies
4. UNIX for Dummies Questions & Answers
I am able to run the UNIX commands in a Windows box from a UNIX box through "SSH" functionality. But whenever the SSH connection is established between UNIX and Windows, password for windows box is being asked.
Is there a way to avoid asking password whenever the SSH connection is made? Can I... (1 Reply)
Discussion started by: D.kalpana
1 Replies
5. Shell Programming and Scripting
Hi All,
I need a little help .I want to transfer a file from unix box to a windows box,but the problem i'm facing is that in windows box FTP is not enabled and currently it is nearly impssible to change setting on windows box,i can not use the ftp method ,in my shell script to transfer the file.... (2 Replies)
Discussion started by: Preet
2 Replies
6. UNIX for Dummies Questions & Answers
scp file="myfile.txt" todir="user@somehost:(M:drive:/somepath/)"/
Not sure I need it to go to a specific drive on the windows box (1 Reply)
Discussion started by: xgringo
1 Replies
7. Shell Programming and Scripting
Hi
our unix admin has copied all files from one unix box to new unix box. We just need to confirm that all the file systems are copied properly. How to validate. (9 Replies)
Discussion started by: sravanreddym
9 Replies
8. UNIX for Advanced & Expert Users
Hi,
I am new for perl scripting, I need a script to copy a log file /test/test_yyyymmdd.dat from one unix box to another unix box location /check/check1/ at daily 2:00AM, please let me know how to do that......
Regards,
Ann (8 Replies)
Discussion started by: fabrine
8 Replies
9. Shell Programming and Scripting
Hello all !
I'm trying to write a shell script (bash) to ftp a file starting with particular name like "Latest_" that is present on a Windows box to UNIX server. Basically I want to set this script in the cron so that daily the new build that is posted on the Windows box can be downloaded to the... (2 Replies)
Discussion started by: vijayb4u83
2 Replies
LEARN ABOUT DEBIAN
sg_get_network_io_stats_diff
sg_get_network_io_stats(3) Library Functions Manual sg_get_network_io_stats(3)
NAME
sg_get_network_io_stats, sg_get_network_io_stats_diff - get network statistics
SYNOPSIS
#include <statgrab.h>
sg_network_io_stats *sg_get_network_io_stats(int *entries);
sg_network_io_stats *sg_get_network_io_stats_diff(int *entries);
DESCRIPTION
Both calls take a pointer to an int, entries, which is filled with the number of network interfaces the machine has. This is needed to know
how many sg_network_io_stats structures have been returned. A pointer is returned to the first sg_network_io_stats.
sg_get_network_io_stats returns the network traffic stored in the kernel which holds the amount of data transferred since bootup. On some
platforms, such as Solaris 7, this value is stored in a 32bit int, so wraps around when it reaches 4GB. Other platforms, such as Solaris 8,
hold the value in a 64bit int, which wraps somewhere near 17 million terabytes.
sg_get_network_io_stats also returns the number of packets sent and received, and the number of errors that have occured. It also makes the
number of collisions available.
sg_get_network_io_stats_diff is the same as sg_get_network_io_stats except it will return the difference since the last call. So, for
instance a call to sg_get_network_io_stats_diff is made, and called again 5 seconds later. Over that time, 20 bytes of traffic was trans-
mitted and 10 bytes received. Tx will store 20, rx will store 10 and systime will store 5. This function copes with wrap arounds by the O/S
so should be seemless to use.
RETURN VALUES
All network statistics return a pointer to a structure of type sg_network_io_stats.
typedef struct{
char *interface_name;
long long tx;
long long rx;
long long ipackets;
long long opackets;
long long ierrors;
long long oerrors;
long long collisions;
time_t systime;
}sg_network_io_stats;
interface_name
The name known to the operating system. (eg. on linux it might be eth0)
tx The number of bytes transmitted.
rx The number of bytes received.
ipackets
The number of packets received.
opackets
The number of packets transmitted.
ierrors
The number of receive errors.
oerrors
The number of transmit errors.
collisions
The number of collisions.
systime
The time period over which tx and rx were transferred.
BUGS
On the very first call sg_get_network_io_stats_diff will return the same as sg_get_network_io_stats. After the first call it will always
return the difference.
On operating system that hold only 32bits of data there is a problem if the values wrap twice. For example, on Solaris 7 if 9GB is trans-
ferred and the operating system wraps at 4GB, the sg_get_network_io_stats_diff function will return 5GB.
SEE ALSO
statgrab(3)
WEBSITE
http://www.i-scream.org/libstatgrab/
i-scream $Date: 2005/04/25 11:25:45 $ sg_get_network_io_stats(3)