I am currently running SuSE Linux 8.2 Professional. It is my "production" installation so, at the very least, I would like to install another copy for experimentation -- which is my main purpose for posting this query.
I have three hard drives on my system.
The first hard drive (40 GB, IDE 1, Primary) contains Windows 2000 Professional and Windows XP Professional. (You may wonder why I have two versions of Windows, but I have certain programs that run only on each version; mostly, I use XP when I use Windows.) The Windows 2000 Pro partition contains PartionMagic 8.0/BootMagic and, for backups, Drive Image 2002; I also plan to install Oracle 8i here, after I have perused the workaround document for getting 8i to run on a Pentium 4 (which it is not supposed to be able to do).
My second hard drive (60 GB, IDE 1, Secondary) contains SuSE Linux 8.2 Pro only, so I have some room if I make some changes.
The third hard drive (30 GB, RAID controller, IDE 3) is for storage of backup images from Drive Image 2002.
My CD-ROM drive/burner and DVD-ROM drive are installed on IDE 2, by the way.
As I say, at the minimum I want a duplicate of SuSE Linux 8.2 Pro, but I am interested in other distributions, primarily Debian and Gentoo.
I would prefer, incidentally, both for the sake of simplicity, and for security, for the distributions not to share partitions on the 60-GB drive -- at least not when I start out "cloning" my SuSE installation.
I continue to do research on this forum and on Google, but I have been using Linux only since November and I am "in over my head."
My 'grub.conf' file, which looks very strange, is as follows:
root (hd1,1)
install --stage2=/boot/grub/stage2 [WRAP]
/boot/grub/stage1 d (hd1,1) /boot/grub/stage$
quit
(I have never seen a 'grub.conf' file that resembles this one!)
I installed SuSE via the default installation program. If there is an expert mode, I would not have been qualified to use it, but there were options, several of which I exercised.
In addition, SuSE defaults to having 'swap' the same size as one's physical memory (1 GB in my case). When I tried to reduce the size during installation, via the custom settings, I received a plethora of error messages, got scared, :) and went with the default.
Because PartitionMagic 8.0 (whatever you may think of it) is my primary bootloader, I used my inexperienced, best judgment to pick a location on the SuSE drive. I cannot recall from the installation, where I put the bootloader, which I know is vital, even if I just want to install a duplicate of SuSE 8.2 -- although I would like the option to install other distributions.
At the minimum, can someone please tell me the safest procedure for installing another copy of SuSE 8.2 on this same drive? (I want an exact copy of my current installation.) Ideally, I would like advice on installing Debian and/or Gentoo in the near future, but I realize and understand that people have limited time (and patience). ;)
Thank you very much, in advance, for your time and help! :)
Cordially,
David
--
http://ddickerson.igc.org/
P.S. -- I apologize for the rambling nature of this query. Please do let me know if you have any questionns. Thanks!
o0zi
08-20-2003, 02:58 AM
If you want an exact copy, you should use PartImage (http://www.partimage.org). Copy your partition into an image file, create another empty partition and extract the image file into that partition. The PartImage documentation should tell you how - it's not too difficult, as it has a menu-based system.
mdwatts
08-20-2003, 05:48 AM
Hi David...
Your Grub config is /boot/grub/menu.lst
Redhat uses grub.conf instead of menu.lst for the Grub configuration.
Do you have free space on your SuSE HD or do you need to resize the existing partitions to make room for the extra distros?
terribleRobbo
08-20-2003, 07:44 AM
You can duplicate the partition by using:
dd if=/dev/hdx# of=/dev/hd$% count=1
Where 'x#' is replaced by the harddrive and partition you wish to copy, and '$%' is replaced by the destination.
I think. Check with the others before trying this - I've never had a go at doing this before, y'see.
DavidMD
08-20-2003, 07:12 PM
Originally posted by o0zi
If you want an exact copy, you should use PartImage (http://www.partimage.org). Copy your partition into an image file, create another empty partition and extract the image file into that partition. The PartImage documentation should tell you how - it's not too difficult, as it has a menu-based system.
Hi, o0zi.
Thank you for the tip about PartImage. I have read good things about it in JustLinux and it has been recommended to me for backups.
I have been reading the PartImage documentation and FAQs, o0zi, and I understand that it will not back up a partition that contains no data. I also know that if I want to back up '/root' or '/boot' that I must do so to another device.
How do I do a complete system backup then? For example, 'swap' on my system is equal to my RAM (1 GB) and I am sure that it never gets used. Does that mean that 'swap' will not get backed up?
When I restore my backup of SuSE Linux 8.2 Pro, I want an exact duplicate of that system for restoration -- or perhaps I am trying to do something that, technically, I cannot do. :)
Thanks, o0zi!
Cordially,
David
--
http://ddickerson.igc.org/
DavidMD
08-20-2003, 07:30 PM
Originally posted by mdwatts
Hi David...
Your Grub config is /boot/grub/menu.lst
Redhat uses grub.conf instead of menu.lst for the Grub configuration.
Do you have free space on your SuSE HD or do you need to resize the existing partitions to make room for the extra distros?
Hi, Mike!
Thanks for the tip about the GRUB configuration file! Below is a copy of mine.
linux:/boot/grub # more menu.lst
# Modified by YaST2. Last modification on Sat May 17 23:34:21 2003
color white/blue black/light-gray
default 0
gfxmenu (hd1,1)/boot/message
timeout 8
title linux
kernel (hd1,1)/boot/vmlinuz root=/dev/hdb2 vga=0x317 hdc=ide-scsi hdclun=0
splash=silent showopts
initrd (hd1,1)/boot/initrd
Regarding your question about disk space, Mike, SuSE Linux 8.2 occupies all of my secondary hard drive (HDE 2), but it does not need all of that disk space. I do, therefore, have the room for other distributions, including a "clone" of my SuSE installation, but -- obviously -- I need to restructure the drive (a subject on which I will need additional expert advice). :)
Thank you, Mike!
Cordially,
David
--
http://ddickerson.igc.org/
DavidMD
08-20-2003, 07:35 PM
Originally posted by terribleRobbo
You can duplicate the partition by using:
dd if=/dev/hdx# of=/dev/hd$% count=1
Where 'x#' is replaced by the harddrive and partition you wish to copy, and '$%' is replaced by the destination.
I think. Check with the others before trying this - I've never had a go at doing this before, y'see.
Hi, terribleRobbo!
Thank you for the advice.
It sounds like PartImage does essentially the same thing. (I assume that the command you give does not back up empty partitions?)
Thanks again, terribleRobbo!
Cordially,
David
--
http://ddickerson.igc.org/
P.S. -- I apologize for posting multiple replies, to everyone who was kind enough to offer me help. A single message to everyone would have been quite sufficient!
I think my brain slipped into neutral! :rolleyes:
o0zi
08-21-2003, 03:13 AM
You can call me Rob if you'd like:)
A swap partition is essentially the same over all Linux systems, so you don't need to back it up. As long as you place a swap partition of the same size where the other one was, there shouldn't be any difference.
mdwatts
08-21-2003, 07:45 AM
You will need to use something like GNU Parted to resize your existing Linux partitions to leave enough space for the new.
Then of course the partition assignments will then change of which you may need to modify hd1,2 and the mountpoints in /etc/fstab. If you are creating the free space after the first Linux root partition, then only the swap partition will be affected and then you will need to change i.e. hdb5 to hdb6 in /etc/fstab for the swap partition.
We do have a few JL Help Files on creating Linux partitions etc. that will certainly help.
For Grub, add a new section for the second Linux installation though that will depend on what the new partition assignments will be.
An example...
title linux 2
kernel (hd1,2)/boot/vmlinuz root=/dev/hdb3 vga=0x317 hdc=ide-scsi hdclun=0
splash=silent showopts
initrd (hd1,2)/boot/initrd
DavidMD
08-23-2003, 12:48 PM
Originally posted by o0zi
You can call me Rob if you'd like:)
A swap partition is essentially the same over all Linux systems, so you don't need to back it up. As long as you place a swap partition of the same size where the other one was, there shouldn't be any difference.
Hi, Rob!
Thank you for your message and for giving me your real name. :) (I always feel weird addressing people by their "screen names" in JustLinux.)
Your comment about the swap partition is very helpful, Rob. Thank you.
I do have a newbie question that I realize is probably a stupid one, but how do I place the swap partition in my original and "clone" copies of SuSE Linux -- the answer to which I know applies to all distributions?
My swap partition for SuSE, by the way, is 1 GB, which is the default but really too big; could I create a smaller swap partition safely, or do I need to leave 'swap' at 1 GB because it was the original size?
Thanks, Rob!
Cordially,
David
--
http://ddickerson.igc.org/
P.S. -- My next decision will be what third distribution to install, in addition to the "two SuSEs." I am leaning toward Debian and Gentoo (either or both, if I have room).
Of course, discussing distributions is off-topic in this thread, although I do need to make the best use of my disk space. :)
DavidMD
08-23-2003, 12:53 PM
Originally posted by terribleRobbo
You can duplicate the partition by using:
dd if=/dev/hdx# of=/dev/hd$% count=1
Where 'x#' is replaced by the harddrive and partition you wish to copy, and '$%' is replaced by the destination.
I think. Check with the others before trying this - I've never had a go at doing this before, y'see.
Hi, Rob!
If my memory serves me correctly, the 'dd' command will copy empty partitions. Am I correct?
If I am correct, then I would not need to worry about recreating empty partitions, such as 'swap', because 'dd' would have copied them, which definitely appeals to me -- if someone can confirm the command you gave is correct, per your suggestion that I check with others.
Thank you, Rob! :)
Cordially,
David
--
http://ddickerson.igc.org/
DavidMD
08-23-2003, 01:13 PM
Originally posted by mdwatts
You will need to use something like GNU Parted to resize your existing Linux partitions to leave enough space for the new.
Then of course the partition assignments will then change of which you may need to modify hd1,2 and the mountpoints in /etc/fstab. If you are creating the free space after the first Linux root partition, then only the swap partition will be affected and then you will need to change i.e. hdb5 to hdb6 in /etc/fstab for the swap partition.
We do have a few JL Help Files on creating Linux partitions etc. that will certainly help.
For Grub, add a new section for the second Linux installation though that will depend on what the new partition assignments will be.
An example...
title linux 2
kernel (hd1,2)/boot/vmlinuz root=/dev/hdb3 vga=0x317 hdc=ide-scsi hdclun=0
splash=silent showopts
initrd (hd1,2)/boot/initrd
Hi, Mike!
Thank you for your detailed message! Because I have never attempted a task remotely similar to this one, I am very apprehensive. I felt as if I were "drinking from a fire hose" as I read your message! :eek:
My first step, I assume, is to read the documentation for GNU Parted. (I would appreciate suggestions of other tools, also.)
My second step would be to read the JustLinux help files on creating Linux partitions.
Mike, I plan on my first distribution on the drive to be my backed up and restored SuSE installation. My second distribution would be an exact clone of this installation, which I could use for experimentation.
If space permits, I probably will install Gentoo and Debian. If space is tight, I will have to decide between the two. If I have no space left, then I will just have two copies of SuSE, or I could have my original SuSE plus either Gentoo or Debian. (It might be more educational for me anyway to have SuSE, plus another, different distribution for experimenting. What does everyone think?)
I will read the GNU Parted documentation and the JustLinux help files, Mike, and then I should be in a better position to clarify additional questions.
As a newbie/neophyte, I am overwhelmed and terrified of messing up a situation that is stable (i.e., SuSE 8.2 Pro as the only distribution on my secondary drive). On the other hand, I know that I will only learn by doing!
If any other suggestions come to mind, Mike, I would appreciate them. Otherwise, I will read the documentation that you suggest, and then ask more questions.
Thank you very much, Mike, for your time and help!
Cordially,
David
--
http://ddickerson.igc.org/
o0zi
08-23-2003, 01:20 PM
If you want to resize your swap partition, it's probably easier to remove it and add a smaller one.
Delete the swap partition and add a smaller one with cfdisk or parted (two partitioning tools), but make sure the new one you add is of type "Linux Swap". Anything from 256-512Mb should be adequate.
Then, add to your startup scripts:
swapon /dev/hda5
if your swap partition is on /dev/hda5 - this makes the system actually use the swap partition.
DavidMD
08-23-2003, 08:48 PM
Originally posted by o0zi
If you want to resize your swap partition, it's probably easier to remove it and add a smaller one.
Delete the swap partition and add a smaller one with cfdisk or parted (two partitioning tools), but make sure the new one you add is of type "Linux Swap". Anything from 256-512Mb should be adequate.
Then, add to your startup scripts:
swapon /dev/hda5
if your swap partition is on /dev/hda5 - this makes the system actually use the swap partition.
Hi, Rob!
Thanks for your message!
I will read the JustLinux help file on partitions, but I will also ask you my question here, a question that I know reflects my vast ignorance. ;)
How do I delete the swap partition? When I run the 'locate' command for "swap," I get no result.
I will research 'cfdisk' and 'parted' to see which one is best for me. My current SuSE Linux installation is on (all of) '/dev/hdb2', so I assume that I should add 'swapon /dev/hdb2/?' to my startup scripts.
Finally, I have one more stupid :confused: question, Rob. I have never edited startup scripts. Where are they typically located?
Thank you very much, Rob, for your time, help, and patience!
Cordially,
David
--
http://ddickerson.igc.org/
o0zi
08-24-2003, 01:56 AM
I suppose I'd better explain a few things first:
locate is a command which finds files on your system. It doesn't have anything to do with partitions.
You use cfdisk or parted to delete, create and resize partitions. You'd probably prefer cfdisk, as it's very easy to use.
If your SuSe installation is on /dev/hdb2, then you don't want to try and turn that on as a swap partition. Find out the name of your swap partition, and that is what you put after swapon.
If you've never edited startup scripts, they might seem confusing at first. Look for a file called rc.local in either the /etc/rc.d or the /etc/init.d directories. Then just add the swapon command to the end of rc.local. If you need more help with the startup scripts, reply back and I'll help, or search on the forum for the countless threads on this topic.
DavidMD
08-24-2003, 08:50 PM
Originally posted by o0zi
I suppose I'd better explain a few things first:
locate is a command which finds files on your system. It doesn't have anything to do with partitions.
You use cfdisk or parted to delete, create and resize partitions. You'd probably prefer cfdisk, as it's very easy to use.
If your SuSe installation is on /dev/hdb2, then you don't want to try and turn that on as a swap partition. Find out the name of your swap partition, and that is what you put after swapon.
If you've never edited startup scripts, they might seem confusing at first. Look for a file called rc.local in either the /etc/rc.d or the /etc/init.d directories. Then just add the swapon command to the end of rc.local. If you need more help with the startup scripts, reply back and I'll help, or search on the forum for the countless threads on this topic.
Hi, Rob!
Thank you very much for your patience and the detailed explanation. I guess my first step is to use 'cfdisk' to determine the name of my swap partition?
Next, I assume that I should reduce the size of the swap partition with 'cfdisk', before backing up my Linux installation. (Actually, I guess 'rc.local' will provide me with the name of my current swap partition, won't it? I will check.)
Again, Rob, thank you. I am sure that I will have more questions! :confused:
Cordially,
David
--
http://ddickerson.igc.org/
P.S. -- The two distributions that I am considering adding, if disk space allows, in addition to a clone of my SuSE installation, are Gentoo and Debian.
Given your forum avatar, I am sure that you would recommend Gentoo. ;)
o0zi
08-25-2003, 04:19 AM
You shouldn't find your swap partition in rc.local because I kind of gave you a quick and dirty solution - the swap space is activated in another startup script depending on your distribution. Your distribution may even add it automatically if you create another swap partition. Adding the swapon command in rc.local will still work, though.
Gentoo is good, but it can be a bit daunting sometimes, and it can take quite some time to install (because everything is compiled from source).
If you're planning to install Debian, get Knoppix, a LiveCD distro, and then install it to hard-disk. Then it's basically Debian with newer packages and better hardware support.
mdwatts
08-25-2003, 05:29 AM
The swap partition is defined in /etc/fstab. If you add another partition before the swap partition, then you will need to change the swap device in /etc/fstab from i.e. /dev/hda6 to /dev/hda7.
That should be all that is required for swap.
o0zi
08-25-2003, 11:43 AM
Yeah, that's what I was going to suggest, but I thought that editing /etc/fstab might be a little too advanced, though it is the proper way to do it.
DavidMD
08-25-2003, 10:44 PM
Originally posted by o0zi
You shouldn't find your swap partition in rc.local because I kind of gave you a quick and dirty solution - the swap space is activated in another startup script depending on your distribution. Your distribution may even add it automatically if you create another swap partition. Adding the swapon command in rc.local will still work, though.
Gentoo is good, but it can be a bit daunting sometimes, and it can take quite some time to install (because everything is compiled from source).
If you're planning to install Debian, get Knoppix, a LiveCD distro, and then install it to hard-disk. Then it's basically Debian with newer packages and better hardware support.
Hi, Rob!
Thank you for the clarification about the swap partition. I do not know how my distribution, SuSE, handles the swap partition in a situation such as this one.
Thank you also, Rob, for your advice about distributions.
I know that I can get Gentoo, for the Pentium 4 architecture, on two CD-ROMS from the Gentoo on-line shop.
I have a copy of the Knoppix CD distribution actually, Rob. I bought it for Roma (who'll be twelve in October), the son of my fiancee in Odessa, Ukraine. (I have gotten Roma interested in Linux and in Star Trek. I have found some really nice Web sites, in Russian, on both topcs.) ;) The next time I go to Odessa, I will probably install ASP Linux (which has excellent support for Russian) on Roma's PC, which is running Windows 98. (I just wish I knew more about his hardware; SuSE has great hardware support, but I do not know about ASP Linux.) But I digress.... :)
Could you please clarify your statement, Rob, about Knoppix being "basically Debian with newer packages and better hardware support"? How is Knoppix similar to Debian?
I know that the full Debian set fills six CD-ROMs, but am I to assume that most of that content is applications, not unlike SuSE, which comes boxed with seven CD-ROMs or, as a convenient alternative, two DVDs? (I did notice on the Debian Web site that some parts of it are old, such as the version of KDE, which is not true of SuSE.)
Thank you, as always, Rob!
Cordially,
David
--
http://ddickerson.igc.org/
DavidMD
08-25-2003, 10:49 PM
Originally posted by mdwatts
The swap partition is defined in /etc/fstab. If you add another partition before the swap partition, then you will need to change the swap device in /etc/fstab from i.e. /dev/hda6 to /dev/hda7.
That should be all that is required for swap.
Hi, Mike!
Thank you for your message.
Basically you are saying that, if I add another swap partition in 'fstab', I need change the original swap partition to the next highest device number?
Currently, I have SuSE Linux filling '/dev/hdb2'. At this stage, of course, I do not know what the swap device will need to be.
Thanks, Mike!
Cordially,
David
--
http://ddickerson.igc.org/
DavidMD
08-25-2003, 10:52 PM
Originally posted by o0zi
Yeah, that's what I was going to suggest, but I thought that editing /etc/fstab might be a little too advanced, though it is the proper way to do it.
Hi, Rob.
Ironically, 'fstab' is one of the system files that I have actually edited. :D
Your concern, however, is a valid one, because I am very much the "newbie." I am already overwhelmed by this discussion topic that I began!
Thanks!
Cordially,
David
--
http://ddickerson.igc.org/
o0zi
08-26-2003, 03:45 AM
Knoppix is a Debian-based distribution, that is, the creator (Klaus Knopper) took Debian and edited it so that it would boot off a single CD. That means that Knoppix has Debian's packaging system and quite a few other similarities.
If you upgrade Debian to the latest packages, it would almost be identical to Knoppix in most ways. So just think of Knoppix as Debian with a nicer installer, better hardware detection and newer software.
DavidMD
08-27-2003, 08:34 PM
Hi, Rob!
Thank you for your message and the clarification about the origins of Knoppix and its relationship to Debian. I cannot access the Knoppix Web site, however, because it is temporarily closed in protest of software patents, with no way to access the Knoppix site. (FVWM2 (http://www.fvwm.org/) is doing the same protesting, but they still give you a link to their site.)
I assume, however, that although Knoppix is more up to date than Debian, that it lacks quite a bit that comes with Debian. (The Debian.org Web site states that Debian comes with 8710 packages, which I know would not fit on the single Knoppix CD-ROM.) ;)
I guess I could download any of the most current versions of the packages that come with the latest stable release of Debian (http://packages.debian.org/stable/) and use them with Knoppix. The process would be time consuming, but I would certainly learn quite a bit! :)
Thanks again, Rob! I am very grateful for your help!
Cordially,
David
--
http://ddickerson.igc.org/
Originally posted by o0zi
Knoppix is a Debian-based distribution, that is, the creator (Klaus Knopper) took Debian and edited it so that it would boot off a single CD. That means that Knoppix has Debian's packaging system and quite a few other similarities.
If you upgrade Debian to the latest packages, it would almost be identical to Knoppix in most ways. So just think of Knoppix as Debian with a nicer installer, better hardware detection and newer software.
o0zi
08-28-2003, 03:14 AM
No problem:)
If you can't get on the official Knoppix website, http://www.knoppix.net/ is quite good.
DavidMD
08-28-2003, 03:08 PM
Hi, Rob!
Thank you for your suggestion!
I still cannot access the official Knoppix Web site, but I was able to access Knoppix.net today, which I could not do yesterday.
By the way, Knoppix 3.2 is available on DVD-ROM (which was given out at LinuxTag).