Stranica: 2/4.

Re: formatiranje stika

Postano: 19 stu 2011, 22:26
Postao/la stefan
hm.. ne znam. cak mislim da to nisam nikad radio. a nemam stick da probam.

Re: formatiranje stika

Postano: 19 stu 2011, 22:32
Postao/la stefan
nesto sam nasao...
da bi formatirao stick - on mora biti unmountan!
probaj

Re: formatiranje stika

Postano: 19 stu 2011, 22:42
Postao/la _samir
nece ): isto mi javi

Re: formatiranje stika

Postano: 19 stu 2011, 23:02
Postao/la zole052
koliko ja znam na sdb stiku bi trebala biti i sdb1 particija :?

Re: formatiranje stika

Postano: 19 stu 2011, 23:31
Postao/la _samir
hocu li pokusati da odem na create new partition table?

Re: formatiranje stika

Postano: 19 stu 2011, 23:43
Postao/la max360se
For all Linux users using usb drives, is really easy. Just plug and play then share data with Windows users through it, is very simple. But if you format it using Linux ext3 or any other Linux mode, you will not be able to share data with Windows users. What you need is to format the usb drive using FAT32 or NTFS file system.

So to format a usb drive, first insert your usb drive in the usb slot of your computer, and check using below command:
$ fdisk -l
(You will see the usb disk)

Let say /dev/sdb is where my usb thumb drive was connected.

We need to unmount it:
$ umount /dev/sdb

Now, fdisk the usb stick, and not the partition:
$ fdisk /dev/sdb

Press ‘p’ to view the partitions on the drive. Delete all partitions. Create a new one with ‘n’. It will be a primary partition, and it will be partition 1. Then ‘w’ to write the partition table, and exit:

Command (m for help): p

Disk /dev/sdb: 1027 MB, 1027604480 bytes
64 heads, 32 sectors/track, 980 cylinders
Units = cylinders of 2048 * 512 = 1048576 bytes
Disk identifier: 0x610fbfb2

Device Boot Start End Blocks Id System
/dev/sdb1 * 1 980 1003504 c ext3

Command (m for help): d
Selected partition 1

Command (m for help): n
Command action
e extended
p primary partition (1-4)
p
Partition number (1-4): 1
First cylinder (1-980, default 1):
Using default value 1
Last cylinder, +cylinders or +size{K,M,G} (1-980, default 980):
Using default value 980

Command (m for help): w
The partition table has been altered!

Calling ioctl() to re-read partition table.
Syncing disks.

use the mkfs.vfat or mkfs.ntfs command to format to FAT32 or NTFS filesystem:
$ sudo mkfs.vfat -n ‘Label’ -I /dev/sdb
(Replace Label with the name you want the pen drive to have)

4. That’s it! When done formatting, you’ll be returned to the prompt
$ mkfs.vfat -n ‘sathya’ -I /dev/sdb
mkfs.vfat 2.11 (12 Mar 2011)

Remove and insert the pen drive to have mounted again!
Step-1: Login as super user
$su
password:

Step-2: Find out under which device your pen drive is usually mounted.

There a two ways you can find it out. Click on flash drive icon and see device name under it is mounted. or find it out in console (terminal) -

Try df command lists mounted storage devices -
# df
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda3 56108128 7918984 45293028 15% /
/dev/sda1 513468 22824 464140 5% /boot
tmpfs 387072 24 387048 1% /dev/shm
/dev/sdb 1005632 324 1005308 1% /media/disk

As you can see above my flash drive device (/dev/sdb) is mounted at /media/disk

Step-3: Once you have identified, unmount it.
#umount /media/disk/

Step-4: Format it
#/sbin/mkdosfs -F32 -I /dev/sdb

[Note: I- Capital Letter of i]

Hope that helps!

Re: formatiranje stika

Postano: 19 stu 2011, 23:50
Postao/la _samir
a vidis sta kdo mene kaze:

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x2c42ae10

Device Boot Start End Blocks Id System
/dev/sda1 2048 409599 203776 7 HPFS/NTFS/exFAT
/dev/sda2 409600 205207425 102398913 7 HPFS/NTFS/exFAT
/dev/sda3 * 205207552 410009599 102401024 f W95 Ext'd (LBA)
/dev/sda4 410009600 976768333 283379367 7 HPFS/NTFS/exFAT
/dev/sda5 205209600 209422335 2106368 82 Linux swap / Solaris
/dev/sda6 209424384 251369471 20972544 83 Linux
/dev/sda7 251371520 410009599 79319040 83 Linux

Disk /dev/sdb: 4103 MB, 4103077888 bytes
127 heads, 62 sectors/track, 1017 cylinders, total 8013824 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x6f20736b

This doesn't look like a partition table
Probably you selected the wrong device.


Device Boot Start End Blocks Id System
/dev/sdb1 ? 778135908 1919645538 570754815+ 72 Unknown
/dev/sdb2 ? 168689522 2104717761 968014120 65 Novell Netware 386
/dev/sdb3 ? 1869881465 3805909656 968014096 79 Unknown
/dev/sdb4 ? 2885681152 2885736650 27749+ d Unknown

Partition table entries are not in disk order

Re: formatiranje stika

Postano: 19 stu 2011, 23:58
Postao/la max360se
Daj ispis od fdisk -l

Re: formatiranje stika

Postano: 20 stu 2011, 00:00
Postao/la _samir
evo:

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x2c42ae10

Device Boot Start End Blocks Id System
/dev/sda1 2048 409599 203776 7 HPFS/NTFS/exFAT
/dev/sda2 409600 205207425 102398913 7 HPFS/NTFS/exFAT
/dev/sda3 * 205207552 410009599 102401024 f W95 Ext'd (LBA)
/dev/sda4 410009600 976768333 283379367 7 HPFS/NTFS/exFAT
/dev/sda5 205209600 209422335 2106368 82 Linux swap / Solaris
/dev/sda6 209424384 251369471 20972544 83 Linux
/dev/sda7 251371520 410009599 79319040 83 Linux

Disk /dev/sdb: 4103 MB, 4103077888 bytes
127 heads, 62 sectors/track, 1017 cylinders, total 8013824 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x6f20736b

This doesn't look like a partition table
Probably you selected the wrong device.

Device Boot Start End Blocks Id System
/dev/sdb1 ? 778135908 1919645538 570754815+ 72 Unknown
/dev/sdb2 ? 168689522 2104717761 968014120 65 Novell Netware 386
/dev/sdb3 ? 1869881465 3805909656 968014096 79 Unknown
/dev/sdb4 ? 2885681152 2885736650 27749+ d Unknown

Partition table entries are not in disk order

Re: formatiranje stika

Postano: 20 stu 2011, 00:04
Postao/la max360se
pretpostavljam da ti je /dev/sdb stick kojeg zelis formatirati, samo za svaki slucaj prije nego napravis sljedece odspoji stick i opet daj tu komandu da budes siguran da je to to.
sljedece komander pokreces kao root:
umount /dev/sdb
mkfs.vfat -n ‘Label’ -I /dev/sdb -umijesto 'label' stavi neko ime pazi da maknes navodnike
nakon toga odspoji pa spoji disk