Results 1 to 3 of 3
Discuss iPhone sysctl.conf at the General - Hackint0sh.org; Is there a way to get the iphone to load /etc/sysctl.conf? I want to increase ...
  1. #1
    Newbie Array

    Join Date
    Dec 2007
    Posts
    2
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default iPhone sysctl.conf

    Is there a way to get the iphone to load /etc/sysctl.conf? I want to increase the TCP receive window size. (My net connect is high bandwidth + hight latency and the default is a bit low.) I tried putting the sysctl.conf into /etc but nothing changed when viewed from sysctl -a. Any help would be appreciated. Thanks.



  2. #2
    Newbie Array

    Join Date
    Dec 2007
    Posts
    2
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    So I figured out a way to load sysctl parameters at startup. Create a launch daemon in /Library/LaunchDaemons that launch a .sh shell script with a bunch of sysctl -w's. This is probably old news for OSX/Unix geeks out there but for everyone else:

    Example launch daemon:
    ===============
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
    <plist version="1.0">
    <dict>
    <key>Label</key>
    <string>com.deus.sysctl</string>
    <key>ProgramArguments</key>
    <array>
    <string>/etc/sysctl.sh</string>
    </array>
    <key>RunAtLoad</key>
    <true/>
    </dict>
    </plist>

    Example .sh file:
    (/etc/sysctl.sh)
    ==========
    #!/bin/sh
    sysctl -w kern.ipc.maxsockbuf=524288
    sysctl -w net.inet.tcp.rfc1323=1
    sysctl -w net.inet.tcp.sockthreshold=0
    sysctl -w net.inet.tcp.recvspace=126720
    sysctl -w net.inet.tcp.sendspace=126720

    I have BSD subsystem and Term-vt100 installed but I'm not sure if they're needed for this. You do need SSH or AFPd installed. If there's a better way to do this, do tell!

  3. #3
    Newbie Array

    Join Date
    Sep 2009
    Location
    4chan.org
    Posts
    1
    Post Thanks / Like
    Downloads
    0
    Uploads
    0
    Rep Power
    0

    Default

    hi

    I found this topic on google, and I'm trying to keep some of my sysctl.conf rules

    I did the shellscript (for i in `cat /etc/sysctl.conf`; do; sysctl -w $i; done)
    I wrote my sysctl.conf file.
    I created /Library/LaunchDaemons/com.sysctl.plist (copied from com.openssh.sshd.plist), and noticed you're only using Program Argument's key.
    Whatever, I tried like you did, and it didn't work.

    So I put 'Program' key instead of 'Program Argument' (following the way my openssh seems to start), but it didn't work either.

    And now... what do?
    Is this way to start scripts still available in 3.x and with 3GS?
    Last edited by faust64; 09-11-2009 at 02:38 PM.

 

 

Similar Threads

  1. sysctl > oid read only. can it be enabled?
    By clubtech in forum iPhone 3G
    Replies: 10
    Last Post: 01-31-2010, 07:00 PM
  2. How to edit resolv.conf?
    By cansurmeli in forum Genuine Mac Support
    Replies: 0
    Last Post: 06-29-2009, 08:39 AM
  3. loader.conf file on iPhone
    By leader288 in forum Free Toolchain Software (Cydia App's)
    Replies: 0
    Last Post: 06-16-2009, 07:10 AM
  4. Help.. Need contents of 'resolv.conf' file
    By neoxx in forum General
    Replies: 6
    Last Post: 10-17-2008, 09:12 PM
  5. [APPLICATION] resolv.conf issues
    By blackbird in forum General
    Replies: 0
    Last Post: 01-29-2008, 06:18 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Powered by vBulletin®
Copyright © 2014 vBulletin Solutions, Inc. All rights reserved.
Search Engine Friendly URLs by vBSEO
(c) 2006-2012 Hackint0sh.org
All times are GMT +2. The time now is 09:55 AM.
twitter, follow us!