What does all the counters in the ifconfig output mean? e.g. frame, dropped... this page describe some of them.
eth1 Link encap:Ethernet HWaddr 02:83:13:02:24:00
inet addr:192.168.20.13 Bcast:0.0.0.0 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:2169 errors:0 dropped:0 overruns:0 frame:0
TX packets:1769 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:1009774 (986.1 KiB) TX bytes:210912 (205.9 KiB)
Blog about development of embedded software for devices, the process of making it and the tools involved.
Showing posts with label Linux. Show all posts
Showing posts with label Linux. Show all posts
2010-09-17
2010-08-19
cat << EOF
Here is an option for writing several line of text to a file via a the shell.
~ # cat > test << EOF
> this is first line
> this is the second line
> EOF
~ # cat test
this is first line
this is the second line
~ #
~ # cat > test << EOF
> this is first line
> this is the second line
> EOF
~ # cat test
this is first line
this is the second line
~ #
Pipe stdout and stderr to one file.
In the Linux shell you can pipe both stdout and stderr to a file with > output_file 2>&1
E.g.:
memtester 16M 1 > /dev/null 2>&1
E.g.:
memtester 16M 1 > /dev/null 2>&1
Chain linux commands together
In the Linux shell you can chain a number of command together. You can do a number of command after each other without having to wait for each command to end.
e.g.
touch memtester ; memtester 16M 1 ; rm memtester
The commands is here separated with ; which tells the shell to execute the first command and then it is done it should execute the next command etc.
Another example:
touch memtester && memtester 16M 1 && rm memtester
Here the commands are separated with && which tells the shell to execute the first command and if it completes successfully then execute the next command and etc.
e.g.
touch memtester ; memtester 16M 1 ; rm memtester
The commands is here separated with ; which tells the shell to execute the first command and then it is done it should execute the next command etc.
Another example:
touch memtester && memtester 16M 1 && rm memtester
Here the commands are separated with && which tells the shell to execute the first command and if it completes successfully then execute the next command and etc.
2010-06-10
test -s
The test -s command behaves a bit different on Cygwin and Linux. In Linux it can be OK to use test -s to test for a directory, because it size if different from 0. But in Cygwin the test fails because directories in Cygwin have the size 0.
2010-06-04
Understanding the Linux load average
I was examine /proc/loadavg today, but how to interpret it? I found this fine post describing the content:
http://juliano.info/en/Blog:Memory_Leak/Understanding_the_Linux_load_average
http://juliano.info/en/Blog:Memory_Leak/Understanding_the_Linux_load_average
Subscribe to:
Posts (Atom)