[MISC] CraftProxy 0.2.0 - Reduce bandwidth use by caching chunk data [1.6]

Discussion in 'Archived: Plugin Releases' started by Raphfrk, May 1, 2011.

  1. Offline

    Raphfrk

    CraftProxy - Reduce bandwidth use by caching chunk data
    Version: 0.2.0

    Description

    This plugin and local client allows chunk data to be cached locally by players. This reduces the bandwidth required for hosting the server. It also helps users who are on slower connections.

    I am not sure what the status of this system is. It doesn't count as a plugin, since it has 2 parts.

    Even when running the plugin, players who don't use the client proxy can still connect. However, they will use the full bandwidth.

    The system can reduce bandwidth by 70-90% (after the 2nd login).

    Setup

    Server

    Add the plugin file to the plugins folder

    Client

    Start minecraft client and login
    Double click on the client jar file
    Enter login details
    Enter the server location/port in the GUI
    Press start on the GUI
    Connect to localhost on the minecraft client

    Stable Builds

    None yet

    Dev Builds

    Warning: These may not be stable

    Client
    Plugin

    Had it get the compress/decompression gain backwards.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
    Jushy, Martin1704, Nathan C and 24 others like this.
  2. Offline

    Raphfrk

    Just leave everything as default. Most of those settings are for interaction with Server Port.

    Well, I haven't said what those settings can do, so makes sense that nobody would know :).

    Code:
    default_server=25565 <- hey i know that :confused:
    
    You might want to change this one. It is the location of your Bukkit.

    If it is on the same computer as the proxy, (which it is, since you are running it as a proxy), then you normally just need the port.

    Code:
    default_server=<ip-of-server>:25565
    
    This is a little more reliable.

    Code:
    listen_hostname_port=20000
    
    This is the port that you want the plugin to listen on. I recommend leaving it as 20000 since that is the default for your users. You need to forward port 20000 to port 20000 on your server, if you are behind a router.

    It's in the OP.

    Server
    Download .jar file and place it in the plugins directory
    Forward external port 20000 to port 20000 on your server

    Players (not on the same computer as the server)


    • Download .jar file and double-click
    • Enter your server's details
    • Press start
    • Connect to localhost with their client
    Players (on the same computer as the server)

    • Download .jar file and double-click
    • Change the listen port for the local server
    • Instead of 25565, use 25564
    • Press start
    • Connect to localhost:25564 with their client

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
  3. Offline

    Pim1234

    if I follow that i can't get it to work :p
     
  4. Offline

    Raphfrk

    More info needed. Please post the server logs.

    What are the settings on the GUI when you press start?
     
  5. Offline

    Pim1234

    wel these are my settings 1.png
    when i press connect i get this 2.png 3.png
     
  6. Offline

    Raphfrk

    First the client version is not the text 1.15.01.

    It is the protocol version. Just leave it as default (blank)

    That might fix it, but I think you also need to use the "more reliable" way of setting up the default_server.

    I explain it in the Faq.

    What does "replace with <local-ip of server>:25565" mean
     
    Pim1234 likes this.
  7. Offline

    MineMac

    Hi great plugin so far , 2 Questions came up: wether this is planned / possible:

    1) Server <-(Inet)->Router <-(Lan)->Proxy<->Multiple Players
    2)Server-> Proxy_Pool<-(Inet)->Router <-(Lan)->Player

    thanks in advance
     
  8. Offline

    Raphfrk

    Yes, I assume you mean

    1) Server <-> Plugin Proxy <-(Inet)->Router <-(Lan)->Proxy<->Multiple Players

    See the OP on starting from the command line.

    You run this on the local-proxy-computer

    java -jar CraftProxyLite.jar 25565 <target-server-hostname>:20000 local_cache quiet bridge_connection

    Players connect to

    <local-proxy-computer>

    Yes, again, is this to spread the proxy load over multiple proxies?

    However, you would need players to connect to different ports or hostnames, or order to connect to different proxies.
     
  9. Offline

    Pim1234

    does my hamachi ip count as local ip?
     
  10. Offline

    Raphfrk

    Yeah.
     
    Pim1234 likes this.
  11. Offline

    Pim1234

    wow! you are amazing!
    you must be a god for being able to help someone like me :p
     
  12. Offline

    MineMac

    Server-> Proxy_Pool<-(Inet)->Router <-(Lan)->Player

    Yes exactly, it would be a great feature to make even "bigger servers" or "lag free servers".
     
  13. Offline

    mireka

    Just a thought : Should have a P2P feature where clients will send chunks to each other to further reduce load on the server.
     
  14. Offline

    Raphfrk

    I doubt that would be fast enough.

    You need chunks "now" :).

    It might be useful for sending the entire world for pre-caching though.
     
  15. Offline

    Pim1234

    well, i'm sorry to bother you again...
    when i connect from my other pc (works fine on the server-pc now) i can't connect using localhost:25565, 25564, 20000 or 20001...
    what am i doing wrong this time?

    should i just leave the port empty?
    just "localhost" and nothing around it?
     
  16. Offline

    Raphfrk

    The local server should localhost and 25565 and the remote host should be the IP of the other computer and port 20000.

    However, some modern OS systems have firewalls that block everything.

    You could try to turn it off for a second.
     
  17. Offline

    Pim1234

    i don't quietly understand this yet...
    what should my friends fill in and what should i fill in on my serverfree pc??
     
  18. Offline

    Raphfrk

    It is on the OP. I would recommend that you stick with the defaults until you have it working.


    Server

    Basic

    Download .jar file and place it in the plugins directory
    Forward external port 20000 to port 20000 on your server

    Sometimes Required

    • start server
    • stop server
    • open /plugins/Craft Proxy Lite/proxylite.txt
    • find default_server=25565
    • replace with <local-ip of server>:25565 (see Faq for more info)
    • start server again
    Players

    Not on the same computer as the server
    • Download .jar file and double-click
    • Enter your server's details
    • Press start
    • Connect to localhost with their client
    On the same computer as the server
    • Download .jar file and double-click
    • Change the listen port for the local server
    • Instead of 25565, use 25564
    • Press start
    • Connect to localhost:25564 with their client
     
  19. Offline

    turtlelink2

    how exactly would I use this AND mineshafter proxy? would they need to be combined into 1 super proxy?
     
  20. Offline

    mireka

    That also sounds exceptionally good.
    Any plans on implementing it? :)
     
  21. Offline

    Pim1234

    how much does this actually help?
     
  22. Offline

    Raphfrk

    Haven't heard of that. What does it do?

    Into the GUI in the Remote Server -> Name box

    About 70-75% reduction in upload bandwidth for me.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: May 14, 2016
  23. Offline

    Chojin

    Is there any way to keep online-mode=on on servers ? The fact is I need mcbans and mcbans does not work if online-mode=off :eek:

    I use ServerPort and so multiple servers.
     
  24. Offline

    ledhead900

    This appears to be working good but do you care to explain what each of the other options do in the config I had some say that they got a String error on disconnect

    whats that about ?
     
  25. Offline

    Raphfrk

    If you want to use the proxy to auto-reconnect, then you have to leave the servers in offline-mode.

    Since the proxy doesn't know the players' usernames, it can't log in for them otherwise.

    You can use the proxy for caching though in online mode.
     
  26. Offline

    MatCat

    Ok how does one adjust the cache size client side? Also what is the default cache size, and what would you recommend? Also is it using threads for compress/decompress stage to take advantage of multi core?
     
  27. Offline

    Raphfrk

    There is a box on the GUI. You type in the number in MB. I guess 50MB or so should be Ok.

    Yes, it uses threads.
     
  28. Offline

    ledhead900


    Aw you replied to two people but did not reply to my post that was above your reply to someone else.
     
  29. Offline

    Raphfrk

    Dunno, can you post logs. Also, I did list the other options in an earlier post. They are mostly for supporting Server Port, so aren't needed.
     
  30. Offline

    ledhead900

    I'm talking more about the non obviouse like

    disable_flood=false
    monitor=
    dimension=
    quiet=true
    reconnectfile=

    None them have any explination at all and Im just wanting to know to best tune the server.

    here is the log from console doupt ud find anything interesting but it would be from todays day the 7th/05

    Edit:

    O earilier post sorry bit sleepy yea I was kinda hoping they would be in the OP under a spolier or something dig dig time for that post then.

    Oh and the OP setup guide is a little rough I found it easier to jsut wing it with light reading but all ports and things are not explained well for the noobs.

    for most part not all of us use the standard minecraft port I use 7767 its below the radar for most things. So I had to set the local thing in the config to that port.

    Tho it works I got it first time no fuss but I read a lot of people are getting fuzzled over the local port thing I do use the IP:port tho as yea its far more reliable to fill in kinks in the chain to avoid possible other kinks later.

    I just really wanted to see a full list of what each one does in detail regadless if its for port or not its interesting to me given the fact most of the users gained less laggy play.

    I do have one question with it rahther about its compatability
    with other plugins that handle chunk data such as http://forums.bukkit.org/threads/me...nimizer-and-more-740.15827/page-4#post-277187


    Anyway mate you seem to have a good thing going here keep up the good work its tops really helps with the bandwidth I will probably get some sort of monitoring going now I know what the monitor thing did - still have not seen the FULL list of options at least not in the past 2 pages but I dont have time tonight to to start from top to bottom.

    Good news is most users are expeirenceing better connection thats the main thing.
    Tho its a real shame Notch was to blind or dumb to do this to start with from the get go I mean too me hosting a map on one or the others end with no cache is jsut fucking retarded.

    I know its a client - server relationship but man some optimizations along the way would greatly smooth out the network side.

    EDIT

    Ok I found the list of but it did not cover the info=

    also some players are telling me this is causing more invalid packet ID Dissconects for them or random Disconnects when run with out it there issue is resolved.

    any Idea's I'm also +1 for removing compression no need to do this its just wasting cycles.
    If your going to do this compress as it sends the hash and data and decompress on client end.

    then Compress again only on SEND screw decrompession on server end.
     

    Attached Files:

  31. Offline

    Simanova

    This tool is brilliant!

    My server can now handle 6 instead of only 2 people!!!
     

Share This Page