Getting extra swap memory manually
Posted by Carlos Zavala on 10 March 2014 10:46 AM

Swapping off mdx or "swap volume" and swapping on individual partitions to maximize total swap memory for operations such as file system check (e2fsck) and file system re-sizing.


1. Connect NAS through SSH using Putty (admin user only)

2. swapoff volume mdx ( x denote the number of bays or slots of your NAS e.g TS-410 --> md4)

• [~] # swapoff /dev/md4

3. Stop the volume

• [~] # mdadm -S /dev/md4

4. Make swap of individual partitions and swap them on

• [~] # for A in a b c d; do mkswap /dev/sd${A}2; swapon /dev/sd${A}2; done   note: a,b,c, and d are the trays/bays with HDDs conforming the RAID.

5. After this you can check again the total swap memory with the free command (optional):

• [~] # free


Compatibility: Applies for firmwares below 4.0.5

(9 vote(s))
Not helpful

Comments (0)