Moving FS9 default scenery folders

Use this forum to discuss technical issues related to the operation of your computer. Graphics, Hardward, Software, settings, etc.
Post Reply
User avatar
Firebird
MAIW Admin
MAIW Admin
Posts: 10404
Joined: 11 Aug 2006, 21:04
Version: FS9
Location: EGLL

Moving FS9 default scenery folders

Post by Firebird »

I have mentioned in other posts of the ability to move the location of your default FS9 scenery folders to a completely separate HD/SSD to help speed up your game.

Well today I have discovered one issue with it so I thought that I would briefly explain the principal, how you do it, the issue I found today and its fix all in one post.

THE PRINCIPAL
A HD has only so many heads to read the rotating disk platters so if the data is not laid out in absolute perfect symmetry you will need to rotate the disks several times to read the data into memory as it jumps about from file part to file part. The bottom line is that you are not able to load the data as quickly as you like.
A similar principal also applies to SSDs although they have no moving heads. If the data is not laid out as you want it to be loaded then your read time will increase.

How do you prevent this? There are several methods that can help which include regularly defragging a HD but you do not defrag an SSD as you will just use up its life time exponentially. Instead SSDs use an algorithm when they right data to try and maximise the readability of the data, however over time as you replace some data with other data it will lose its effectiveness.
You can increase the number of heads that can access the data. How? Well the most common way is to have two disks in a RAID 0 array. This is seen as 1 disk of double the size and it stripes data across the two physical disks meaning that you have 2 sets of disk heads reading the data at the same time. Potentially up to twice as fast.
The big drawback with RAID 0 arrays is that if you lose one disk you lose them all. If you are a person that does not backup your disks regularly DO NOT go anywhere near RAID.

Any other solutions? Yes. You can split up your FS installation across multiple HD/SSDs to increase the load time

THE METHOD
Simply put what does FS9 constantly load from the disk? Scenery, textures, aircraft and traffic.
Probably the simplest method to increase read times and reduce stutters in the game in so move the scenery folders to a completely separate HD/SSD. Not a different partition as you will still share the same heads.

How do you move the scenery folders?
Easy copy them to another path in another disk and then alter your scenery.cfg file to reflect what you have done.

I should state that I moved all bar one folder, Default Terrain, but that is my personal choice and for no other reason. The reason being that this is where the traffic files are kept so I decided to separate them from the other scenery folders.

The alteration you make in your scenery.cfg is similar to this :-
[Area.002]
Title=Default Scenery
Local=Scenery\BASE
Layer=2
Active=TRUE
Required=TRUE

Becomes :-

[Area.002]
Title=Default Scenery
Local=S:\FS9_Default\Scenery\BASE
Layer=2
Active=TRUE
Required=TRUE

In the first case the location is the default relative location to FS9, the second is the full path name. It is that simple.

Now you have your global textures, traffic and aircraft on one disk and all your scenery on another. This should spread the workload nicely. I can't guarantee that it will be a lot faster but it will definitely be smoother in game. It may not get rid of all stutters but they will be reduced significantly.

As Isaid on my system I left one folder alone but you need not do so, it is up to you.
[Area.001]
Title=Default Terrain
Texture_ID=1
Layer=1
Active=TRUE
Required=TRUE
Local=Scenery\World

THE PROBLEM
Today after months of use the first problem. I tried to load the default RAF Leuchars afcad into ADE9 and it reported that it couldn't be found. I suspected that this was caused by the move and so i contacted Jon at Scruffyduck. He confirmed what I thought and that ADE9 only looks in the default installation place for relative folders.
Jon did not offer a hope that he would look at altering this and to be honest it is obvious why.

THE FIX
The fix is to use part of the Windows OS called symlinks.
There is a command called mklink which you can call from your admin command prompt. A good useful explanation of how to use it is here https://www.howtogeek.com/howto/16226/c ... -or-linux/.
Bascially, it creates a logical file that points to the actual file in a completely different location. You can also create local folders as well. So for each default scenery location I had to create a symlink to the actual location and then ADE9 was able to find and open the file successfully. The good news is that anything else that has hard coded links will also benefit from this fix.

To show you one example here is some of the commands I entered :-

Code: Select all

[b]Microsoft Windows [Version 10.0.16299.192]
(c) 2017 Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>mklink /J "F:\Flight Simulator 9\Scenery\Eurw" S:\FS9_Default\Scenery\Eurw
Junction created for F:\Flight Simulator 9\Scenery\Eurw <<===>> S:\FS9_Default\Scenery\Eurw

C:\WINDOWS\system32>mklink /J "F:\Flight Simulator 9\Scenery\Afri" S:\FS9_Default\Scenery\Afri
Junction created for F:\Flight Simulator 9\Scenery\Afri <<===>> S:\FS9_Default\Scenery\Afri

C:\WINDOWS\system32>mklink /J "F:\Flight Simulator 9\Scenery\asia" S:\FS9_Default\Scenery\asia
Junction created for F:\Flight Simulator 9\Scenery\asia <<===>> S:\FS9_Default\Scenery\asia

C:\WINDOWS\system32>
[/b]
That it is. The subject in its entirety. maybe some of you will find it more interesting than useful but anything that increases your knowledge of how FS operates has to be useful.
Steve
_______________________________________________________
Image
Quid Si Coelum Ruat
_______________________________________________________

User avatar
hawk_sh
Lieutenant Colonel
Lieutenant Colonel
Posts: 830
Joined: 16 Nov 2008, 22:26
Version: FS9
Location: near EDDF

Re: Moving FS9 default scenery folders

Post by hawk_sh »

Thank you Steve for your explanations.

Could all these mklink commands for the default scenery folders be put into a single batch file that is then run as administrator?

The default scenery folders ("Scenery\Eurw", "Scenery\Afri", "Scenery\asia", ...) themselves should be indentical on every FS9 installation, only the source paths ("F:\Flight Simulator 9\") and target paths ("S:\FS9_Default\") should be different?

One could make a template batch file and then the source and target paths could be quickly modified with find --> replace ?
Hartwig
_______________________________________________________________

Image

User avatar
SeanG
Captain
Captain
Posts: 302
Joined: 11 May 2008, 05:22
Version: FS9
Location: Christchurch, New Zealand
Contact:

Re: Moving FS9 default scenery folders

Post by SeanG »

... or could you move the complete \scenery\ folder to another drive, and mklink that into \fs9\ Rather than lots of links?

Might be worth doing with \aircraft as well... to speed up loading AI textures.... Oh the possibilities!

It's something I want to play with as well... better performance is better performance after all!

SeanG
Image

User avatar
Firebird
MAIW Admin
MAIW Admin
Posts: 10404
Joined: 11 Aug 2006, 21:04
Version: FS9
Location: EGLL

Re: Moving FS9 default scenery folders

Post by Firebird »

Interesting question there, Sean.
I didn't know the answer to that one as I left one behind. However, in the interest of experimentation I renamed the FS9 Scenery folder and created a symlink as follows :-

Code: Select all

[b]Microsoft Windows [Version 10.0.16299.192]
(c) 2017 Microsoft Corporation. All rights reserved.

C:\WINDOWS\system32>mklink /J "F:\Flight Simulator 9\scenery" S:\FS9_Default\Scenery
Junction created for F:\Flight Simulator 9\scenery <<===>> S:\FS9_Default\Scenery

C:\WINDOWS\system32>[/b]
The quick test I did worked so it would seem that if you move the whole lot you can simplify it to just one command.

In answer to Hartwigs question then yes a batch file can be created to run the individual commands.

Then was one more thing to mention. The Addon Scenery folder is not part of the same structure and so I ignored it, however you are also free to move that and put the full path in the scenery.cfg as it contains no default scenery.

---===*===---

Now the one thing that I didn't mention, as this was scenery specific was that if you go down the symlink route you could just as easily move all your aircraft to a different drive, as Sean thought, and do the create a link for your aircraft instead, or even textures.

The upshot is that you now have the power to split up your FS9 installation to either free up space on your original drive or increase the efficiency of your game.
A word of caution though, only move stuff to internal drives and there is nearly always going to be a slow down on externally plugged in drives.

As many people are constantly trying the squeeze the most performance out your machines that you can for FS it will be interesting to see what you guys do and experience.
Steve
_______________________________________________________
Image
Quid Si Coelum Ruat
_______________________________________________________

User avatar
gsnde
MAIW Staff
MAIW Staff
Posts: 3572
Joined: 05 Apr 2007, 08:13
Version: P3D
Location: South-West Germany
Contact:

Re: Moving FS9 default scenery folders

Post by gsnde »

Not sure if that has been said already....

There is one thing that you should always be very much aware of: by deleting a symbolic link from the command prompt with the 'del' command you will also delete the content of the linked folders.

If I remember correctly the right way to get rid of a symbolic link and leaving the content is the 'rd' command.

You can safely delete symbolic links with the Windows Explorer.

From mobile hence short

Cheers,
Martin
________________________________________
ImageThe Owl's Nest * Military Aircraft Reference * ICAO Reference * Distance Calculator * MAIW, Military AI & UKMil Reference

User avatar
Firebird
MAIW Admin
MAIW Admin
Posts: 10404
Joined: 11 Aug 2006, 21:04
Version: FS9
Location: EGLL

Re: Moving FS9 default scenery folders

Post by Firebird »

A slight update to this topic.
For those that quite like the flexibility that this gives FS9 users but don't fancy the idea of playing around with command prompt stuff there is now a tool that you can install and it will do it from your explorer.

Here is a link to a post that shows you how to use mklink in the command line but also has a link to an app that you can use through the gui and how to use it. https://www.howtogeek.com/howto/16226/c ... -or-linux/.

It does work I have tested it.
Steve
_______________________________________________________
Image
Quid Si Coelum Ruat
_______________________________________________________

Post Reply