Mods
Resource Packs
Data Packs
Modpacks
Shaders
Plugins
Mods Resource Packs Data Packs Plugins Shaders Modpacks
Get Modrinth App Upgrade to Modrinth+
Sign in
ModsPluginsData PacksShadersResource PacksModpacks
Sign in
Settings
Fast IP Ping

Fast IP Ping

Yeet the laggy reversed DNS lookup for literal IP server addresses

5.37M
572
Optimization
AboutGalleryChangelogVersions

pinging

Yeet the laggy reversed DNS lookup for literal IP server addresses

Extracted from the yeetServerIpReversedDnsLookup option in TweakerMore Mod

What & Why & How

For servers whose addresses are represented solely by a literal IP, e.g. 192.168.2.10:25565, disable reverse DNS lookups in the corresponding InetAddress object

Many non-loopback IPs lack associated domain names, which makes reverse lookups time-consuming

// java.net.InetAddress#getHostName(boolean)
String getHostName(boolean check) {
    if (holder().getHostName() == null) {  // It will be null if InetAddress.getByName() received a literal IP
        holder().hostName = InetAddress.getHostFromNameService(this, check);  // <-- takes forever
    }
    return holder().getHostName();
}

This option sets the domain of those servers directly to their IP, bypassing the reverse DNS check

This results in a 1s ~ 5s reduction in time for servers with literal IP address. Affects the following environments:

  • Pinging the server in the server list screen
  • Connecting to the server

Environment

  • Client-side only
  • Fabric / Forge / NeoForge mod loader. No extra requirement is needed

90% of ad revenue goes to creators

Support creators and Modrinth ad-free with Modrinth+

Compatibility

Minecraft: Java Edition

1.21.x
1.20.x
1.19.x
1.18.2
1.17.1
1.16.4–1.16.5
1.15.2
1.14.4

Platforms

Fabric
Forge
NeoForge

Supported environments

Client-side

Links

Report issues View source

Creators

fallen-breath
fallen-breath Owner

Details

Licensed LGPL-3.0-only
Published last year
Updated 8 months ago

Modrinth is open source.

main@a0bd011

© Rinth, Inc.

Company

TermsPrivacyRulesCareers

Resources

SupportBlogDocsStatus

Interact

Discord X (Twitter) Mastodon Crowdin
Get Modrinth App Settings
NOT AN OFFICIAL MINECRAFT SERVICE. NOT APPROVED BY OR ASSOCIATED WITH MOJANG OR MICROSOFT.