首先,我是linux / ubuntu的新手。其次,我自己搜索了一种方法进行了4个小时的搜索,但无法完全找到它或找不到正确的解释方法。对于任何基本的linux / ubuntu用户,如果这是重复或难度为1/100,我深表歉意。
话虽如此,这是我的设置:我正在Acer c7 Chromebook上通过“ Crouton”与ChromeOS一起运行Xubuntu 12.04。这是昨天(是xubuntu)的全新安装。我设法弄清楚了启动器,apt-get和ppa存储库以及这些东西……大部分。我有一些基本程序-FireFox,Skype,VLC,Audacious和qBittorrent。因此,现在我准备下载一些视频和音乐,然后我就解决了问题。
问题是我(非常)很快就用完了空间(剩余660 MB)。问题是这是一个320 GB的HDD,我的台式机上有一个311 GB的灰色驱动器。当我尝试右键单击并安装时,我得到以下信息:
So I went in sudo fdisk -l and it promptly told me that /dev/sda was a GPT and fdisk could not format it, and I needed to get GNU Parted. So I tried simply "sudo apt-get install parted" and sure enough it grabbed GNU Parted 2.3. Here is what (parted) print returned for me:
So my question is how can I get this 311 GB of space working for me as storage? To be clear it's just a partition on my internal 320 GB HDD that came with my Acer c7 chromebook. Do I need to mount it somehow or could I somehow change one of the other existing partitions to just be bigger?
Again I apologize for my level of noviceness and any help is much appreciated!
For a partition or internal hard disk to be accessible in ubuntu it has to be 'mounted'. You can mount partitions manually or automatically.
To mount them manually:
Find out the name of the partition you want to mount. I find it easy to use gparted sudo apt-get install gparted
). You can run sudo gparted
in the commandline. Be careful not to mess anything up. Then you write down the name of the partition you want to mount (for instance sda2
).
Now you need to create a mounting point. That is a point in your filesystem at which the partition will be accessible. It is not actually at that point, it just accessible at that point. You can create a directory for this. For instance, mkdir /media/extra_drive
. Usually you would make this in the media directory which is also where usb sticks will be mounted. Media is usually used for mounts for a particular user (not systemwide, then you'd use mnt).
Now you can mount the partition using
sudo mount /dev/sda2 /media/extra_drive
This can be unmounted manually using sudo umount /media/extra_drive
. The mount is not boot-persistent and you will have to do it on each reboot.
Mounting it on every boot is not handy, therefore you should mount it automatically. To mount it automatically on each boot you have to add it to your fstab file. There is a nice wiki for that, so I will not repeat all the info here unless it is unclear. Essentially you find the UUID (ls -al /dev/disk/by-uuid/
) and then do the following:
Duplicate your fstab file:
sudo cp /etc/fstab /etc/fstab.$(date +%Y-%m-%d)
Compare the two files to confirm the backup matches the original:
cmp /etc/fstab /etc/fstab.$(date +%Y-%m-%d)
Open the original fstab in a text editor:
gksu gedit /etc/fstab
and add these lines into it
# (identifier) (location, eg sda5) (format, eg ext3 or ext4) (some settings) UUID=???????? /media/dir_of_your_choice ext4 defaults 0 2
不管是手动还是自动安装,这样的分区都不会将其自身添加到主文件夹中(因此,其空间仍然很低)。因此,如果您希望像现在这样进行操作,则必须手动将文件放在该分区上。更好的办法是为/home
目录提供自己的分区。有关更多信息(需要一些阅读和工作),请参见。这个不错的维基页面。根据您的主分区的大小,+-300GB分区将构成一个不错的主文件夹。主文件夹的最大优点是您可以重新安装ubuntu而不会丢失文件(如果您知道自己在做什么,并且可以进行安装,这样就不会破坏主分区)。
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句