diff options
author | onefang | 2020-09-08 21:17:45 +1000 |
---|---|---|
committer | onefang | 2020-09-08 21:17:45 +1000 |
commit | dcfd54b7608093d509cd045a152a4cde7317f66f (patch) | |
tree | 593eb822c05a6d209707593732e7e0fac4984663 | |
parent | Various database fixups. (diff) | |
download | opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.zip opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.gz opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.bz2 opensim-SC-dcfd54b7608093d509cd045a152a4cde7317f66f.tar.xz |
Move various paths out of the bin directory.
Diffstat (limited to '')
27 files changed, 82 insertions, 49 deletions
diff --git a/.nant/local.include b/.nant/local.include index be79d1c..07421c8 100644 --- a/.nant/local.include +++ b/.nant/local.include | |||
@@ -5,9 +5,9 @@ | |||
5 | <!-- This target produces a source distribution of OpenSimulator --> | 5 | <!-- This target produces a source distribution of OpenSimulator --> |
6 | <!-- TODO: A few parameters still need to be tweaked after running this - need to do this automatically with sed or similar --> | 6 | <!-- TODO: A few parameters still need to be tweaked after running this - need to do this automatically with sed or similar --> |
7 | <target name="distsrc"> | 7 | <target name="distsrc"> |
8 | <copy file="bin/OpenSim.ini.example" tofile="bin/OpenSim.ini"/> | 8 | <copy file="config/OpenSim.ini.example" tofile="config/OpenSim.ini"/> |
9 | <copy file="bin/config-include/StandaloneCommon.ini.example" tofile="bin/config-include/StandaloneCommon.ini"/> | 9 | <copy file="config/config-include/StandaloneCommon.ini.example" tofile="config/config-include/StandaloneCommon.ini"/> |
10 | <copy file="bin/config-include/FlotsamCache.ini.example" tofile="bin/config-include/FlotsamCache.ini"/> | 10 | <copy file="config/config-include/FlotsamCache.ini.example" tofile="config/config-include/FlotsamCache.ini"/> |
11 | <!-- delete files generated by runprebuild.sh which had to be run in order to generate the build file for this target--> | 11 | <!-- delete files generated by runprebuild.sh which had to be run in order to generate the build file for this target--> |
12 | <delete> | 12 | <delete> |
13 | <fileset basedir="OpenSim"> | 13 | <fileset basedir="OpenSim"> |
diff --git a/OpenSim/Data/SQLite/SQLiteAssetData.cs b/OpenSim/Data/SQLite/SQLiteAssetData.cs index 966d0b8..51d1030 100644 --- a/OpenSim/Data/SQLite/SQLiteAssetData.cs +++ b/OpenSim/Data/SQLite/SQLiteAssetData.cs | |||
@@ -86,7 +86,7 @@ namespace OpenSim.Data.SQLite | |||
86 | 86 | ||
87 | if (dbconnect == string.Empty) | 87 | if (dbconnect == string.Empty) |
88 | { | 88 | { |
89 | dbconnect = "URI=file:Asset.db,version=3"; | 89 | dbconnect = "URI=file:" + Util.dbDir() + "Asset.db,version=3"; |
90 | } | 90 | } |
91 | m_conn = new SqliteConnection(dbconnect); | 91 | m_conn = new SqliteConnection(dbconnect); |
92 | m_conn.Open(); | 92 | m_conn.Open(); |
@@ -360,7 +360,7 @@ namespace OpenSim.Data.SQLite | |||
360 | /// </summary> | 360 | /// </summary> |
361 | override public void Initialise() | 361 | override public void Initialise() |
362 | { | 362 | { |
363 | Initialise("URI=file:Asset.db,version=3"); | 363 | Initialise("URI=file:" + Util.dbDir() + "Asset.db,version=3"); |
364 | } | 364 | } |
365 | 365 | ||
366 | /// <summary> | 366 | /// <summary> |
diff --git a/OpenSim/Data/Tests/BasicDataServiceTest.cs b/OpenSim/Data/Tests/BasicDataServiceTest.cs index 79691e4..580e7aa 100644 --- a/OpenSim/Data/Tests/BasicDataServiceTest.cs +++ b/OpenSim/Data/Tests/BasicDataServiceTest.cs | |||
@@ -106,7 +106,7 @@ namespace OpenSim.Data.Tests | |||
106 | if (String.IsNullOrEmpty(m_connStr)) | 106 | if (String.IsNullOrEmpty(m_connStr)) |
107 | { | 107 | { |
108 | m_file = Path.GetTempFileName() + ".db"; | 108 | m_file = Path.GetTempFileName() + ".db"; |
109 | m_connStr = "URI=file:" + m_file + ",version=3"; | 109 | m_connStr = "URI=file:" + Util.dbDir() + "/" + m_file + ",version=3"; |
110 | } | 110 | } |
111 | } | 111 | } |
112 | 112 | ||
diff --git a/OpenSim/Data/Tests/Resources/TestDataConnections.ini b/OpenSim/Data/Tests/Resources/TestDataConnections.ini index 7b55467..2ddec8b 100644 --- a/OpenSim/Data/Tests/Resources/TestDataConnections.ini +++ b/OpenSim/Data/Tests/Resources/TestDataConnections.ini | |||
@@ -16,9 +16,9 @@ | |||
16 | ; file for the DB. If you want the resulting DB to persist (e.g. for performance testing, | 16 | ; file for the DB. If you want the resulting DB to persist (e.g. for performance testing, |
17 | ; when filling up the tables can take a long time), explicitly specify a conn string like this: | 17 | ; when filling up the tables can take a long time), explicitly specify a conn string like this: |
18 | 18 | ||
19 | ; SqliteConnection="URI=file:<path_to_your_file>,version=3" | 19 | ; SqliteConnection="URI=file:../../db/<path_to_your_file>,version=3" |
20 | 20 | ||
21 | [TestConnections] | 21 | [TestConnections] |
22 | MySqlConnection="Server=localhost;Port=3306;Database=opensim-nunit;User ID=opensim-nunit;Password=opensim-nunit;" | 22 | MySqlConnection="Server=localhost;Port=3306;Database=opensim-nunit;User ID=opensim-nunit;Password=opensim-nunit;" |
23 | SqlConnection="Server=.\SQL2008;Database=opensim-nunit;Trusted_Connection=True;" | 23 | SqlConnection="Server=.\SQL2008;Database=opensim-nunit;Trusted_Connection=True;" |
24 | SqliteConnection="URI=file:opensim-nunit.db,version=3" \ No newline at end of file | 24 | SqliteConnection="URI=file:../../db/opensim-nunit.db,version=3" |
diff --git a/OpenSim/Framework/Console/LocalConsole.cs b/OpenSim/Framework/Console/LocalConsole.cs index e1492b8..f84d21c 100755 --- a/OpenSim/Framework/Console/LocalConsole.cs +++ b/OpenSim/Framework/Console/LocalConsole.cs | |||
@@ -96,9 +96,9 @@ namespace OpenSim.Framework.Console | |||
96 | return; | 96 | return; |
97 | } | 97 | } |
98 | 98 | ||
99 | string m_historyFile = startupConfig.GetString("ConsoleHistoryFile", "OpenSimConsoleHistory.txt"); | 99 | string m_historyFile = startupConfig.GetString("ConsoleHistoryFile", Path.Combine(Util.logsDir(), "OpenSimConsoleHistory.txt")); |
100 | int m_historySize = startupConfig.GetInt("ConsoleHistoryFileLines", 100); | 100 | int m_historySize = startupConfig.GetInt("ConsoleHistoryFileLines", 100); |
101 | m_historyPath = Path.GetFullPath(Path.Combine(Util.configDir(), m_historyFile)); | 101 | m_historyPath = Path.GetFullPath(m_historyFile); |
102 | m_historytimestamps = startupConfig.GetBoolean("ConsoleHistoryTimeStamp", false); | 102 | m_historytimestamps = startupConfig.GetBoolean("ConsoleHistoryTimeStamp", false); |
103 | m_log.InfoFormat("[LOCAL CONSOLE]: Persistent command line history is Enabled, up to {0} lines from file {1} {2} timestamps", | 103 | m_log.InfoFormat("[LOCAL CONSOLE]: Persistent command line history is Enabled, up to {0} lines from file {1} {2} timestamps", |
104 | m_historySize, m_historyPath, m_historytimestamps?"with":"without"); | 104 | m_historySize, m_historyPath, m_historytimestamps?"with":"without"); |
diff --git a/OpenSim/Framework/Util.cs b/OpenSim/Framework/Util.cs index e0e35db..cc449af 100644 --- a/OpenSim/Framework/Util.cs +++ b/OpenSim/Framework/Util.cs | |||
@@ -1304,8 +1304,19 @@ namespace OpenSim.Framework | |||
1304 | return Path.Combine(configDir(), "inventory"); | 1304 | return Path.Combine(configDir(), "inventory"); |
1305 | } | 1305 | } |
1306 | 1306 | ||
1307 | public static string dbDir() | ||
1308 | { | ||
1309 | return Path.Combine("..", Path.Combine("..", "db")); | ||
1310 | } | ||
1311 | |||
1312 | public static string cacheDir() | ||
1313 | { | ||
1314 | return Path.Combine("..", Path.Combine("..", "caches")); | ||
1315 | } | ||
1316 | |||
1307 | public static string configDir() | 1317 | public static string configDir() |
1308 | { | 1318 | { |
1319 | // return Path.Combine("..", Path.Combine("..", "config")); | ||
1309 | return "."; | 1320 | return "."; |
1310 | } | 1321 | } |
1311 | 1322 | ||
@@ -1314,6 +1325,16 @@ namespace OpenSim.Framework | |||
1314 | return "."; | 1325 | return "."; |
1315 | } | 1326 | } |
1316 | 1327 | ||
1328 | public static string logsDir() | ||
1329 | { | ||
1330 | return Path.Combine("..", "logs"); | ||
1331 | } | ||
1332 | |||
1333 | public static string webDir() | ||
1334 | { | ||
1335 | return Path.Combine("..", Path.Combine("..", "web")); | ||
1336 | } | ||
1337 | |||
1317 | public static string logFile() | 1338 | public static string logFile() |
1318 | { | 1339 | { |
1319 | foreach (IAppender appender in LogManager.GetRepository().GetAppenders()) | 1340 | foreach (IAppender appender in LogManager.GetRepository().GetAppenders()) |
@@ -1324,7 +1345,7 @@ namespace OpenSim.Framework | |||
1324 | } | 1345 | } |
1325 | } | 1346 | } |
1326 | 1347 | ||
1327 | return "./OpenSim.log"; | 1348 | return Path.Combine(logsDir(), "OpenSim.log"); |
1328 | } | 1349 | } |
1329 | 1350 | ||
1330 | public static string statsLogFile() | 1351 | public static string statsLogFile() |
@@ -1337,7 +1358,7 @@ namespace OpenSim.Framework | |||
1337 | } | 1358 | } |
1338 | } | 1359 | } |
1339 | 1360 | ||
1340 | return "./OpenSimStats.log"; | 1361 | return Path.Combine(logsDir(), "OpenSimStats.log"); |
1341 | } | 1362 | } |
1342 | 1363 | ||
1343 | public static string logDir() | 1364 | public static string logDir() |
diff --git a/OpenSim/Region/Application/ConfigurationLoader.cs b/OpenSim/Region/Application/ConfigurationLoader.cs index 66e46cb..02a9941 100644 --- a/OpenSim/Region/Application/ConfigurationLoader.cs +++ b/OpenSim/Region/Application/ConfigurationLoader.cs | |||
@@ -153,15 +153,14 @@ namespace OpenSim | |||
153 | } | 153 | } |
154 | 154 | ||
155 | // Override distro settings with contents of inidirectory | 155 | // Override distro settings with contents of inidirectory |
156 | string iniDirName = startupConfig.GetString("inidirectory", "config"); | 156 | string iniDirPath = startupConfig.GetString("inidirectory", Util.configDir()); |
157 | string iniDirPath = Path.Combine(Util.configDir(), iniDirName); | ||
158 | 157 | ||
159 | if (Directory.Exists(iniDirPath)) | 158 | if (Directory.Exists(iniDirPath)) |
160 | { | 159 | { |
161 | m_log.InfoFormat("[CONFIG]: Searching folder {0} for config ini files", iniDirPath); | 160 | m_log.InfoFormat("[CONFIG]: Searching folder {0} for config ini files", iniDirPath); |
162 | List<string> overrideSources = new List<string>(); | 161 | List<string> overrideSources = new List<string>(); |
163 | 162 | ||
164 | string[] fileEntries = Directory.GetFiles(iniDirName); | 163 | string[] fileEntries = Directory.GetFiles(iniDirPath); |
165 | foreach (string filePath in fileEntries) | 164 | foreach (string filePath in fileEntries) |
166 | { | 165 | { |
167 | if (Path.GetExtension(filePath).ToLower() == ".ini") | 166 | if (Path.GetExtension(filePath).ToLower() == ".ini") |
diff --git a/OpenSim/Region/CoreModules/Asset/FlotsamAssetCache.cs b/OpenSim/Region/CoreModules/Asset/FlotsamAssetCache.cs index bbf7be7..238fbab 100755 --- a/OpenSim/Region/CoreModules/Asset/FlotsamAssetCache.cs +++ b/OpenSim/Region/CoreModules/Asset/FlotsamAssetCache.cs | |||
@@ -66,7 +66,7 @@ namespace OpenSim.Region.CoreModules.Asset | |||
66 | private bool m_cleanupRunning; | 66 | private bool m_cleanupRunning; |
67 | 67 | ||
68 | private const string m_ModuleName = "FlotsamAssetCache"; | 68 | private const string m_ModuleName = "FlotsamAssetCache"; |
69 | private const string m_DefaultCacheDirectory = "./assetcache"; | 69 | private const string m_DefaultCacheDirectory = "assetcache"; |
70 | private string m_CacheDirectory = m_DefaultCacheDirectory; | 70 | private string m_CacheDirectory = m_DefaultCacheDirectory; |
71 | 71 | ||
72 | private readonly List<char> m_InvalidChars = new List<char>(); | 72 | private readonly List<char> m_InvalidChars = new List<char>(); |
diff --git a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs index 4c922ba..ce5e167 100644 --- a/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs +++ b/OpenSim/Region/CoreModules/World/Warp3DMap/Warp3DImageModule.cs | |||
@@ -83,6 +83,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
83 | private bool m_texturePrims = true; // true if should texture the rendered prims | 83 | private bool m_texturePrims = true; // true if should texture the rendered prims |
84 | private float m_texturePrimSize = 48f; // size of prim before we consider texturing it | 84 | private float m_texturePrimSize = 48f; // size of prim before we consider texturing it |
85 | private bool m_renderMeshes = false; // true if to render meshes rather than just bounding boxes | 85 | private bool m_renderMeshes = false; // true if to render meshes rather than just bounding boxes |
86 | private String m_cacheDirectory = ""; | ||
86 | private float m_renderMinHeight = -100f; | 87 | private float m_renderMinHeight = -100f; |
87 | private float m_renderMaxHeight = 4096f; | 88 | private float m_renderMaxHeight = 4096f; |
88 | 89 | ||
@@ -119,6 +120,11 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
119 | Util.GetConfigVarFromSections<float>(m_config, "TexturePrimSize", configSections, m_texturePrimSize); | 120 | Util.GetConfigVarFromSections<float>(m_config, "TexturePrimSize", configSections, m_texturePrimSize); |
120 | m_renderMeshes = | 121 | m_renderMeshes = |
121 | Util.GetConfigVarFromSections<bool>(m_config, "RenderMeshes", configSections, m_renderMeshes); | 122 | Util.GetConfigVarFromSections<bool>(m_config, "RenderMeshes", configSections, m_renderMeshes); |
123 | m_cacheDirectory | ||
124 | = Util.GetConfigVarFromSections<string>(m_config, "CacheDirectory", configSections, System.IO.Path.Combine(Util.cacheDir(), "MapImageCache")); | ||
125 | |||
126 | if (!Directory.Exists(m_cacheDirectory)) | ||
127 | Directory.CreateDirectory(m_cacheDirectory); | ||
122 | 128 | ||
123 | m_renderMaxHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMaxHeight", configSections, m_renderMaxHeight); | 129 | m_renderMaxHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMaxHeight", configSections, m_renderMaxHeight); |
124 | m_renderMinHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMinHeight", configSections, m_renderMinHeight); | 130 | m_renderMinHeight = Util.GetConfigVarFromSections<float>(m_config, "RenderMinHeight", configSections, m_renderMinHeight); |
@@ -210,7 +216,7 @@ namespace OpenSim.Region.CoreModules.World.Warp3DMap | |||
210 | 216 | ||
211 | Bitmap tile = GenImage(); | 217 | Bitmap tile = GenImage(); |
212 | // image may be reloaded elsewhere, so no compression format | 218 | // image may be reloaded elsewhere, so no compression format |
213 | string filename = "MAP-" + m_scene.RegionInfo.RegionID.ToString() + ".png"; | 219 | string filename = System.IO.Path.Combine(m_cacheDirectory,"MAP-" + m_scene.RegionInfo.RegionID.ToString() + ".png"); |
214 | tile.Save(filename, ImageFormat.Png); | 220 | tile.Save(filename, ImageFormat.Png); |
215 | m_primMesher = null; | 221 | m_primMesher = null; |
216 | return tile; | 222 | return tile; |
diff --git a/OpenSim/Region/OptionalModules/UserStatistics/WebStatsModule.cs b/OpenSim/Region/OptionalModules/UserStatistics/WebStatsModule.cs index c15b194..f76b057 100644 --- a/OpenSim/Region/OptionalModules/UserStatistics/WebStatsModule.cs +++ b/OpenSim/Region/OptionalModules/UserStatistics/WebStatsModule.cs | |||
@@ -96,7 +96,7 @@ namespace OpenSim.Region.UserStatistics | |||
96 | 96 | ||
97 | //IConfig startupConfig = config.Configs["Startup"]; | 97 | //IConfig startupConfig = config.Configs["Startup"]; |
98 | 98 | ||
99 | dbConn = new SqliteConnection("URI=file:LocalUserStatistics.db,version=3"); | 99 | dbConn = new SqliteConnection("URI=file:" + Util.dbDir() + "/LocalUserStatistics.db,version=3"); |
100 | dbConn.Open(); | 100 | dbConn.Open(); |
101 | CreateTables(dbConn); | 101 | CreateTables(dbConn); |
102 | 102 | ||
@@ -1200,4 +1200,4 @@ VALUES | |||
1200 | m_scriptLinesPerSecond = stats.ExtraStatsBlock[0].StatValue; | 1200 | m_scriptLinesPerSecond = stats.ExtraStatsBlock[0].StatValue; |
1201 | } | 1201 | } |
1202 | } | 1202 | } |
1203 | } \ No newline at end of file | 1203 | } |
diff --git a/OpenSim/Region/PhysicsModules/Meshing/Meshmerizer/Meshmerizer.cs b/OpenSim/Region/PhysicsModules/Meshing/Meshmerizer/Meshmerizer.cs index de39d0e..93c2986 100644 --- a/OpenSim/Region/PhysicsModules/Meshing/Meshmerizer/Meshmerizer.cs +++ b/OpenSim/Region/PhysicsModules/Meshing/Meshmerizer/Meshmerizer.cs | |||
@@ -99,7 +99,7 @@ namespace OpenSim.Region.PhysicsModule.Meshing | |||
99 | 99 | ||
100 | IConfig mesh_config = source.Configs["Mesh"]; | 100 | IConfig mesh_config = source.Configs["Mesh"]; |
101 | 101 | ||
102 | decodedSculptMapPath = config.GetString("DecodedSculptMapPath", "j2kDecodeCache"); | 102 | decodedSculptMapPath = config.GetString("DecodedSculptMapPath", System.IO.Path.Combine(Util.cacheDir(), "j2kDecodeCache")); |
103 | cacheSculptMaps = config.GetBoolean("CacheSculptMaps", cacheSculptMaps); | 103 | cacheSculptMaps = config.GetBoolean("CacheSculptMaps", cacheSculptMaps); |
104 | if (mesh_config != null) | 104 | if (mesh_config != null) |
105 | { | 105 | { |
diff --git a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs index ac32f75..66c376c 100644 --- a/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs +++ b/OpenSim/Region/PhysicsModules/ubOdeMeshing/Meshmerizer.cs | |||
@@ -64,7 +64,7 @@ namespace OpenSim.Region.PhysicsModule.ubODEMeshing | |||
64 | 64 | ||
65 | public bool doMeshFileCache = true; | 65 | public bool doMeshFileCache = true; |
66 | public bool doCacheExpire = true; | 66 | public bool doCacheExpire = true; |
67 | public string cachePath = "MeshCache"; | 67 | public string cachePath = System.IO.Path.Combine(Util.cacheDir(), "MeshCache"); |
68 | public TimeSpan CacheExpire; | 68 | public TimeSpan CacheExpire; |
69 | 69 | ||
70 | // const string baseDir = "rawFiles"; | 70 | // const string baseDir = "rawFiles"; |
diff --git a/OpenSim/Region/ScriptEngine/Shared/AssemblyResolver.cs b/OpenSim/Region/ScriptEngine/Shared/AssemblyResolver.cs index e35f79f..6c42e2e 100644 --- a/OpenSim/Region/ScriptEngine/Shared/AssemblyResolver.cs +++ b/OpenSim/Region/ScriptEngine/Shared/AssemblyResolver.cs | |||
@@ -44,7 +44,7 @@ namespace OpenSim.Region.ScriptEngine.Shared | |||
44 | string dirName = myDomain.FriendlyName; | 44 | string dirName = myDomain.FriendlyName; |
45 | string ScriptEnginesPath = myDomain.SetupInformation.PrivateBinPath; | 45 | string ScriptEnginesPath = myDomain.SetupInformation.PrivateBinPath; |
46 | 46 | ||
47 | string[] pathList = new string[] {"", "bin", ScriptEnginesPath, | 47 | string[] pathList = new string[] {"", "caches", ScriptEnginesPath, |
48 | Path.Combine(ScriptEnginesPath, dirName)}; | 48 | Path.Combine(ScriptEnginesPath, dirName)}; |
49 | 49 | ||
50 | string assemblyName = args.Name; | 50 | string assemblyName = args.Name; |
diff --git a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs index 9e47530..b225aad 100755 --- a/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs +++ b/OpenSim/Region/ScriptEngine/XEngine/XEngine.cs | |||
@@ -315,7 +315,7 @@ namespace OpenSim.Region.ScriptEngine.XEngine | |||
315 | m_WaitForEventCompletionOnScriptStop | 315 | m_WaitForEventCompletionOnScriptStop |
316 | = m_ScriptConfig.GetInt("WaitForEventCompletionOnScriptStop", m_WaitForEventCompletionOnScriptStop); | 316 | = m_ScriptConfig.GetInt("WaitForEventCompletionOnScriptStop", m_WaitForEventCompletionOnScriptStop); |
317 | 317 | ||
318 | m_ScriptEnginesPath = m_ScriptConfig.GetString("ScriptEnginesPath", "ScriptEngines"); | 318 | m_ScriptEnginesPath = m_ScriptConfig.GetString("ScriptEnginesPath", Path.Combine(Util.cacheDir(), "ScriptEngines")); |
319 | 319 | ||
320 | m_Prio = ThreadPriority.BelowNormal; | 320 | m_Prio = ThreadPriority.BelowNormal; |
321 | switch (priority) | 321 | switch (priority) |
diff --git a/OpenSim/Server/Base/ServicesServerBase.cs b/OpenSim/Server/Base/ServicesServerBase.cs index 3bede45..8c16f61 100755 --- a/OpenSim/Server/Base/ServicesServerBase.cs +++ b/OpenSim/Server/Base/ServicesServerBase.cs | |||
@@ -85,7 +85,7 @@ namespace OpenSim.Server.Base | |||
85 | string fileName = ""; | 85 | string fileName = ""; |
86 | if (Assembly.GetEntryAssembly() != null) | 86 | if (Assembly.GetEntryAssembly() != null) |
87 | fileName = Path.GetFileNameWithoutExtension(Assembly.GetEntryAssembly().Location); | 87 | fileName = Path.GetFileNameWithoutExtension(Assembly.GetEntryAssembly().Location); |
88 | string iniFile = fileName + ".ini"; | 88 | string iniFile = Path.Combine(Util.configDir(), fileName + ".ini"); |
89 | string logConfig = null; | 89 | string logConfig = null; |
90 | 90 | ||
91 | IConfig startupConfig = argvConfig.Configs["Startup"]; | 91 | IConfig startupConfig = argvConfig.Configs["Startup"]; |
diff --git a/OpenSim/Server/Handlers/BakedTextures/XBakes.cs b/OpenSim/Server/Handlers/BakedTextures/XBakes.cs index 4e55433..0c74564 100644 --- a/OpenSim/Server/Handlers/BakedTextures/XBakes.cs +++ b/OpenSim/Server/Handlers/BakedTextures/XBakes.cs | |||
@@ -67,12 +67,7 @@ namespace OpenSim.Server.Handlers.BakedTextures | |||
67 | throw new Exception("No BakedTextureService configuration"); | 67 | throw new Exception("No BakedTextureService configuration"); |
68 | } | 68 | } |
69 | 69 | ||
70 | m_FSBase = assetConfig.GetString("BaseDirectory", String.Empty); | 70 | m_FSBase = assetConfig.GetString("BaseDirectory", Util.cacheDir() + "/bakes"); |
71 | if (m_FSBase == String.Empty) | ||
72 | { | ||
73 | m_log.ErrorFormat("[BAKES]: BaseDirectory not specified"); | ||
74 | throw new Exception("Configuration error"); | ||
75 | } | ||
76 | 71 | ||
77 | m_log.Info("[BAKES]: XBakes service enabled"); | 72 | m_log.Info("[BAKES]: XBakes service enabled"); |
78 | } | 73 | } |
diff --git a/OpenSim/Services/GridService/HypergridLinker.cs b/OpenSim/Services/GridService/HypergridLinker.cs index 9c66e3d..4f5fe59 100644 --- a/OpenSim/Services/GridService/HypergridLinker.cs +++ b/OpenSim/Services/GridService/HypergridLinker.cs | |||
@@ -95,7 +95,8 @@ namespace OpenSim.Services.GridService | |||
95 | 95 | ||
96 | // m_Check4096 = gridConfig.GetBoolean("Check4096", true); | 96 | // m_Check4096 = gridConfig.GetBoolean("Check4096", true); |
97 | 97 | ||
98 | m_MapTileDirectory = gridConfig.GetString("MapTileDirectory", "maptiles"); | 98 | //// TODO OpenSim is crazy, this is called from Robust and OpenSim, Robust needs the ../caches bit, OpenSim somehow adds a path already. I can't tell why. So strip the path. |
99 | m_MapTileDirectory = Path.Combine(Util.cacheDir(), Path.GetFileName(gridConfig.GetString("MapTileDirectory", "maptiles"))); | ||
99 | 100 | ||
100 | m_ThisGatekeeperURI = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", | 101 | m_ThisGatekeeperURI = Util.GetConfigVarFromSections<string>(config, "GatekeeperURI", |
101 | new string[] { "Startup", "Hypergrid", "GridService" }, String.Empty); | 102 | new string[] { "Startup", "Hypergrid", "GridService" }, String.Empty); |
diff --git a/OpenSim/Services/MapImageService/MapImageService.cs b/OpenSim/Services/MapImageService/MapImageService.cs index 30d3e41..9c5e0bb 100644 --- a/OpenSim/Services/MapImageService/MapImageService.cs +++ b/OpenSim/Services/MapImageService/MapImageService.cs | |||
@@ -63,7 +63,7 @@ namespace OpenSim.Services.MapImageService | |||
63 | private const int HALF_WIDTH = 128; | 63 | private const int HALF_WIDTH = 128; |
64 | private const int JPEG_QUALITY = 80; | 64 | private const int JPEG_QUALITY = 80; |
65 | 65 | ||
66 | private static string m_TilesStoragePath = "maptiles"; | 66 | private static string m_TilesStoragePath = Path.Combine(Util.cacheDir(), "/maptiles"); |
67 | 67 | ||
68 | private static object m_Sync = new object(); | 68 | private static object m_Sync = new object(); |
69 | private static bool m_Initialized = false; | 69 | private static bool m_Initialized = false; |
diff --git a/OpenSim/Tests/Robust/Server/DemonServer.cs b/OpenSim/Tests/Robust/Server/DemonServer.cs index 1e0797e..41c2185 100644 --- a/OpenSim/Tests/Robust/Server/DemonServer.cs +++ b/OpenSim/Tests/Robust/Server/DemonServer.cs | |||
@@ -48,8 +48,8 @@ namespace Robust.Tests | |||
48 | [SetUp] | 48 | [SetUp] |
49 | public void StartDemon() | 49 | public void StartDemon() |
50 | { | 50 | { |
51 | if (File.Exists("Robust.Tests.log")) | 51 | if (File.Exists("../../logs/Robust.Tests.log")) |
52 | File.Delete("Robust.Tests.log"); | 52 | File.Delete("../../logs/Robust.Tests.log"); |
53 | 53 | ||
54 | Console.WriteLine("**** Starting demon Robust server ****"); | 54 | Console.WriteLine("**** Starting demon Robust server ****"); |
55 | m_demon = new Thread( () => Main(new string[] {"-inifile=Robust.Tests.ini"})); | 55 | m_demon = new Thread( () => Main(new string[] {"-inifile=Robust.Tests.ini"})); |
diff --git a/bin/OpenSim.ConsoleClient.exe.config b/bin/OpenSim.ConsoleClient.exe.config index 3a50408..6542517 100644 --- a/bin/OpenSim.ConsoleClient.exe.config +++ b/bin/OpenSim.ConsoleClient.exe.config | |||
@@ -18,7 +18,7 @@ | |||
18 | </appender> | 18 | </appender> |
19 | 19 | ||
20 | <appender name="LogFileAppender" type="log4net.Appender.FileAppender"> | 20 | <appender name="LogFileAppender" type="log4net.Appender.FileAppender"> |
21 | <file value="OpenSim.ConsoleClient.log" /> | 21 | <file value="../../logs/OpenSim.ConsoleClient.log" /> |
22 | <appendToFile value="true" /> | 22 | <appendToFile value="true" /> |
23 | <layout type="log4net.Layout.PatternLayout"> | 23 | <layout type="log4net.Layout.PatternLayout"> |
24 | <conversionPattern value="%date %-5level - %logger %message%newline" /> | 24 | <conversionPattern value="%date %-5level - %logger %message%newline" /> |
diff --git a/bin/OpenSim.exe.config b/bin/OpenSim.exe.config index 5be6989..690f808 100755 --- a/bin/OpenSim.exe.config +++ b/bin/OpenSim.exe.config | |||
@@ -24,7 +24,8 @@ | |||
24 | 24 | ||
25 | <!-- If you want automatic log-rolling then use RollingFileAppender instead of FileAppender: | 25 | <!-- If you want automatic log-rolling then use RollingFileAppender instead of FileAppender: |
26 | <appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender"> | 26 | <appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender"> |
27 | <file value="log/OpenSim.log" /> | 27 | <threshold value="DEBUG" /> |
28 | <file value="../../logs/OpenSim.log" /> | ||
28 | <rollingStyle value="Date" /> | 29 | <rollingStyle value="Date" /> |
29 | <datePattern value="'.'yyyy-MM-dd"/> | 30 | <datePattern value="'.'yyyy-MM-dd"/> |
30 | ... | 31 | ... |
@@ -44,7 +45,7 @@ | |||
44 | </appender> | 45 | </appender> |
45 | 46 | ||
46 | <appender name="StatsLogFileAppender" type="log4net.Appender.FileAppender"> | 47 | <appender name="StatsLogFileAppender" type="log4net.Appender.FileAppender"> |
47 | <file value="OpenSimStats.log"/> | 48 | <file value="../../logs/OpenSimStats.log"/> |
48 | <appendToFile value="true" /> | 49 | <appendToFile value="true" /> |
49 | <layout type="log4net.Layout.PatternLayout"> | 50 | <layout type="log4net.Layout.PatternLayout"> |
50 | <conversionPattern value="%date - %message%newline" /> | 51 | <conversionPattern value="%date - %message%newline" /> |
diff --git a/bin/OpenSim.ini.example b/bin/OpenSim.ini.example index 04a4f7d..6129640 100644 --- a/bin/OpenSim.ini.example +++ b/bin/OpenSim.ini.example | |||
@@ -988,7 +988,7 @@ | |||
988 | ;; co-op will be more stable but this option is currently experimental. | 988 | ;; co-op will be more stable but this option is currently experimental. |
989 | ;; If moving from co-op to abort, existing script DLLs will need to be recompiled. | 989 | ;; If moving from co-op to abort, existing script DLLs will need to be recompiled. |
990 | ;; This currently can only be done manually, either by setting DeleteScriptsOnStartup = true for one run | 990 | ;; This currently can only be done manually, either by setting DeleteScriptsOnStartup = true for one run |
991 | ;; or by deleting the script DLL* files in bin/ScriptEngines/<region-id>/ | 991 | ;; or by deleting the script DLL* files in ../../caches/ScriptEngines/<region-id>/ |
992 | ;; One can move from co-op back to abort without recompilation, but reverting back to co-op again will need script recompile | 992 | ;; One can move from co-op back to abort without recompilation, but reverting back to co-op again will need script recompile |
993 | ;; Current valid values are "abort" and "co-op" | 993 | ;; Current valid values are "abort" and "co-op" |
994 | ; ScriptStopStrategy = co-op | 994 | ; ScriptStopStrategy = co-op |
@@ -1049,7 +1049,7 @@ | |||
1049 | 1049 | ||
1050 | ;# {ScriptEnginesPath} {} {Path to script assemblies} {} ScriptEngines | 1050 | ;# {ScriptEnginesPath} {} {Path to script assemblies} {} ScriptEngines |
1051 | ;; Path to script engine assemblies | 1051 | ;; Path to script engine assemblies |
1052 | ;; Default is ./bin/ScriptEngines | 1052 | ;; Default is ../../caches/ScriptEngines |
1053 | ; ScriptEnginesPath = "ScriptEngines" | 1053 | ; ScriptEnginesPath = "ScriptEngines" |
1054 | 1054 | ||
1055 | [OSSL] | 1055 | [OSSL] |
diff --git a/bin/OpenSimDefaults.ini b/bin/OpenSimDefaults.ini index 5d99110..2e680df 100644 --- a/bin/OpenSimDefaults.ini +++ b/bin/OpenSimDefaults.ini | |||
@@ -1,6 +1,12 @@ | |||
1 | ; This file contains defaults for various settings in OpenSimulator. These can be overriden | 1 | ; This file contains defaults for various settings in OpenSimulator. These can be overriden |
2 | ; by changing the same setting in OpenSim.ini (once OpenSim.ini.example has been copied to OpenSim.ini). | 2 | ; by changing the same setting in OpenSim.ini (once OpenSim.ini.example has been copied to OpenSim.ini). |
3 | 3 | ||
4 | |||
5 | [Includes] | ||
6 | ; Define your server specific constants in this file. | ||
7 | Include-Common = ../../config/config.ini | ||
8 | |||
9 | |||
4 | [Startup] | 10 | [Startup] |
5 | ; Console prompt | 11 | ; Console prompt |
6 | ; Certain special characters can be used to customize the prompt | 12 | ; Certain special characters can be used to customize the prompt |
@@ -13,11 +19,11 @@ | |||
13 | ConsoleHistoryFileEnabled = true | 19 | ConsoleHistoryFileEnabled = true |
14 | 20 | ||
15 | ; Log file location. This can be set to a simple file path | 21 | ; Log file location. This can be set to a simple file path |
16 | ; LogFile = OpenSim.log | 22 | LogFile = "${Paths|LogPath}/OpenSim.log" |
17 | 23 | ||
18 | ; The history file can be just a filename (relative to OpenSim's bin/ directory | 24 | ; The history file can be just a filename (relative to OpenSim's bin/ directory |
19 | ; or it can be a full path to somewhere else. (default is OpenSimConsoleHistory.txt in bin/) | 25 | ; or it can be a full path to somewhere else. (default is OpenSimConsoleHistory.txt in bin/) |
20 | ConsoleHistoryFile = "OpenSimConsoleHistory.txt" | 26 | ConsoleHistoryFile = "${Paths|LogPath}/OpenSimConsoleHistory.txt" |
21 | 27 | ||
22 | ; How many lines of command history should we keep? (default is 100) | 28 | ; How many lines of command history should we keep? (default is 100) |
23 | ConsoleHistoryFileLines = 100 | 29 | ConsoleHistoryFileLines = 100 |
@@ -98,7 +104,7 @@ | |||
98 | 104 | ||
99 | ; Determines where the region XML files are stored if you are loading these from the filesystem. | 105 | ; Determines where the region XML files are stored if you are loading these from the filesystem. |
100 | ; Defaults to bin/Regions in your OpenSimulator installation directory | 106 | ; Defaults to bin/Regions in your OpenSimulator installation directory |
101 | ; regionload_regionsdir="C:\somewhere\xmlfiles\" | 107 | regionload_regionsdir="Regions" |
102 | 108 | ||
103 | ; Determines the page from which regions xml is retrieved if you are loading these from the web | 109 | ; Determines the page from which regions xml is retrieved if you are loading these from the web |
104 | ; The XML here has the same format as it does on the filesystem (including the <Root> tag), | 110 | ; The XML here has the same format as it does on the filesystem (including the <Root> tag), |
@@ -459,6 +465,9 @@ | |||
459 | ; Show NPCs as green world map dots | 465 | ; Show NPCs as green world map dots |
460 | ;ShowNPCs = true | 466 | ;ShowNPCs = true |
461 | 467 | ||
468 | ; where to store cached map tiles. | ||
469 | CacheDirectory = "${Paths|CachePath}/MapImageCache" | ||
470 | |||
462 | [Permissions] | 471 | [Permissions] |
463 | ; ## | 472 | ; ## |
464 | ; ## PERMISSIONS | 473 | ; ## PERMISSIONS |
@@ -1699,7 +1708,7 @@ | |||
1699 | default_snapshot_period = 1200 | 1708 | default_snapshot_period = 1200 |
1700 | 1709 | ||
1701 | ; This will be created in bin, if it doesn't exist already. It will hold the data snapshots. | 1710 | ; This will be created in bin, if it doesn't exist already. It will hold the data snapshots. |
1702 | snapshot_cache_directory = "DataSnapshot" | 1711 | snapshot_cache_directory = "${Paths|CachePath}/DataSnapshot" |
1703 | 1712 | ||
1704 | ; Uncomment if you want to index your data with this and/or other search providers. One entry per | 1713 | ; Uncomment if you want to index your data with this and/or other search providers. One entry per |
1705 | ; data service | 1714 | ; data service |
@@ -1927,7 +1936,7 @@ | |||
1927 | ; DisableUndergroundMovement = true | 1936 | ; DisableUndergroundMovement = true |
1928 | 1937 | ||
1929 | ;; Path to script assemblies | 1938 | ;; Path to script assemblies |
1930 | ; ScriptEnginesPath = "ScriptEngines" | 1939 | ; ScriptEnginesPath = "${Paths|CachePath}/ScriptEngines" |
1931 | 1940 | ||
1932 | 1941 | ||
1933 | [Concierge] | 1942 | [Concierge] |
diff --git a/bin/Robust.Tests.dll.config b/bin/Robust.Tests.dll.config index a4c43e7..cc0bead 100644 --- a/bin/Robust.Tests.dll.config +++ b/bin/Robust.Tests.dll.config | |||
@@ -22,7 +22,7 @@ | |||
22 | </appender> | 22 | </appender> |
23 | 23 | ||
24 | <appender name="LogFileAppender" type="log4net.Appender.FileAppender"> | 24 | <appender name="LogFileAppender" type="log4net.Appender.FileAppender"> |
25 | <file value="Robust.Tests.log" /> | 25 | <file value="../../logs/Robust.Tests.log" /> |
26 | <appendToFile value="true" /> | 26 | <appendToFile value="true" /> |
27 | <filter type="log4net.Filter.LoggerMatchFilter"> | 27 | <filter type="log4net.Filter.LoggerMatchFilter"> |
28 | <loggerToMatch value="special"/> | 28 | <loggerToMatch value="special"/> |
diff --git a/bin/Robust.exe.config b/bin/Robust.exe.config index 3ad5f31..62ffcc6 100644 --- a/bin/Robust.exe.config +++ b/bin/Robust.exe.config | |||
@@ -22,7 +22,8 @@ | |||
22 | 22 | ||
23 | <!-- If you want automatic log-rolling then use RollingFileAppender instead of FileAppender: | 23 | <!-- If you want automatic log-rolling then use RollingFileAppender instead of FileAppender: |
24 | <appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender"> | 24 | <appender name="LogFileAppender" type="log4net.Appender.RollingFileAppender"> |
25 | <file value="log/Robust.log" /> | 25 | <threshold value="DEBUG" /> |
26 | <file value="../../logs/Robust.log" /> | ||
26 | <rollingStyle value="Date" /> | 27 | <rollingStyle value="Date" /> |
27 | <datePattern value="'.'yyyy-MM-dd"/> | 28 | <datePattern value="'.'yyyy-MM-dd"/> |
28 | ... | 29 | ... |
@@ -41,7 +42,7 @@ | |||
41 | </appender> | 42 | </appender> |
42 | 43 | ||
43 | <appender name="StatsLogFileAppender" type="log4net.Appender.FileAppender"> | 44 | <appender name="StatsLogFileAppender" type="log4net.Appender.FileAppender"> |
44 | <file value="RobustStats.log"/> | 45 | <file value="../../logs/RobustStats.log"/> |
45 | <appendToFile value="true" /> | 46 | <appendToFile value="true" /> |
46 | <layout type="log4net.Layout.PatternLayout"> | 47 | <layout type="log4net.Layout.PatternLayout"> |
47 | <conversionPattern value="%date - %message%newline" /> | 48 | <conversionPattern value="%date - %message%newline" /> |
diff --git a/bin/config-include/GridCommon.ini.example b/bin/config-include/GridCommon.ini.example index 46b4ded..3550ed9 100644 --- a/bin/config-include/GridCommon.ini.example +++ b/bin/config-include/GridCommon.ini.example | |||
@@ -6,7 +6,7 @@ | |||
6 | ; | 6 | ; |
7 | 7 | ||
8 | ; SQLite | 8 | ; SQLite |
9 | Include-Storage = "config-include/storage/SQLiteStandalone.ini"; | 9 | ; Include-Storage = "config-include/storage/SQLiteStandalone.ini"; |
10 | 10 | ||
11 | ; MySql | 11 | ; MySql |
12 | ; Uncomment these lines if you want to use mysql storage | 12 | ; Uncomment these lines if you want to use mysql storage |
diff --git a/bin/config-include/StandaloneCommon.ini.example b/bin/config-include/StandaloneCommon.ini.example index a4be88e9..906ab84 100644 --- a/bin/config-include/StandaloneCommon.ini.example +++ b/bin/config-include/StandaloneCommon.ini.example | |||
@@ -6,7 +6,7 @@ | |||
6 | ; | 6 | ; |
7 | 7 | ||
8 | ; SQLite | 8 | ; SQLite |
9 | Include-Storage = "config-include/storage/SQLiteStandalone.ini"; | 9 | ;Include-Storage = "config-include/storage/SQLiteStandalone.ini"; |
10 | 10 | ||
11 | ; MySql | 11 | ; MySql |
12 | ; Uncomment these lines if you want to use mysql storage | 12 | ; Uncomment these lines if you want to use mysql storage |