- Posts: 17
- Thank you received: 0
this is regarding the connectio
- iamprabhu100
- Topic Author
- Offline
- New Member
Less
More
18 years 9 months ago #12823
by iamprabhu100
this is regarding the connectio was created by iamprabhu100
Hi,
Can any one tell me the what is the use of the below commands
echo 86400> /proc/sys/net/ipv4/netfilter/ip_conntrack_tcp_timeout_established
echo "1024 2048 4096" > /proc/sys/vm/freepages
echo 0 > /proc/sys/net/ipv4/conf/all/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/eth0/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/eth1/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/lo/rp_filter
echo 1 > /proc/sys/net/ipv4/ip_forward
echo 1 > /proc/sys/net/ipv4/tcp_syncookies
echo 32768 > /proc/sys/fs/file-max
echo 60 > /proc/sys/net/ipv4/tcp_fin_timeout
echo 7 > /proc/sys/net/ipv4/tcp_retries1
echo 7 > /proc/sys/net/ipv4/tcp_retries2
echo 300 > /proc/sys/net/ipv4/tcp_keepalive_time
echo "1024 65535" > /proc/sys/net/ipv4/ip_local_port_range
echo 262144 > /proc/sys/net/core/rmem_default
echo 262144 > /proc/sys/net/core/wmem_default
echo 262144 > /proc/sys/net/core/rmem_max
echo 262144 > /proc/sys/net/core/wmem_max
Please can anyone tell me
regards,
Prabhakaran.D
Can any one tell me the what is the use of the below commands
echo 86400> /proc/sys/net/ipv4/netfilter/ip_conntrack_tcp_timeout_established
echo "1024 2048 4096" > /proc/sys/vm/freepages
echo 0 > /proc/sys/net/ipv4/conf/all/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/eth0/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/eth1/rp_filter
echo 0 > /proc/sys/net/ipv4/conf/lo/rp_filter
echo 1 > /proc/sys/net/ipv4/ip_forward
echo 1 > /proc/sys/net/ipv4/tcp_syncookies
echo 32768 > /proc/sys/fs/file-max
echo 60 > /proc/sys/net/ipv4/tcp_fin_timeout
echo 7 > /proc/sys/net/ipv4/tcp_retries1
echo 7 > /proc/sys/net/ipv4/tcp_retries2
echo 300 > /proc/sys/net/ipv4/tcp_keepalive_time
echo "1024 65535" > /proc/sys/net/ipv4/ip_local_port_range
echo 262144 > /proc/sys/net/core/rmem_default
echo 262144 > /proc/sys/net/core/wmem_default
echo 262144 > /proc/sys/net/core/rmem_max
echo 262144 > /proc/sys/net/core/wmem_max
Please can anyone tell me
regards,
Prabhakaran.D
18 years 9 months ago #12834
by nske
Replied by nske on topic Re: this is regarding the connectio
Hello,
They pass some values to the linux kernel, through the proc filesystem. These are either boolean values ( 0 or 1) used to define whether a particular feature is enabled or disabled, or integer values used to define various things (i.e. the size of some buffers in bytes, the time units after which idle connection sessions will be killed or the local port range for establishing outgoing connections). I suggest you don't change any of them unless you have a specific reason, since the optimum values vary greatly from application to application and the defaults are sensible in most cases.
You should be able to find detailed information if you query each element's name in google (i.e. "/proc/sys/net/ipv4/ip_forward"), some of them are easy to explain in one line, however some others are quite a bit more complicated. In general, options under /proc/sys/net/ipv4 define the behaviour of the tcp/ip stack (things like connection timeouts, available port range for initiating outgoing connections, activation of technical infrastructures like syn cookies -used against DDoS- or routing), options under /proc/sys/fs define the behaviour of filesystem drivers (things like max number of files to allow simultaneous access to), options under /proc/sys/vm the management of the virtual memory system and the elements under /proc/sys/net/core, lower level networking options.
There are many many more, most of which are documented in the linux kernel documentation, if you are curious try exploring the various kernel components through the menuconfig interface ("make menuconfig" in the path where you extracted linux kernel source, and press "?" for a description and a reference to more detailed info -if there is one)
PS. Notice that /proc is not a physical filesystem, it exists only in memory, so any of these changes must be re-written upon reboot.
They pass some values to the linux kernel, through the proc filesystem. These are either boolean values ( 0 or 1) used to define whether a particular feature is enabled or disabled, or integer values used to define various things (i.e. the size of some buffers in bytes, the time units after which idle connection sessions will be killed or the local port range for establishing outgoing connections). I suggest you don't change any of them unless you have a specific reason, since the optimum values vary greatly from application to application and the defaults are sensible in most cases.
You should be able to find detailed information if you query each element's name in google (i.e. "/proc/sys/net/ipv4/ip_forward"), some of them are easy to explain in one line, however some others are quite a bit more complicated. In general, options under /proc/sys/net/ipv4 define the behaviour of the tcp/ip stack (things like connection timeouts, available port range for initiating outgoing connections, activation of technical infrastructures like syn cookies -used against DDoS- or routing), options under /proc/sys/fs define the behaviour of filesystem drivers (things like max number of files to allow simultaneous access to), options under /proc/sys/vm the management of the virtual memory system and the elements under /proc/sys/net/core, lower level networking options.
There are many many more, most of which are documented in the linux kernel documentation, if you are curious try exploring the various kernel components through the menuconfig interface ("make menuconfig" in the path where you extracted linux kernel source, and press "?" for a description and a reference to more detailed info -if there is one)
PS. Notice that /proc is not a physical filesystem, it exists only in memory, so any of these changes must be re-written upon reboot.
18 years 9 months ago #12844
by monsky
Replied by monsky on topic Re: this is regarding the connectio
this is regarding with the "echo" syntax, i have been using this to append a text to an existing text file in DOS mode if the purpose is to insert a simple text or command.
for example, if we wanted to create an empty file "myfile" in dos C:\ prompt:
C:\copy con myfile then enter
F6 to save
C:\echo hello world >>myfile then enter
then to view the content of myfile file:
C:\type myfile then enter
hello world
you can see now the hello world inside the myfile file:
this is just a DOS trivia
but as nske has said:
in linux it is different and it teaches us a lot about an operating system.
for example, if we wanted to create an empty file "myfile" in dos C:\ prompt:
C:\copy con myfile then enter
F6 to save
C:\echo hello world >>myfile then enter
then to view the content of myfile file:
C:\type myfile then enter
hello world
you can see now the hello world inside the myfile file:
this is just a DOS trivia
but as nske has said:
PS. Notice that /proc is not a physical filesystem, it exists only in memory, so any of these changes must be re-written upon reboot.
in linux it is different and it teaches us a lot about an operating system.
Time to create page: 0.123 seconds