MODIFYING /proc/sys/net/core AND /proc/sys/net/ipv4...

Booting, installing, newbie
Post Reply
Message
Author
User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

MODIFYING /proc/sys/net/core AND /proc/sys/net/ipv4...

#1 Post by Gorilla no baka »

Ok i found them.... :D....

rmem_default - Receive Window default value
rmem_max - Receive Window maximum value
wmem_default - Send Window default value
wmem_max - Send Window maximum value


The first set of four are located in /proc/sys/net/core.



The second set of eleven are located in /proc/sys/net/ipv4



tcp_wmem - Send Window vector--contains 3 integer values: <min> <default> <max>
tcp_rmem - Receive Window vector--contains 3 integer values: <min> <default> <max>
tcp_mem - TCP stack memory vector--contains 3 integer values: <low> <pressure> <high>
tcp_rfc1337 - See rfc1337 "TIME-WAIT Assassination Hazards in TCP" for an explanation; 1 enables, 0 disables
ip_no_pmtu_disc - Path Maximum Transfer Unit discovery--disable this and the MTU settings are derived from the MTUs of all the hops along the path to the host you are connecting to, including the host itself; 1 enables, 0 disables
tcp_sack - See rfc2883 "An Extension to Selective Acknowledgment (SACK) Option for TCP" for an explanation; 1 enables, 0 disables
tcp_fack - Forward Acknowledgment is a special algorithm that works on top of the SACK options, and is geared at congestion controlling; 1 enables, 0 disables
tcp_window_scaling - window scaling, explained in the previous paragraph; 1 enables, 0 disables
tcp_timestamps - controls timestamping packets as described in rfc1323, since we will be using window scaling we might as well use this too; 1 enables, 0 disables
tcp_ecn - See rfc3168 "The Addition of Explicit Congestion Notification (ECN) to IP" and rfc2884 "Performance Evaluation of Explicit Congestion Notification (ECN) in IP" for an explanation; 1 enables, 0 disables
route/flush - flushes the routing cache; 1 enables, 0 disables


source
http://www.santa-li.com/linuxonbb.html

Now, i have got an other problem....

In linux Puppy215ce you can go straight in the respective folders and manually modify each file....entering the settings you want....

Puppy215ce will accept 'em for the time being.. no problem at all..

sysctl -p.... does not work tough....it seems that it does not recognize the command....


Whereas in Puppy Linux 4.1 looks like you do not have access at the respective folders even if you try to change the folders attributes and stuff..

Good thing is... that you can go in the /etc folder AND CREATE A FILE sysctl.conf input the values than save it and run sysctl -p....

Puppy 4.1 it will accept the command and it will ,,merge'' the instructions...but than again only for the current session.. the moment you reboot the default settings are back to the normal...


So... my question is.... How can make this settings permanent both in PUPPY LINUX 215CE AND PUPPY4.1

THANKS A LOT GUYS....
Last edited by Gorilla no baka on Tue 04 Nov 2008, 17:07, edited 1 time in total.
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

Bruce B

#2 Post by Bruce B »

you should be able to put your sysctl command in /etc/rc.d/rc.local and have it work by itself on each new boot

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#3 Post by Gorilla no baka »

Bruce B wrote:you should/ be able to put your sysctl command in /etc/rc.d/rc.local and have it work by itself on each new boot

Bruce...


You're a LEGEND Mate...

Thanks a lot...I really apreciated...

Now...I've got an other question...

Everytime when i try to open the /proc folder it takes ages in Puppy 215CE even when i give my self read write rights and stuff...sometimes it won't open at all and the screen goes empty the desktop as well loosing all its icons and looks like the system goes on scanning proc folder forever...

Is there any way around it...???

Cheers...
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

Bruce B (put your sysctl command in /etc/rc.d/rc.local)

#4 Post by Gorilla no baka »

Bruce B wrote:you should be able to put your sysctl command in /etc/rc.d/rc.local and have it work by itself on each new boot
I allready added it there and than checked with sysctl -p
and it gives me the same line as before,.


sh-3.00# sysctl -p
sh: sysctl: command not found
sh-3.00#
sh-3.00#
sh-3.00#


what do i do now,,,?>??

Cheers mate..

Ps: Sorry for beeing a pain...
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#5 Post by Gorilla no baka »

Ok ,BRUCE......

i got back...


SORRY AGAIN... :wink:


CHEERS !
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

Bruce B

#6 Post by Bruce B »

Gorilla no baka,

Good news: I want to acknowledge receipt of your posts. I guess we will keep everything together in THIS topic.

Bad news: is I have to shut the computer down now

Horrible news: is I have to baby sit mommy's cat and I'll be working on a Windows machine.

Why a Windows machine is horrible, if not obvious, well, Puppy doesn't like the USB mouse? What gives with that? Suggestions anyone? You could save the day!!!

Why a cat needs a baby sitter? Who knows? I leave my cat to babysit another cat. No big deal.. My cat is not accident prone or suicidal or anything like that.

I'll be back.

Bruce

I'll install another Linux if Puppy won't take to the mouse, I suppose. But first, I'll check it.

BTW - What version are we working on, so we can be on exactly the same page?

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#7 Post by Pizzasgood »

Everytime when i try to open the /proc folder it takes ages in Puppy 215CE even when i give my self read write rights and stuff...sometimes it won't open at all and the screen goes empty the desktop as well loosing all its icons and looks like the system goes on scanning proc folder forever...

Is there any way around it...???
The version of ROX-Filer used by some versions of Puppy used to lock up when it went into /proc. You can get around this by skipping /proc and going directly into whatever subdirectory there that you need (say, /proc/acpi) by doing this:
rox /proc/acpi

I generally don't bother using the file manager at all when dealing with /proc. I just do it from the commandline. I use ls for getting a list of the files, cd for moving around, cat to read from files, and echo to write to files. Example:

Code: Select all

bash-3.00# cat /proc/sys/kernel/hostname
puppypc
bash-3.00# echo "omnius" > /proc/sys/kernel/hostname
bash-3.00# cat /proc/sys/kernel/hostname
omnius
If you start typing a path and then press the [Tab] key it will try to autocomplete. If it can't or doesn't finish, pressing it a second time will list the possibilities. This applies to commands too (but not to the options that a command can take, except for paths).
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

Bruce B

#8 Post by Bruce B »

Pizzasgood wrote:
I generally don't bother using the file manager at all when dealing with /proc. I just do it from the commandline. I use ls for getting a list of the files, cd for moving around, cat to read from files, and echo to write to files. Example:
I gotta say, I never even tried it with an fm either. Ls, cat, less. These files may not be at all what they appear to be, even ls -l can deliver byte sizes of 0, but cat will do otherwise.

I'm on that Windows computer, tested Puppy 3.01 and it likes the USB mouse.

Ball's in your court Gorilla no baka, let me know exactly what version we are going to try and whip in shape. It is easy for me to lose track of a topic I'm working with, I admit, especially when I think it's resolved.

I'll watch for this one. Can't promise success. I don't have the usually amount of time either. If it falls on to page two, bump it or just PM me. Forget the others and let them fall off page one, okay?

It doesn't seem an emergency here, but I'm curious and I think Pizzasgood is, possibly others also.

Bruce

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#9 Post by Gorilla no baka »

Bruce

Thanks a lot for your understending mate...
I am using Puppy 215CE

I tried the other versions as well and well i do not specially like`em...Last one i tried was Puppy 4.1..

Puppy 215CE tough it is older and a lot bigger than the other ones somehow got under my skin...I have it installed on my HD full install i guess that`s how you call it and definatelly i am gonna stick with it...Wanna know why i like it..??
It`s relatively small ( it occupies 335 Mb on my Hd) it`s fast enough ( not as fast as my overtweaked-slimmed down ( 138 MB) win xp pro sp2
And somehow among of all distros ubuntus ,kubuntus mepises and dream linuxes it was the only one who reconized my all my cds and dvds and playd`em without any fuss.. without having to download any additional codes dvd support and stuff...
The sound is loud and clear louder than a normal dvdplayer made for windoze and the graphics are effing amazing..

I am using an old 224MB ram NecLavie... been bought 7 years ago ...

Anyway i just like this version,,,[/i]
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#10 Post by Gorilla no baka »

Pizzasgood

[/quote]The version of ROX-Filer used by some versions of Puppy used to lock up when it went into /proc. You can get around this by skipping /proc and going directly into whatever subdirectory there that you need (say, /proc/acpi) by doing this:
rox /proc/acpi .[/quote]

Just went home from work and gave it a shot...

The command works like a charm
(It took me straight inside of the rox /proc/acpi folder)

But unfortunatelly the results are the same ROX-Filer locks and the desktop goes blank and the /proc/acpi window goes completly white..
After half an hour the message: scanning......

was still there..so i had to go in task mannager and shut rox-filler down..

Listen... What are the chances to get it work by downloading and installing a Newer version of the Rox-filler..?

Don`t know how to do it anyway ..installing it i mean...I can download it but i have a feeling that apt-get install command will not work on it,,, :lol:
And i do not know any other command...

Still learning tough....

Cheers,,,,
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#11 Post by Pizzasgood »

Am I right in thinking these are your problems:
1: In Puppy 2.15 CE, the sysctl command doesn't work.
2: In Puppy 2.15 CE, ROX-Filer freezes when you go anywhere inside /proc/ with it.

Puppy 2.15 CE doesn't appear to come with the 'sysctl' program. You should still be able to do the things you want to do by using the echo command, and doing them one at a time. Then if you put all those commands into /etc/rc.d/rc.local, they will be run each time you boot.

For example, to set net.core.rmem_default = 524288, you would run this command:

Code: Select all

echo 524288 > /proc/sys/net/core/rmem_default
The 'echo' means to print whatever you give it to stdout. The '524288' is the value you are printing. The '>' tells it to redirect stdout into a file. The '/proc/sys/net/core/rmem_default' is the path of the file to redirect into.


For ROX-Filer, I don't remember it ever having problems anyplace besides /proc itself, but I'll try to look into it later today.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#12 Post by Pizzasgood »

I didn't have a 2.15CE iso handy, so I used a version of Pizzapup that was based off 2.14, which is the same version 2.15 was based off. ROX-Filer did freeze when I tried opening it at /proc/acpi, but it worked at some other spots.

Anyways, I dug up the source for a newer version and compiled it. Seems to work alright in /proc. Here is the download:
rox_2.6.1_overlay.pet
A note to anybody who considers using this with unleashed: it doesn't include any of the default settings and what-not, since it's intended to be installed over an existing installation. So if you use it with Unleashed, be sure to copy in all that stuff from a normal puppy's Rox package.

Also: this is compiled using the patched version of Rox that Puppies use, not the vanilla source.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#13 Post by Gorilla no baka »

Pizzasgood wrote:Am I right in thinking these are your problems:
1: In Puppy 2.15 CE, the sysctl command doesn't work.
2: In Puppy 2.15 CE, ROX-Filer freezes when you go anywhere inside /proc/ with it.
That`s true PizzaMan....
Pizzasgood wrote: Then if you put all those commands into /etc/rc.d/rc.local, they will be run each time you boot.
Ok....HOW do i put`em in there? That`s very confusing...Do not forget that my linux aknoweldge it`s` allmost 0...

Do i open up a notepad and write down all the commands
in this format :

Code: Select all

echo 524288 > /proc/sys/net/core/rmem_default
And then what? do i save it into /etc/rc.d/rc.local as what??
as sysctl?? but as you mentioned before Puppy will not reconize it...


If i save it into /etc/rc.d/rc.local with what extension do i save it..?? as in .lol . exe , .bac .....?


Thank you Pizzasgood :!: :!: :!: :!: :!: :)
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#14 Post by Gorilla no baka »

Pizzasgood wrote: Anyways, I dug up the source for a newer version and compiled it. Seems to work alright in /proc. Here is the download:
rox_2.6.1_overlay.pet
Also: this is compiled using the patched version of Rox that Puppies use, not the vanilla source.

Ok,,,
Thanks Pizzasgood...

So if i will download the stuff how do i install it..???


Is there any specific command that will allow me to install the packages..???



will there be any conflict version between my old rox and the new one..??

Cheers...
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

User avatar
Pizzasgood
Posts: 6183
Joined: Wed 04 May 2005, 20:28
Location: Knoxville, TN, USA

#15 Post by Pizzasgood »

Ok....HOW do i put`em in there?
Navigate to /etc/rc.d. Open the file 'rc.local' as a text file (normally with this file, you can just left click it, but otherwise you can right-click ->File 'NAME' -> Open as text). Add the commands near the bottom using the following format, and then save the file.
echo VALUE > PATH
Where VALUE is the value you wan, such as 524288, and PATH is the path to the file, such as /proc/sys/net/core/rmem_default.

Now the next time you boot, those commands should be run.

So if i will download the stuff how do i install it..???
I'm nearly certain that in Puppy 2.15 you can just download it, and then click on the file, and it should install itself.
Is there any specific command that will allow me to install the packages..???
petget rox_2.6.1_overlay.pet
will there be any conflict version between my old rox and the new one..??
It may reset any file-manager settings you have changed (but I doubt this), and may alter some icons. Otherwise there shouldn't be any issues. It should just overwrite the old one.

If it does change some icons and you want them back, you can mount the Puppy 2.15CE iso, then mount the pup_215.sfs file within, and then copy the original icons over the new ones. Something like this should do it:

Code: Select all

mount -o loop puppy-2.15.iso /mnt/cdrom
mount -o loop /mnt/cdrom/pup_215.sfs /mnt/data
cp /mnt/data/usr/local/apps/ROX-Filer/ROX/MIME/* /usr/local/apps/ROX-Filer/ROX/MIME/
umount /mnt/data
umount /mnt/cdrom
That assumes that you run it in the same location as the 2.15CE iso, that the iso is named puppy-2.15.iso, and that the directories /mnt/cdrom and /mnt/data exist.

I haven't actually tested this code, just for the record.
[size=75]Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib[/size]
[img]http://www.browserloadofcoolness.com/sig.png[/img]

User avatar
Gorilla no baka
Posts: 234
Joined: Sun 26 Oct 2008, 05:27
Location: UK
Contact:

#16 Post by Gorilla no baka »

Pizzasgood wrote:
Ok....HOW do i put`em in there?
Navigate to /etc/rc.d. Open the file 'rc.local' as a text file (normally with this file, you can just left click it, but otherwise you can right-click ->File 'NAME' -> Open as text). Add the commands near the bottom using the following format, and then save the file.
echo VALUE > PATH
Where VALUE is the value you wan, such as 524288, and PATH is the path to the file, such as /proc/sys/net/core/rmem_default.

Now the next time you boot, those commands should be run.

So if i will download the stuff how do i install it..???
I'm nearly certain that in P be uppy 2.15 you can just download it, and then click on the file, and it should install itself.
Is there any specific command that will allow me to install the packages..???
petget rox_2.6.1_overlay.pet
will there be any conflict version between my old rox and the new one..??
It may reset any file-manager settings you have changed (but I doubt this), and may alter some icon. Otherwise there shouldn't be any issues. It should just overwrite the old one.

If it does change some icons and you want them back, you can mount the Puppy 2.15CE iso, then mount the pup_215.sfs file within, and then copy the original icons over the new ones. Something like this should do it:

Code: Select all

mount -o loop puppy-2.15.iso /mnt/cdrom
mount -o loop /mnt/cdrom/pup_215.sfs /mnt/data
cp /mnt/data/usr/local/apps/ROX-Filer/ROX/MIME/* /usr/local/apps/ROX-Filer/ROX/MIME/
umount /mnt/data
umount /mnt/cdrom
That assumes that you run it in the same location as the 2.15CE iso, that the iso is named puppy-2.15.iso, and that the directories /mnt/cdrom and /mnt/data exist.

I haven't actually tested this code, just for the record.
Pizza`s God :P

Man, the command

Code: Select all

echo VALUE > PATH[code] it worked like a charm.....

it took me a while `till a realised that  ito /proc/sys/net/ipv4/tcp_rmem  i must write the value 3 times...

echo 847249408 > /proc/sys/net/core/rmem_default
echo 847249408 > /proc/sys/net/core/rmem_max
echo 847249408 > /proc/sys/net/core/wmem_default
echo 847249408 > /proc/sys/net/core/wmem_max
echo 847249408 847249408 847249408 > /proc/sys/net/ipv4/tcp_wmem
echo 847249408 847249408 847249408 > /proc/sys/net/ipv4/tcp_rmem
echo 847249408 847249408 847249408 > /proc/sys/net/ipv4/tcp_mem
echo 1 > /proc/sys/net/ipv4/tcp_rfc1337
echo 0 > /proc/sys/net/ipv4/ip_no_pmtu_disc
echo 1 > /proc/sys/net/ipv4/tcp_sack
echo 1 > /proc/sys/net/ipv4/tcp_fack
echo 1 > /proc/sys/net/ipv4/tcp_window_scaling
echo 1 > /proc/sys/net/ipv4/tcp_timestamps
echo 0 > /proc/sys/net/ipv4/tcp_ecn
echo 1 > /proc/sys/net/ipv4/route.flush

I also did the usually stuff in about:config setting the network connection to as many as it will take pipelining ...you know what i mean....

All in all it`s wondefull.... the commands are happily loading themself on each reboot and everything it`s working smoothly...

Well :roll:  Not exactly...I know that the values i put are a little bit high,...( the maximum puppy it would accept)
But  i can allways change`em back now that i know how to...
Good thing is Puppy seems to be awright with it tough sometime tends to lag with this values and the memory usage it`s sky rocketing...But as i said it is  for testing purpuroses only and for learning,...  If  i manage to tame  puppy i will make it my default os and  i will transfer it  on my normal laptop... right now puppy  it`s installed on a test machine,,,,,He must fell quite lonly in there,,, :roll:  :P

Thanks again man.....


PS:ABOUT THE  ROX-FILLER LOOKS LIKE THERE`S NO NEED TO DOWNLOAD AND INSTALL THE NEW VERSION ANYMORE...

I just found the XFE MANAGER AND THE Uxplor one and they do not lock in /proc /sys...

So looks like the problem it`s solved...

Cheers
[img]http://i44.tinypic.com/29zdifo.jpg[/img]
[b]
[color=red]I'M IN MY OWN WORLD[/color].[/b] [color=darkred]IT'S OK, THEY KNOW ME HERE..!!![/color]

Post Reply