Fractal Softworks Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

Starsector 0.97a is out! (02/02/24); New blog post: Simulator Enhancements (03/13/24)

Pages: 1 ... 12 13 [14] 15 16 ... 30

Author Topic: [Important!] Modded System Requirements  (Read 513216 times)

Tartiflette

  • Admiral
  • *****
  • Posts: 3529
  • MagicLab discord: https://discord.gg/EVQZaD3naU
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #195 on: March 03, 2016, 08:01:05 AM »

Can we all agree that developer could just improve the game code so you can either choose how much memory it can use or its checking your resources and uses it better? It feels weird to be forced to do that all stuff by yourself :P

Hello everybody btw. Been lurking here since 0.6 version ;)
Maybe he doesn't have to because his game run fine on 1GB with a 32bits Java. Doing what you are sugesting would imply making the game no longer work for all the current 32bits users. Also it's a mod issue and if he does tackle it at some point it won't be until the game is alredy complete, as maintaining a 32 and 64 bits version would be very time consuming.
Logged
 

Goosi

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #196 on: March 03, 2016, 12:17:47 PM »

Paste your vmparams file.

Spoiler
-server -XX:CompilerThreadPriority=1 -XX:+CompilerThreadHintNoPreempt -Djava.library.path=native\\windows -Xms3g -Xmx5g -Xss1024k -classpath janino.jar;commons-compiler.jar;commons-compiler-jdk.jar;starfarer.api.jar;starfarer_obf.jar;jogg-0.0.7.jar;jorbis-0.0.15.jar;json.jar;lwjgl.jar;jinput.jar;log4j-1.2.9.jar;lwjgl_util.jar;fs.sound_obf.jar;fs.common_obf.jar;xstream-1.4.2.jar -Dcom.fs.starfarer.settings.paths.saves=..\\saves -Dcom.fs.starfarer.settings.paths.screenshots=..\\screenshots -Dcom.fs.starfarer.settings.paths.mods=..\\mods -Dcom.fs.starfarer.settings.paths.logs=. com.fs.starfarer.StarfarerLauncher
[close]

I've tried every single combination of memory allowance but nothing seems to work.
Logged

TJJ

  • Admiral
  • *****
  • Posts: 1905
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #197 on: March 03, 2016, 12:59:38 PM »

Can we all agree that developer could just improve the game code so you can either choose how much memory it can use or its checking your resources and uses it better? It feels weird to be forced to do that all stuff by yourself :P

Hello everybody btw. Been lurking here since 0.6 version ;)
Maybe he doesn't have to because his game run fine on 1GB with a 32bits Java. Doing what you are sugesting would imply making the game no longer work for all the current 32bits users. Also it's a mod issue and if he does tackle it at some point it won't be until the game is alredy complete, as maintaining a 32 and 64 bits version would be very time consuming.

Include both 32 & 64bit VMs.
Have the launcher configure which is used, and what VM parameters are used. (Launcher would spawn a new VM instance)

Game could even catch its own Out of memory/stackover errors, and at next launch, suggest which VM parameters to increase.
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #198 on: March 03, 2016, 04:13:32 PM »

Paste your vmparams file.

Spoiler
-server -XX:CompilerThreadPriority=1 -XX:+CompilerThreadHintNoPreempt -Djava.library.path=native\\windows -Xms3g -Xmx5g -Xss1024k -classpath janino.jar;commons-compiler.jar;commons-compiler-jdk.jar;starfarer.api.jar;starfarer_obf.jar;jogg-0.0.7.jar;jorbis-0.0.15.jar;json.jar;lwjgl.jar;jinput.jar;log4j-1.2.9.jar;lwjgl_util.jar;fs.sound_obf.jar;fs.common_obf.jar;xstream-1.4.2.jar -Dcom.fs.starfarer.settings.paths.saves=..\\saves -Dcom.fs.starfarer.settings.paths.screenshots=..\\screenshots -Dcom.fs.starfarer.settings.paths.mods=..\\mods -Dcom.fs.starfarer.settings.paths.logs=. com.fs.starfarer.StarfarerLauncher
[close]

I've tried every single combination of memory allowance but nothing seems to work.

You are running from the launcher .exe file, correct?

Anyway, when does this occur?  Any save?  A specific save?

Try idling the game for like 10 minutes on the start screen.  Does it crash?
Logged

Goosi

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #199 on: March 03, 2016, 04:31:06 PM »

You are running from the launcher .exe file, correct?

Anyway, when does this occur?  Any save?  A specific save?

Try idling the game for like 10 minutes on the start screen.  Does it crash?

The game won't launch from the .exe with a modified vmparams file so I'm running it from the .bat in the starsector-core folder.

The crash occurs whenever I save after playing for maybe half an hour.

Been idling for some thirty minutes and no crash yet. It's only when I'm saving.
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #200 on: March 03, 2016, 05:21:09 PM »

You are running from the launcher .exe file, correct?

Anyway, when does this occur?  Any save?  A specific save?

Try idling the game for like 10 minutes on the start screen.  Does it crash?

The game won't launch from the .exe with a modified vmparams file so I'm running it from the .bat in the starsector-core folder.

The crash occurs whenever I save after playing for maybe half an hour.

Been idling for some thirty minutes and no crash yet. It's only when I'm saving.

The .bat file does not use vmparams.  This means you're using the default memory allocation.

You are probably not using a 64-bit JRE (in the jre folder), which would explain the crashing from the launcher.
Logged

Goosi

  • Ensign
  • *
  • Posts: 4
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #201 on: March 03, 2016, 08:53:29 PM »

The .bat file does not use vmparams.  This means you're using the default memory allocation.

You are probably not using a 64-bit JRE (in the jre folder), which would explain the crashing from the launcher.

Holy moley! For some reason the Java I've been using has been the 32 bit one when I was sure I had downloaded the 64 bit one.

I downloaded the 64 bit version and as far as I can tell it solved the problem. Thanks for the help!  ;D ;D
Logged

Kevin Flemming

  • Commander
  • ***
  • Posts: 104
  • So say we all.
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #202 on: March 08, 2016, 02:49:29 AM »

Step 1: Download and install 64-bit JRE 7 for your operating system here: http://www.oracle.com/technetwork/java/javase/downloads/jre7-downloads-1880261.html.

As a note, that isn't the same link as in the video.

This is the actual link: https://java.com/en/download/manual.jsp

I zoomed-in on the video and typed in the same link that Nemo had in his browser and it was much easier to follow. Actually managed to get 64-bit working! That's where I was getting confused. The link takes you somewhere totally different.
Logged

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #203 on: March 08, 2016, 08:27:04 AM »

Nobody can agree on the correct link.  That one is for Java 8, which works with Starsector - but isn't technically the correct version to use.  I have to link JRE 7 because that's the "spec" that Starsector uses for its packaged JRE.
Logged

Kevin Flemming

  • Commander
  • ***
  • Posts: 104
  • So say we all.
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #204 on: March 08, 2016, 08:41:09 AM »

Nobody can agree...
...packaged JRE.

Oh, okay. No worries. I wasn't saying it's the "wrong" link, just not the one from the video. =)

I tried JRE7 again earlier, followed the instructions to the letter and nothing. Same as last time, wouldn't run SS. Then tried the Java which Nemo downloaded and it worked straight away. So either something is wrong with JRE7 or my system just doesn't like it. But anyhow, it seems to work so I'm happy lol.
Logged

Weltall

  • Admiral
  • *****
  • Posts: 774
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #205 on: March 12, 2016, 04:50:43 AM »

Not talking about SS+ but I remember a talk a while ago about some faction mods using actually Java 8, which resulted with people using Java 7 getting errors. Personally I do not care for Java 7, since from tests, it did not seem faster than 8 on my machine. Both of them had the same speed on the map and in battle Java 8 was better when I was using a lot of mods and the battle was large. Java 7 was giving me a big lag even in small battles.

Since combinations are mentioned, on my machine again, if I set both min and max at the same ram (my system has 8GB ram) eg. "-Xms4g -Xmx4g" or "-Xms5g -Xmx5g" or even "-Xms4g -Xmx5g" the game will create a memory leak before I know it. Meaning Java will take all the available ram I have and eventually make the game and the whole pc slow down. If I set it to "-Xms2g -Xmx5g" which is what I use, the game might lag here and there, but with Nex+SS+, 25+ factions  and some etc, the ram will flow betwee 3.2GB-4.2GB ram or so. Maybe rarely a bit more, but never over 5 and never leak, or give me any other problem, even on really really many hour long sessions.

These tests through I did on 0.7.1a. I know Alex was not happy with how JRE 8 was acting and moved from it that was coming with 0.7.1a to 7 now. I still use 8, but I have not tested the differences between them with this version.
« Last Edit: March 12, 2016, 04:53:08 AM by weltall »
Logged
Ignorance is bliss..

Dark.Revenant

  • Admiral
  • *****
  • Posts: 2806
    • View Profile
    • Sc2Mafia
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #206 on: March 12, 2016, 01:10:08 PM »

By allocating 5 GB to the heap, you still have to contend with the base Java VM memory, which for a game like this can be around 0.5GB, so in effect you'd see the game use up all of your system memory.  There is no "memory leak".  That term applies to memory that fails to be deallocated, not memory that's simply allocated in the first place.
Logged

Weltall

  • Admiral
  • *****
  • Posts: 774
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #207 on: March 12, 2016, 03:15:47 PM »

I am not knowledgeable about technical terms for sure. I do remember another talk though on here, that someone in detail explained how java works. I think he compared it to linux, but I might be wrong. He said that not allocating all 4GB in both min and max, actually slows down the game, when it is trying to raise the ram from 2GB to 4 GB, while it is needing it. That results in lag while playing. But allocating it all at once, makes it all available to the game, so it will not have to keep trying to get more when it needs it. Also I remember I mentioned Minecraft and he (umm or she) explained that offline games do not work the same as servers, whilst Minecraft is different on that aspect. For me though, I know that adding "-Xms4g -Xmx4g" or "-Xms5g -Xmx5g" or "-Xms4g -Xmx5g", while end up with the game taking over 6GB of ram. I have tested all three, and I was seeing other apps lower their GB use, while java kept taking it all. With closed apps it would take all physical ram and still going over 6Gb and at times push to get more, lagging the system.

So I am not trying to say using it all at once is wrong, because I am sure it is not. This is why I said my machine and I did not generalize it. Even 3 GB min will end up creating a bit larger ram, always being around to 5 GB. So for me, following the instructions of the forums that suggest xms to be lower than xmx, lets me play a really heavy modded game (Nexerelin with full planets, stars and stations, SS+ and all factions that would work with Nexerelin) with some lag but no crashes, even on saving. Follow the video's suggestion, which is the right one, to set them the same, ends up with the game reaching a point that lags way too much and is unplayable, even with every other application on my machine turned off (including antivirus).
Logged
Ignorance is bliss..

Dabclipers

  • Ensign
  • *
  • Posts: 28
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #208 on: March 28, 2016, 04:43:55 PM »

Well, this is the second post I've made today regarding an inability to get the game working.  Hopefully this one will be as easy a fix as the last one:  Anyways, while saving my game crashed and I got a memory related error, so I figured it had to be that I hadn't done the increase to my memory allocation.  I followed the instructions and downloaded the jre folder (Looks like this: jre1.8.0_77 ), restarted my computer and then edited my vmparams file to look like this:

-server -XX:CompilerThreadPriority=1 -XX:+CompilerThreadHintNoPreempt -Djava.library.path=native\\windows -Xms2g -Xmx4g -Xss1024k -classpath janino.jar;commons-compiler.jar;commons-compiler-jdk.jar;starfarer.api.jar;starfarer_obf.jar;jogg-0.0.7.jar;jorbis-0.0.15.jar;json.jar;lwjgl.jar;jinput.jar;log4j-1.2.9.jar;lwjgl_util.jar;fs.sound_obf.jar;fs.common_obf.jar;xstream-1.4.2.jar -Dcom.fs.starfarer.settings.paths.saves=..\\saves -Dcom.fs.starfarer.settings.paths.screenshots=..\\screenshots -Dcom.fs.starfarer.settings.paths.mods=..\\mods -Dcom.fs.starfarer.settings.paths.logs=. com.fs.starfarer.StarfarerLauncher

For those uninterested in reading that^, all I did was modify the -Xms portions to be like they are set in the example.  Now that I have done that my game will no longer launch from the Starsector shortcut or the application launcher from the folder.  I can only launch it from the Windows Batch File in the Starsector-Core file.  This doesn't exactly fix the issue, because none of my saves work anymore.  I saw that someone earlier had something slightly similar happen, in that they could no longer launch the game regularly and had to launch from the starsector-core file but it turned out that they had 32 bit installed.  I downloaded it from the link that and Kevin Flemming posted which is an area you get directed to if you want to download the 64 bit and am reasonably certain I have the correct version installed (could be wrong, I don't know how to check).  If anyone has any ideas, I'd appreciate it, thank you.

*Edit
Upon further testing, I can get the game to run again if I change the Xms portion of the vmparams file back to how it originally is.  I can also change the second number a small amount and it will still run.  Once I change it to: -Xms1024m -Xmx1500m it no longer works.  Don't know if that is useful, but figured I might as well mention it.
« Last Edit: March 28, 2016, 04:54:35 PM by Dabclipers »
Logged

Weltall

  • Admiral
  • *****
  • Posts: 774
    • View Profile
Re: Out of Memory? Use 64-bit Java! (Instructions Inside + Video)
« Reply #209 on: March 28, 2016, 05:18:25 PM »

You do not need to restart, nor you need your system to have Java. You install Java just to take the folder and put it in the game. The game will always use the jre folder found under it root folder. So you can do the tests without restarting. With that said, your made sure to get the 64 bit version? You renamed that jre1.8.0_77 folder to jre, and then replaced the game's jre folder with it?

If yes, then try to uninstall, redownload and reinstall. The way you say the error happens is liek you are using a 32bit version, or the download you used is corrupt. You can try getting the 64bit version from here
http://javadl.oracle.com/webapps/download/AutoDL?BundleId=207231

PS: Maybe you should consider getting the Java 7 ( http://download.oracle.com/otn-pub/java/jdk/7u80-b15/jre-7u80-windows-x64.exe ) and not the java 8, but that is up to you.
« Last Edit: March 28, 2016, 05:22:58 PM by Weltall »
Logged
Ignorance is bliss..
Pages: 1 ... 12 13 [14] 15 16 ... 30