Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0008227opensim[GRID] Hypergridpublic2017-08-08 07:572017-08-11 14:29
Assigned To 
PlatformUbuntu 17 Server + Windows 10OSAllOS VersionAll
Product Versionmaster (dev code) 
Target VersionFixed in Version 
Summary0008227: SYSTEMIP does not work correctly
Description### SYSTEMIP does not work correctly

SYSTEMIP = 192.168.1.x is not an external IP

ExternalHostName = SYSTEMIP // Does not work correctly

SYSTEMIP = ${Const|BaseHostname} // Does not work
Steps To ReproduceUbuntu 17 Server + Windows 10 HomePC -> Network -> Internet Router

##Linux bash extern real IP Test working:
EXTSYSTEMIP=$(curl -s [^] | sed 's/[a-zA-Z<>/ :]//g')

Correct IP
Additional Information## C# Test(I'm not a C# programmer):
# The configuration of the service must be adjustable in Opensim.ini.
# service testing
# "" [^]
# "" [^]
# "" [^]

# Examples untested:

using System.Net;
using System.IO;

public IPAddress EXTSYSTEMIP()
    WebRequest hwr = HttpWebRequest.Create(new Uri("" [^]));
    WebResponse wr = hwr.GetResponse();
    Stream stream = wr.GetResponseStream();
    StreamReader streamReader = new StreamReader(stream, Encoding.UTF8);
    string htmlResult = streamReader.ReadToEnd();
    string[] htmlSplit = htmlResult.Split(new string[]{":", "<"}, StringSplitOptions.RemoveEmptyEntries);
    string IP = htmlSplit[6].Trim();
    return IPAddress.Parse(IP);

## or

using System.IO;
using System.Net;

            HttpWebRequest req = (HttpWebRequest)WebRequest.Create("" [^]);
            HttpWebResponse res = (HttpWebResponse)req.GetResponse();
            StreamReader str = new StreamReader(res.GetResponseStream());
            string ip = str.ReadToEnd();
            return IPAddress.Parse(ip);

## or

using System;
using System.Net;
using System.IO;
using System.Text.RegularExpressions;

static string[] EXTSYSTEMIP()
        WebRequest req = WebRequest.Create("" [^]);
        WebResponse res = req.GetResponse();
        Stream s = res.GetResponseStream();
        StreamReader sr = new StreamReader(s);
        string streamTxt = sr.ReadToEnd();
        Regex rx = new Regex(@"(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\b");
        MatchCollection mc = rx.Matches(streamTxt);
        string[] retStr = new string[mc.Count];
        for(int i = 0; i < mc.Count; i++)
                retStr[i] = mc[i].Value.ToString();
        return retStr;
TagsNo tags attached.
Git Revision or version number
Run Mode Grid (Multiple Regions per Sim)
Physics EngineBulletSim
Mono Version4.0
Attached Files

- Relationships

-  Notes
UbitUmarov (administrator)
2017-08-08 08:00

SYSTEMIP is as name says it is the system IP, ie the IP seen by OS on its internet stack, not external IP
Manni (reporter)
2017-08-09 03:28

ExternalHostName = SYSTEMIP (SYSTEMIP is as name says it is the system IP, not external IP)
ExternalHostName = external IP or external Name

Newspaper 2015: USA are the IP addresses.
This has already been the case in Europe for some time.
We have to go with time and work with changing IP.
We need something like EXTSYSTEMIP (EXTERNALIP as one might call it.).
This can not be difficult for a programmer to insert such an important thing.

Each grid can host this service itself:
<title><?php echo "My public IP Address"; ?></title>
<?php echo $_SERVER['REMOTE_ADDR']; ?>
UbitUmarov (administrator)
2017-08-09 18:52

if you mean adding a option for a region to discover the external IP, like using a web page as above, that could be a option yes.
Manni (reporter)
2017-08-10 05:31

Yes that would be nice.

For this purpose, an adjustment possibility for a time control, and the IP service would have to be made.


We need to do everything we can to make the OpenSimulator as easy as possible.
It does not work to write programs that nobody can start without programming knowledge.

It is important that this is also included in Gettext [^]

There should be a function load mesh filename.format for the console.
This could be achieved with the ASSIMP library [^]
ASSIMP library can import, export and convert meshfiles.
watcher64 (reporter)
2017-08-10 09:53
edited on: 2017-08-10 09:55

The problem with this is it would cause you to depend on an external service, if that service is down it would fail.

You cannot make this request from a LOCAL service to a LOCAL service because if both are inside the firewall it will return your inside ip. So Opensimulator cannot provide this service locally.

If it is that big of a problem , buy your own web domain , and host the file your self , here is an example ..

SYSTEMIP=`curl [^]`

and for windows you can download the curl.exe and use

for /f %%i in ('curl -s ""' [^]) do set SYSTEMIP=%%i

But again both these options require you to access an EXTERNAL service, they cannot do it locally .. If done locally it is simply going to return the local ip of your system.

I use both these for various things ..

And I disagree that we need to make it "easiest as possible", opensimulator is a very complicated piece of code, and people really should learn a few things before diving off the deep end.

If you want easy , you can use ferds outworldz installer ..

watcher64 (reporter)
2017-08-10 11:09

I provide the following batch file for windows users that want this function, I also provide them with the windows version of curl, [^]

@echo off

@setlocal EnableDelayedExpansion
set ip_address_string="IPv4 Address"

@for /f %%i in ('curl -s ""' [^]) do set SYSTEMIP=%%i
@echo Your External IP is %SYSTEMIP%
@echo You will need this when configuring your region.
@echo You will have to configure your router
@echo to allow the ports through to your PC's
@echo Internal Address.
@echo Typically this region will be configured
@echo on Port 9100
for /f "usebackq tokens=2 delims=:" %%f in (`ipconfig ^| findstr /c:%ip_address_string%`) do echo Your IP Internal Address is: %%f
@echo Visit [^]
@echo for information on forwarding ports.
cd bin
watcher64 (reporter)
2017-08-10 11:23

in linux just add this to your startup script

SYSTEMIP=`curl [^]`
kcozens (administrator)
2017-08-10 13:14

This report could be closed as "not a bug". SYSTEMIP is doing what it is meant to do. The use of it is incorrect in the examples.

If you are running Open Sim on a local LAN and need it to be accessible from the outside world you can use some of the suggestions given in the comments.
Manni (reporter)
2017-08-11 05:45

@ Watcher64 @ kconzens
You do not have to explain this to me.
I've written articles and howto's about it.
Also I have written the program MysysIP.exe for Windows.
If I may, I will gladly send all the people to them.
They seem to have fun always answer the same questions.

It would be great if they would insert external IP.
Many people would be grateful to them.
I have now an Ip service on started. [^]
watcher64 (reporter)
2017-08-11 11:32

I guess you did not understand, SYSTEMIP was never meant to be your EXTERNAL IP .. So it is doing what it is supposed to do, so it is not a bug.

What you suggest is more of a feature request than a bug, since the current behavior is as expected.

And the explanation was for OTHERS that may read this mantis, not everyone else knows everything.

Having Opensimulator rely on an external service like to get an external IP is/would create even more of a support nightmare ..
Manni (reporter)
2017-08-11 12:16

I can not speak much English, so a problem with them.

The people do not understand the SYSTEMIP is not the external IP is because in the Regions.ini stands
ExternalHostName = SYSTEMIP so they think there is external then it must also be an external IP.
We know it is not so, but not others.

This service is disabled in the configuration and does not require any support on your part.

Example: OpenSim.ini:
    ;; ExternalService (true / false) false
    ;; ServiceAddress from an ExternalServices or GridService
    ;; Timer interval in minutes.
    ; ExternaService = true
    ; ServiceAdress "" [^]
    ;ServiceAdressTimer = 60

I have a lot of support without such features.

Just this bad initialTerrain = "pinhead-island" I have Daily work to say how it goes flat.
smxy (reporter)
2017-08-11 14:29

If you want to flatten it, try this at the console:

terrain fill 21

- Issue History
Date Modified Username Field Change
2017-08-08 07:57 Manni New Issue
2017-08-08 08:00 UbitUmarov Note Added: 0032235
2017-08-09 03:28 Manni Note Added: 0032236
2017-08-09 18:52 UbitUmarov Note Added: 0032237
2017-08-10 05:31 Manni Note Added: 0032238
2017-08-10 09:53 watcher64 Note Added: 0032239
2017-08-10 09:55 watcher64 Note Edited: 0032239 View Revisions
2017-08-10 11:09 watcher64 Note Added: 0032240
2017-08-10 11:23 watcher64 Note Added: 0032241
2017-08-10 13:14 kcozens Note Added: 0032242
2017-08-11 05:45 Manni Note Added: 0032243
2017-08-11 11:32 watcher64 Note Added: 0032244
2017-08-11 12:16 Manni Note Added: 0032245
2017-08-11 14:29 smxy Note Added: 0032246

Copyright © 2000 - 2012 MantisBT Group
Powered by Mantis Bugtracker