Welcome, Guest. Please login or register.

Author Topic: Windows WITH a swapfile :-)  (Read 4294 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline ptekTopic starter

  • Sr. Member
  • ****
  • Join Date: Jul 2002
  • Posts: 328
    • Show only replies by ptek
Windows WITH a swapfile :-)
« on: July 17, 2004, 06:37:45 PM »
Hi all,

I have a Athlon XP 2000+ machine with windoze XP and 256MB RAM.

Since 256 MB seems not to be enough for the hungry OS, I must live with a pagefile (virtual memory) bitting my disk :-)

So, I decided to create a extra partition for exclusive virtual memory use. This way, I prevent fragmentation on the system disk gaining some performance as you may already realized.

My big question is: Which filesystem should I use ?
I read somewhere that NT filesystem has more overhead than FAT32. And FAT32 in turn has more overhead than FAT.

For best performance should I use FAT ?
The partition is about 1GB, so FAT should handle it.
Onions have layers ...
 

Offline fragment

  • Full Member
  • ***
  • Join Date: Dec 2002
  • Posts: 218
    • Show only replies by fragment
    • http://www.fragment.fi/
Re: Windows WITH a swapfile :-)
« Reply #1 on: July 17, 2004, 06:48:00 PM »
...
 

Offline Turambar

  • Sr. Member
  • ****
  • Join Date: Jan 2003
  • Posts: 425
    • Show only replies by Turambar
    • http://gentleman-bastards.com/
Re: Windows WITH a swapfile :-)
« Reply #2 on: July 17, 2004, 06:53:54 PM »
Personally i blame fragment for file fragmentation.
 

Offline seer

  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 1453
    • Show only replies by seer
Re: Windows WITH a swapfile :-)
« Reply #3 on: July 17, 2004, 07:04:31 PM »
If you can put it on a diferent disk it would be a little better then if it was on the same disk but a different partition.

A long time ago I read an article that said you should put a pagefile on a FAT(32) formatted drive, tho I can't remember the reasons. I since put it on a NTFS partition (different disk then the partition XP lives) and don't notice any performance when it was on a FAT partition (which was the same partition only needed a fet NTFS permissions set on that one..).
~
Everything you say will be misquoted and used against you.
~
 

Offline Karlos

  • Sockologist
  • Global Moderator
  • Hero Member
  • *****
  • Join Date: Nov 2002
  • Posts: 16879
  • Country: gb
  • Thanked: 5 times
    • Show only replies by Karlos
Re: Windows WITH a swapfile :-)
« Reply #4 on: July 17, 2004, 07:09:34 PM »
What happens if you get a great big fat CF IDE and use that to hold your swapfile (having first given it a whole IDE chain to  itslef ;-) )
int p; // A
 

Offline Turambar

  • Sr. Member
  • ****
  • Join Date: Jan 2003
  • Posts: 425
    • Show only replies by Turambar
    • http://gentleman-bastards.com/
Re: Windows WITH a swapfile :-)
« Reply #5 on: July 17, 2004, 07:25:37 PM »
You'll soon end up with a dead flash card. IIRC flash memory can only handle a certain number of reads/writes before it burns out, a windows swap file will probably reach that limit reasonably quickly.
 

Offline odin

  • Colonization had Galleons
  • Hero Member
  • *****
  • Join Date: Feb 2002
  • Posts: 6796
    • Show only replies by odin
Re: Windows WITH a swapfile :-)
« Reply #6 on: July 17, 2004, 07:39:27 PM »
100.000 cycles are usually garantueed.

Offline B00tDisk

  • VIP / Donor - Lifetime Member
  • Hero Member
  • *****
  • Join Date: Dec 2002
  • Posts: 1670
    • Show only replies by B00tDisk
    • http://www.thedelversdungeon.com
Re: Windows WITH a swapfile :-)
« Reply #7 on: July 17, 2004, 08:21:43 PM »
I cannot emphasize this enough: GO WITH NTFS.  NTFS is a more secure file system, it keeps track of itself MUCH better than either FAT or FAT32, it can take random power loss on the chin and come right back, it doesn't fragment nearly as much as either FAT file systems, it compresses better (if you need such a thing in this day and age).  It's just much, much, much more robust.  Please do yourself a favor, spare yourself the heartbreak and GO WITH NTFS!

You'll thank me! :)
Back away from the EU-SSR!
 

Offline Ilwrath

Re: Windows WITH a swapfile :-)
« Reply #8 on: July 17, 2004, 08:52:45 PM »
@B00tDisk-
Yes, of course, for boot and data partitions, use NTFS, no doubt about it.  The feature set puts it far above any other Windows filesystem.  But, do you need ANY of those features for a swap partition?  (What should I format my swap partition as was the original question...)

My gut instinct is to use FAT32 for your swap, if you're going to use a dedicated partition.  Why add the overhead of NTFS permissions and fault recovery to a drive that doesn't need them?  

But, I don't really think breaking out swap from your Windows partition will give you any noticable performance gains over a non-fragmented fixed-size pagefile on an NTFS partition, though.  At one of my old jobs, we benchmarked several different NT swap setups, and chose to go with a fixed-size pagefile on the NTFS system partition, as it was the all-around most efficient setup for a single HD workstation.  We found no appreciable speed difference by placing swap in a seperate partition, and, of course, you lose the ability to easily increase your pagefile should the need occur.  

If you have two or more drives in your system, and they are  identical drives, putting the swap partition on the drive that does not contain the system partition will speed up things a slight amount.  But if that drive is slower than your system drive, the small speed gains you make can be wiped out... and you may even get a performance penalty.  (In other words, I wouldn't recommend putting an old 1 gig drive in your system for the sole purpose of having a swap drive -- it'll hurt more than it helps.)
 

Offline ptekTopic starter

  • Sr. Member
  • ****
  • Join Date: Jul 2002
  • Posts: 328
    • Show only replies by ptek
Re: Windows WITH a swapfile :-)
« Reply #9 on: July 17, 2004, 11:15:40 PM »
Yes, my concern was about performance (less overhead) and to prevent fragmentation (the hint to use a fixed size pagefile was welcome :-) ).

About FAT32 vs FAT16, I think i'll go for FAT16. here's why:

http://www.storagereview.com/guide2000/ref/hdd/file/fileFAT32.html

and extensively explained futher on:

http://www.storagereview.com/guide2000/ref/hdd/file/partFAT32.html

Since my partition is relative small, the amount of slack FAT16 will take will not be so important, and I agree the NTFS might slow down thinks a bit due to the extra feature it offers (user rights, etc)

And look for the "Overall Performance" table on this:
http://www.ntfs.com/ntfs_vs_fat.htm

I hope 1GB partition is considered small
 :-D
Onions have layers ...
 

Offline blobrana

  • Hero Member
  • *****
  • Join Date: Mar 2002
  • Posts: 4743
    • Show only replies by blobrana
    • http://mysite.wanadoo-members.co.uk/blobrana/home.html
Re: Windows WITH a swapfile :-)
« Reply #10 on: July 17, 2004, 11:43:45 PM »
Hum,
Sounds good...

And you probably won't run into any difficulties, er, before you buy another 256 ram module (which are incredibly cheep), and do away with the swap file & HD altogether... :-)






---------------
Star Shrek

Offline Holley

  • Hero Member
  • *****
  • Join Date: May 2004
  • Posts: 888
    • Show only replies by Holley
    • http://www.Front-Runners.net
Re: Windows WITH a swapfile :-)
« Reply #11 on: July 18, 2004, 01:09:20 AM »
One simple solution: get more memory, and run the swapfile onto a Ramdisk.  Windows requires an extensive swapfile, just try switching it off and running Word as an example!  This is the only way to stop the harddisk grinding.

For speed (on disk) a fixed size swapfile, set right after installing Windows, will do best.  A small partition at the start of an oversized drive will also work faster.  Keeping it cleared of temp files and defragmented regularly also helps ... a quick harddisk will access faster than flash memory for that kind of access pattern BTW!
\\"Sex, drugs and rock n\\\' roll are very good for you\\" - Ian Dury
 

Offline weirdami

  • Hero Member
  • *****
  • Join Date: Jan 2003
  • Posts: 3776
    • Show only replies by weirdami
    • Http://Bindingpolymer.com
Re: Windows WITH a swapfile :-)
« Reply #12 on: July 18, 2004, 01:32:02 AM »
@ptek

Don't partition, get a separate harddrive for the swapfile. You could pick up a 1GB one really cheap somewhere I'm sure. If windows is accessing the swap partition on your main harddrive, the heads aren't accessing the data you want, so the heads have to go back and forth. With a spearate harddrive for the swapfile, you've got a different drive heads doing different things all at once.
----
Binding Polymer: Keeping you together since 1892.
 

Offline Holley

  • Hero Member
  • *****
  • Join Date: May 2004
  • Posts: 888
    • Show only replies by Holley
    • http://www.Front-Runners.net
Re: Windows WITH a swapfile :-)
« Reply #13 on: July 18, 2004, 02:02:50 AM »
A seperate old 1Gb drive will be slower than a newish 30+ Gb one sharing Windows!  If you create, say, a 10Gb partition at the start of a 160Gb disk it goes well quick, too!

Anyway, to set up a Ramdisk you used to run a program called ramdisk under Dos (it came with 5.0 to 6.22 IIRC), under Windows you'd need to use something like this.
\\"Sex, drugs and rock n\\\' roll are very good for you\\" - Ian Dury
 

Offline Trev

  • Hero Member
  • *****
  • Join Date: May 2003
  • Posts: 1550
  • Country: 00
    • Show only replies by Trev
Re: Windows WITH a swapfile :-)
« Reply #14 on: July 18, 2004, 02:20:48 AM »
You're only going to store one file (pagefile.sys) on this disk/partition, so storage lost to half-empty clusters isn't an issue. At most, you'll lose n-1 bytes, where n is the size of the cluster, plus the overhead of the file system and the directory entry. (Storage loss per file for a typical file system is normally n/2.)

Fragmentation will remain an issue, as the data written to the page file becomes fragmented over time, whether or not the page file itself is fragmented.

For best performance, you should use NTFS with 64K clusters. FAT partition performance degrades quickly with size. (Side note: never convert a FAT partion to NTFS, as the partition will always use 512 bytes clusters. Very poor performance.)

The size of the page file should be based on the memory requirements of your applications and is usually something like max(total, largest_allocated) - physical + 12 (i.e. the maximum of either the total amount of memory used by all applications or the largest block of memory allocated by a single application minus the amount of physical memory in the system plus 12).

If you intend to produce and debug system dumps, you must have a page file on your system disk. You'll get slightly better performance by using a separate partition. You'll only see increased performance on a separate ATA disk if you place the disk on its own channel.

Quick note. A page file is about allowing you to do more with less. A properly written application with accurate memory requirements souldn't suffer performance problems just because a page file exists on the system. Setting aside physical memory as a RAM disk for storing the page file just doesn't make sense. If you don't need the extra memory, remove it. If you don't need the page file, don't create one (or just use the minimum required).

And from the perspective of the FAT file system, 1GB is, as Mike Meyers would say, "Friggin' huge!"

Trev