Having Problems with Partitions on a New Install

I am trying to set up a separate partition for /var, /tmp/ /home/ and /opt for a new Debian 5.0 installation. I have searched through the forums and thought I understood what to do, but it is not working. This is what I did:

1. Created 4 disk images for each partition using the raw format.

2. Created a new Debian 5.0 profile

3. Booted the new profile

4. Edited /etc/fstab to read:

# <file system=""> <mount point="">   <type>  <options>       <dump>  <pass>
proc            /proc           proc    defaults        0       0
/dev/xvda       /               ext3    noatime,errors=remount-ro 0       1
/dev/xvdb       none            swap    sw              0       0
/dev/xvdc    /home       ext3    defaults    1   2
/dev/xvdd    /opt        ext3    defaults    1   2
/dev/xvde    /tmp        ext3    defaults    1   2
/dev/xvdf    /var        ext3    defaults    1   2</pass></dump></options></type></mount></file>

5. Rebooted

When I look in /home I am seeing what the original Debian 5.0 profile, and not my new partition. When I try mounting a partition manually, I get this error:

li84-151:/# mount /tmp
mount: /dev/xvde is not a valid block device

Do I need to format the disk images? The instructions on the web interface said to make these disk images raw if they are to be used as a partition - > If you plan on partitioning the device, use "unformatted / raw" for the Filesystem Type.
Thanks for any suggestions or a link to the "Linode approve method for creating a new install with separate partitions"!

Mark

6 Replies

You should have chosed ext3/ext2 in the Linode Manger. The "raw format" is for when you wish to use a different file system, or to create individual partitions within that image (i.e. the image becomes a "disk")

But now that you have chosen the raw format, you can format using: mkfs.ext3 /dev/xvde

Thanks. I thought that might be the problem. For future reference, were my steps correct except for choosing "raw" vs "ext3"? Since I haven't put any data on the disks, should I just delete all the images except Debian 5 and make them ext3? Then follow the steps I enumerated? I read in a forum post that my partitions would not be backed-up by Libode if I format them outside the web interface.

Thanks again from newbie land!

Mark

Hi mark,

Before booting into that profile, you need to link your new partitions to it (by editing that profile). Perhaps you did this, but it wasn't listed in your steps. It's set up this way so you can (for example) share a /home disk image across several different profiles.

Edit: Yes, for backups you'll need to create fresh disk images in a supported format.

You'll also want to avoid "raw" disks because the filesystems on them can't be resized by the Web interface when you shuffle your disk allocation around.

It can be done, but you have to deal with shrinking/expanding the filesystems yourself, and at the right point in the process. I have a lot of mail stored in Maildir format, so I have a ReiserFS partition. Whenever I have to rearrange it makes me very nervous!

OK, now I get it. I forgot the step where I configure the Debian image for the new partitions.

If I have to grow/shrink a partition, do I have to move the data off that partition, change the size, and then move it back? Or can I just grow/shrink the partition through the web interface and be confident that I will not loose any data in that partition?

Thanks!

Mark

@mark:

If I have to grow/shrink a partition, do I have to move the data off that partition, change the size, and then move it back? Or can I just grow/shrink the partition through the web interface and be confident that I will not loose any data in that partition?

You will not loose any data - use the online resize tool.

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct