I bought a new USB hard drive the other day. Es nopirku jaunu USB cieto disku otro dienu. I wanted to use it to create backups of my Linux server. Es gribēju izmantot, lai izveidotu dublējumkopijas manu Linux serveri. Here's how I went about formatting and mounting the drive on my Linux server. Lūk, kā es gāju par formatēšanas un uzstādīšanas diska uz manu Linux servera.
The first thing I did was to find out where the disk had been mounted. Vispirms es tomēr bija noskaidrot, kur disks ir uzstādīti. For that I ran the following command: Par to es ilga šādu komandu:
# tail -F /var/log/messages # Tail-F / var / log / messages
When I plugged in the drive into my server there was a message saying the the drive was available at /dev/sdc1. Kad es plugged in iedzīt mana servera bija ziņa sakot disks bija pieejama / dev/sdc1. So the next step was to format the drive. Tātad nākamais solis bija format disks. There are a number of file formats that can by read and written to by Linux, but Windows is a bit more fussy about it. Ir failu formātos skaits, kas varētu ar lasīt un rakstīts, lai ar Linux, bet Windows ir vairāk nervozs mazliet par to. So I decided to use a tried and tested file system that works well with both operating systems. Tāpēc es nolēmu izmantot izmēģinātas un pārbaudītas failu sistēma, kas darbojas arī ar abām operētājsistēmām. I went with FAT. Es devos ar taukiem. So to format the drive as FAT I ran the following command: Tik formatēt disku, kā FAT I ilga šādu komandu:
# mkfs.vfat /dev/sdc1 # Mkfs.vfat / dev/sdc1
In a few minutes the newly formatted drive was ready to go. Ar dažām minūtēm tikko formatēta diska bija gatava iet. Now I wanted to mount it. Tagad es vēlējos mount to. So I created a directory to mount it: Tāpēc es radīju direktorijā mount tā:
# mkdir /media/usbdisk # Mkdir / media / usbdisk
Now, to mount the drive to this mount point I ran the following command: Tagad uzstādīt vadīt šo mount point I ilga šādu komandu:
# mount -t vfat /dev/sdc1 /media/usbdisk # Mount-t VFAT / dev/sdc1 / media / usbdisk
And that's it. Un tas ir viss. My new hard drive was formatted, mounted, and ready to go. Mans jaunais cietais disks ir formatēts, montētas, un gatavi iet. I copied the data I wanted to copy on it and then I unmounted it: Es kopēt datus gribēju nokopēt uz tā, un tad es neiedarināts tā:
# umount /media/usbdisk # Umount / media / usbdisk
NOTE : this last step is very important. PIEZĪME: Šis pēdējais solis ir ļoti svarīgs. If you unplug your drive without unmounting it you could risk the data it holds. Ja jūs Atvienojiet jūsu diska bez unmounting tā jūs varētu radīt risku, dati ir tās rīcībā.
If this is a USB storage device that you might use often and plan to leave it hooked up to your Linux server you can set up the device to be automatically mounted when you boot into Linux. Ja tas ir USB atmiņas ierīci, varētu izmantot bieži, un plāno atstāt saliekts līdz jūsu Linux serveri, varat iestatīt ierīces automātiski uzstādīts, kad jūs ielādēs Linux. To do that make an entry like the one shown below at the end of file /etc/fstab : Lai to izdarītu, kas padara ierakstu kā vienu parādītas tālāk beigas failu / etc / fstab:
/dev/sdc1 /mnt/usbdrive vfat defaults 0 0 / dev/sdc1 / mnt / usbdrive VFAT noklusējumus 0 0
Now your drive will be automatically mounted to your Linux server, and you can take your backups without worrying about mounting a device. Tagad jūsu diska tiks automātiski uzstādīts uz jūsu Linux serveri, un varat lietot backups, neraizējoties par montāžas ierīce.























please hiw do i format my pc hard drive?Each time i try do do so the computer tells me it cant.Also, i tried to uninstall an ms program the other day lūdzu hiw man format datoru cieto disku? Katru reizi, kad mēģinu to darīt, dators saka man tas cant.Also, es mēģināju atinstalēt ms programmas otro dienu
but the system went off before it could complete uninstalling.since then i cant open any ms package,remove program or add any.what must i do to get my system to normal. bet sistēma aizgāja pirms varētu pabeigt uninstalling.since pēc tam nevaru atvērt jebkuru ms paketi, noņemiet programmu vai pievienojiet any.what man jādara, lai saņemtu manu sistēmu normālas.