LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   How to format flashdisk which has unused capacity (https://www.linuxquestions.org/questions/linux-general-1/how-to-format-flashdisk-which-has-unused-capacity-4175473060/)

knottulf 08-12-2013 02:21 AM

How to format flashdisk which has unused capacity
 
I have a terabyte flashdisk, which I used as a target when rescuing a crashed disk. So it is now formatted to only 40GB.
How do I reformat it to 1 terabyte, and partition it to ext3?
Im using a headless ubuntu server 10.04

TobiSGD 08-12-2013 04:54 AM

At first, Ubuntu 10.04 has reached its end-of-life and is unsupported, which means that you won't get bugfixes and, worse, security updates anymore. It is recommended to upgrade to 12.04, which is supported until 2017.

Regarding your problem, just use fdisk or the easier cfdisk (you may probably have to install it first) to delete the old partition (assuming that you have no need anymore for the data or already have a backup copy), create a new one in the size you want to use and then format it using the mkfs command, for example like this if you want to use ext3 (I personally always use ext4, it is faster, especially when a fsck is needed):
Code:

sudo mkfs -t ext3 /dev/sdb1
Make sure that you have chosen the correct partition name (sdb1 is the first partition on the second disk in your system, you most likely will have to adapt that for your needs) before launching the command.


All times are GMT -5. The time now is 05:59 PM.