How To Create a Swap Partition on a flash drive

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP








up vote
0
down vote

favorite












So I am looking to create a swap partition on a flash drive for a program I am working on. We have successfully created the partition on the drive, but when we plug the drive into the router, the router is unable to read the partition. When we plugged the drive into a different computer, we had to manually activate the partition each time. All of the guides we have found on automatically activating the drive only apply to a single computer. Is it possible to have the partition automatically activate on any computer?







share|improve this question




















  • The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
    – sudodus
    May 27 at 4:22














up vote
0
down vote

favorite












So I am looking to create a swap partition on a flash drive for a program I am working on. We have successfully created the partition on the drive, but when we plug the drive into the router, the router is unable to read the partition. When we plugged the drive into a different computer, we had to manually activate the partition each time. All of the guides we have found on automatically activating the drive only apply to a single computer. Is it possible to have the partition automatically activate on any computer?







share|improve this question




















  • The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
    – sudodus
    May 27 at 4:22












up vote
0
down vote

favorite









up vote
0
down vote

favorite











So I am looking to create a swap partition on a flash drive for a program I am working on. We have successfully created the partition on the drive, but when we plug the drive into the router, the router is unable to read the partition. When we plugged the drive into a different computer, we had to manually activate the partition each time. All of the guides we have found on automatically activating the drive only apply to a single computer. Is it possible to have the partition automatically activate on any computer?







share|improve this question












So I am looking to create a swap partition on a flash drive for a program I am working on. We have successfully created the partition on the drive, but when we plug the drive into the router, the router is unable to read the partition. When we plugged the drive into a different computer, we had to manually activate the partition each time. All of the guides we have found on automatically activating the drive only apply to a single computer. Is it possible to have the partition automatically activate on any computer?









share|improve this question











share|improve this question




share|improve this question










asked May 27 at 1:34









Terry

1




1











  • The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
    – sudodus
    May 27 at 4:22
















  • The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
    – sudodus
    May 27 at 4:22















The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
– sudodus
May 27 at 4:22




The normal way to activate swap is via a line in the file /etc/fstab in the operating system, that you run (or intend to run). You can also activate it 'manually' via sudo swapon -a There is a detailed description in man swapon. Finally, you can make the system run sudo swapon -a automatically in a way that does not cause problems, if the drive with swap is not plugged in.
– sudodus
May 27 at 4:22










1 Answer
1






active

oldest

votes

















up vote
4
down vote













I wouldn't suggest creating a swap partition on a flash device. The read/write rate when swapping would shorten the life of the drive considerably. But if you like, here how its done:



Open disks from dash, and follow the images below in the order that they are listed:
Click the + sign to create a partition



enter image description here



Make sure the right type is choose, and name is optional, and them click create



enter image description here



Click the little wheels, to change the partition type



enter image description here



Make sure the right type is chosen, and click change



enter image description here



Notice that the partition type is now Swap



enter image description here



Click on the little square to mount, and that's it



enter image description here



This answer was copied from here






share|improve this answer




















  • +1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
    – sudodus
    May 27 at 4:16










Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "89"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: true,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);








 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1040739%2fhow-to-create-a-swap-partition-on-a-flash-drive%23new-answer', 'question_page');

);

Post as a guest






























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes








up vote
4
down vote













I wouldn't suggest creating a swap partition on a flash device. The read/write rate when swapping would shorten the life of the drive considerably. But if you like, here how its done:



Open disks from dash, and follow the images below in the order that they are listed:
Click the + sign to create a partition



enter image description here



Make sure the right type is choose, and name is optional, and them click create



enter image description here



Click the little wheels, to change the partition type



enter image description here



Make sure the right type is chosen, and click change



enter image description here



Notice that the partition type is now Swap



enter image description here



Click on the little square to mount, and that's it



enter image description here



This answer was copied from here






share|improve this answer




















  • +1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
    – sudodus
    May 27 at 4:16














up vote
4
down vote













I wouldn't suggest creating a swap partition on a flash device. The read/write rate when swapping would shorten the life of the drive considerably. But if you like, here how its done:



Open disks from dash, and follow the images below in the order that they are listed:
Click the + sign to create a partition



enter image description here



Make sure the right type is choose, and name is optional, and them click create



enter image description here



Click the little wheels, to change the partition type



enter image description here



Make sure the right type is chosen, and click change



enter image description here



Notice that the partition type is now Swap



enter image description here



Click on the little square to mount, and that's it



enter image description here



This answer was copied from here






share|improve this answer




















  • +1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
    – sudodus
    May 27 at 4:16












up vote
4
down vote










up vote
4
down vote









I wouldn't suggest creating a swap partition on a flash device. The read/write rate when swapping would shorten the life of the drive considerably. But if you like, here how its done:



Open disks from dash, and follow the images below in the order that they are listed:
Click the + sign to create a partition



enter image description here



Make sure the right type is choose, and name is optional, and them click create



enter image description here



Click the little wheels, to change the partition type



enter image description here



Make sure the right type is chosen, and click change



enter image description here



Notice that the partition type is now Swap



enter image description here



Click on the little square to mount, and that's it



enter image description here



This answer was copied from here






share|improve this answer












I wouldn't suggest creating a swap partition on a flash device. The read/write rate when swapping would shorten the life of the drive considerably. But if you like, here how its done:



Open disks from dash, and follow the images below in the order that they are listed:
Click the + sign to create a partition



enter image description here



Make sure the right type is choose, and name is optional, and them click create



enter image description here



Click the little wheels, to change the partition type



enter image description here



Make sure the right type is chosen, and click change



enter image description here



Notice that the partition type is now Swap



enter image description here



Click on the little square to mount, and that's it



enter image description here



This answer was copied from here







share|improve this answer












share|improve this answer



share|improve this answer










answered May 27 at 4:04









SaWin

1067




1067











  • +1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
    – sudodus
    May 27 at 4:16
















  • +1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
    – sudodus
    May 27 at 4:16















+1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
– sudodus
May 27 at 4:16




+1 for the warning to avoid swapping to a flash drive. @Terry, Not only will it wear out, it is also very show. But if you use a modern SSD (via USB) the lifetime will be longer (and it is much faster). You get a more reliable swap partition, if you connect a hard disk drive via USB (slower than the SSD, but you can expect a longer life).
– sudodus
May 27 at 4:16












 

draft saved


draft discarded


























 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1040739%2fhow-to-create-a-swap-partition-on-a-flash-drive%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How do so many people here on Academia.SE, and in general, afford lavish higher education programs?

Trouble downloading packages list due to a “Hash sum mismatch” error

How do I move numbers in filenames, in a batch renaming operation?