<div class="gmail_quote">On Sun, Oct 30, 2011 at 6:34 PM, Avi Greenbury <span dir="ltr"><<a href="mailto:lists@avi.co">lists@avi.co</a>></span> wrote:<br><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<div class="im">Linux Tyro wrote:<br>
<br>
> About how really partitioning works, in fact what exactly it is!<br>
<br>
</div>Basically, partitioning is a way of partitioning off a hard drive into<br>
separate areas. Much as you might divide up a warehouse into areas to<br>
keep distinct sorts of stock in, you can divide up hard drives in the<br>
same way.<br>
<br>
A hard drive is basically a large area of storage, which<br>
allows the computer to set bits of it to values either of 1 or 0. This,<br>
fundamentally, is how the files are stored on the system. But files<br>
have more than just data - they have things like names, and modified<br>
dates and permissions. We therefore tend to use a filesystem on a<br>
drive.<br>
<br>
A filesystem basically sets out a standard for the way files are<br>
to be stored on a drive - how the filename is stored and linked to the<br>
file, and how the permissions work. Common filesystems in Windows are<br>
NTFS and FAT, and Linux tends to use ext3 or ext4. The actual mechanics<br>
of how they work isn't particularly important, but the reason that,<br>
say, Windows needs a different partition to Linux us because Windows<br>
assumes NTFS's way of storing permissions and other file data, and<br>
Linux assumes ext's. [0] You would, therefore, put Windows on an NTFS<br>
filesystem in one partition, and Ubuntu on an ext filesystem in another.<br>
<div class="im"><br>
> - What are these partitions sda1, 2, 3, ....how to know if ubuntu is<br>
> sda1 or sda2 or what and is it different from /home....?<br>
> - When I installed ubuntu 10.04 LTS, it got installed and that<br>
> partition is sda1/2/3/4/5 ...and upto where does this go...?<br>
<br>
</div>In contrast to Window's way of exposing hard drives with drive letters,<br>
Linux lets you 'mount' any drive at any directory. To 'mount' a drive<br>
is to make it available under a directory. If you had a big disk full<br>
of music, for example, you might wish to mount it under the directory<br>
'music' in your home directory, then you just go into that directory to<br>
access the files on the disk.<br>
<br>
/dev/ is a directory in which devices are 'kept'. To mount a drive, you<br>
need to specify which device you want mounted (using its /dev address)<br>
and which directory you want it mounted on.<br>
<br>
/dev isn't reserved for disk drives, though. Disk drives generally<br>
start /dev/sd nowadays.<br>
<br>
/dev/sda is the first drive, /sdv/sdb the second and so on.<br>
<br>
The partitons are then themselves denoted by letters:<br>
<br>
/dev/sda1 is the first partition on the first drive, /dev/sda4 the<br>
fourth. You cannot actually *do* anything to the drives with these<br>
addresses - if you want to get at the files on them you need to<br>
instruct Linux to mount them first. Fortunately, it probably already<br>
has.<br>
<br>
I'm not aware of a graphical way to investigate what's mounted on the<br>
computer, though I'm sure there is one, but you can get an idea if you<br>
open a terminal (ctrl+alt+t) and then enter this text and hit enter:<br>
<br>
mount<br>
<br>
You will see several virtual drives mounted (ones with lines that don't<br>
start '/dev/') but you should be able to pick out the ones that are<br>
real-life drives. The lines are of the form:<br>
<br>
/dev/sda6 on / type ext3 (rw,errors=remount-ro,commit=0)<br>
<br>
This is /dev/sda6 (that is, the sixth partition of the first drive)<br>
Mounted on / (that is, the 'root' directory, so it's where my operating<br>
system is)<br>
Of type ext3 (so the filesystem I'm using is ext3)<br>
<br>
The bits in the brackets are options for mounting, which are likely to<br>
be different, but are rather boring and irrelevant here anyway,<br>
<div class="im"><br>
<br>
> -LVM yet another thing, is related with what...? It is (also) a<br>
> partition or what....? It is sda...?<br>
<br>
</div>LVM is rather more complicated, at least until you're happy with<br>
partitions and mounting and the like. Unless you've need to know and<br>
use it shortly, it would be beneficial to get quite comfortable with<br>
filesystems, partitions and the like before exploring LVM.<br>
<br>
Put simply, though, it provides a means of effectively having<br>
partitions whose sizes can be changed while they're in use - generally<br>
without LVM this is not possible.<br>
<div class="im"><br>
> - Mounting a partition means what, what exactly we are going to do<br>
> with that partition after mounting it and before mounting, was it in<br>
> existence?<br>
<br>
</div>We speak of mounting drive at directories, and you make the contents<br>
of the drive appear as the contents of the directory. Any previous<br>
contents of that directory still exist, but are inaccessible while the<br>
drive is mounted.<font color="#888888"><a href="https://lists.ubuntu.com/mailman/listinfo/ubuntu-users" target="_blank"></a><br>
</font></blockquote></div><br>Thanks a lot to you. I have just started reading all this from the first word where you started. Thx again.<br><br clear="all"><br>-- <br><span style="color:rgb(0, 0, 0)">Two atoms are walking along. Suddenly, one stops. The other says, "What's<br>
wrong?" "I've lost an electron." "Are you sure?" "I'm positive!"<br><br></span><font style="color:rgb(0, 0, 0)" color="#888888">
===================================================</font><br><a href="http://sites.google.com/site/whyilikeubuntu/" target="_blank">Ubuntu LTS is good</a>!<br><font style="color:rgb(0, 0, 0)" color="#888888">
===================================================</font><br><br>