Solved

Save RedHat Install

Posted on 2002-06-09
8
215 Views
Last Modified: 2013-12-15
I have a HP 4050 notebook with 6 GB drive.

I ran the recovery CD that put it back to factory defaults with a C: partition and a D: partition.
I used System Commander to move the partitions around so I could install RH 7.3 also. Each OS has about
3GB
At this time everything is working just fine. I can boot on Win2K or RH 7.3

I've got quite a bit of time setting this all up and I need this setup for work. On the weekend I would
like to play with Gentoo. I've booted with the Gentoo CD and it recognizes the NIC and sets up networking

Is their any way for me to:
1. Boot with the Gentoo CD and store the RH partition on a NFS share
2. Zap the partition
3. Install Gentoo
4. Come Sunday night swap Gentoo and RH and be ready for work.
5. Next Fri. night swap Gentoo and RH or Gentoo and Win2K for another weekend learning session?

I'm thinking that some sort or tar, gzip, dd, rsync type thing may work. But there is the Grub stuff
and the syntax and mounting stuff I'm not sure of.
0
Comment
Question by:davidpm
  • 5
  • 3
8 Comments
 

Author Comment

by:davidpm
Comment Utility
Must be more work than I thought. Perhaps this will help
0
 
LVL 40

Expert Comment

by:jlevie
Comment Utility
You could certainly use dump/restore to move the contents of the Linux filesystem to/from an NFS mount point. Getting the dump image onto an NFS mount is easy. Getting it back onto your laptop would require a bootable floppy or CD that included networking, NFS, and restore.

The bigger problem will be to boot loader. I don't know anything about Gentoo, so I don't know what it uses or how that might affect the w2k installation. Once the RedHat filesystems have been reloaded running grub-install show restore the MBR to what it was before Gentoo.
0
 

Author Comment

by:davidpm
Comment Utility
Could you supply some example commands?
I have one partion /dev/hda3 mounted on /
0
 
LVL 40

Accepted Solution

by:
jlevie earned 300 total points
Comment Utility
I'd presume that you also have a swap partition for the RedHat installation. First I'd make sure that you uave a working boot floppy for Redhat. If you don't, or have updated the system since installation and it's making of a boot floppy you'll need to make a new one with mkbootdisk. And test it before futzing with the system to make sure it works.

The safe way to dump and restore RH is to boot off of alternate media that includes NFS support, dump, and restore. Your bootable media also needs to understand ext3fs file systems. Once you've booted off of the alternative media, do:

# mkdir /mnt/root /mnt/nfs
# mount /dev/hda3 /mnt/root
# mount server:/path-to/space /mnt/nfs
# dump -0af /mnt/root /mnt/nfs/root.image
# umount /mnt/nfs
# umount /mnt/root

Now you can install Gentoo. When you are done and want to put RH back on, boot from your alternative media and do:

# mke2fs -L / /dev/hda3
# tune2fs -j /dev/hda3
# mkswap /dev/hda?
# mkdir /mnt/root /mnt/nfs
# mount server:/path-to/space /mnt/nfs
# mount /dev/hda3 /mnt/root
# cd /mnt/root
# restore rf /mnt/nfs/root.image
# cd
# umount /mnt/nfs
# chroot /mnt/root
# /sbin/grub-install

Since I don't know what you will be using for an alternative boot I can't exactly tell you what needs to done with it to enable networking and start the NFS mount services. Nor do I know what partition you are using for swap on the RH installation.
0
Get up to 2TB FREE CLOUD per backup license!

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

 

Author Comment

by:davidpm
Comment Utility
Thanks. I'll pass this to my Linux intern. Hope it is all he needs
0
 
LVL 40

Expert Comment

by:jlevie
Comment Utility
How about posting a comment here after you (or your intern) goes through to process. Oh yes, you can always try this on some other system that has a 'throw away' installation on it. I think it would suffice to just have RedHat on the trial system.
0
 

Author Comment

by:davidpm
Comment Utility
Good Idea. I have just the system for that test already built. The only reason why this project came up is that this is a notebook and my trick of using a spare hard drive and just swapping drives does not work as I only have one drive for the notebook.
Thanks.
Did you ever complete that firewall distro experiment you were working on last year?
0
 

Author Comment

by:davidpm
Comment Utility
This worked:
Only thing I had to change was a dump typo and fstab which apparently is required.
Have not tried restore yet.

Boot on Super Rescue CD (http://www.kernel.org/pub/dist/superrescue/v2/
Press enter to boot then ^d for multi-user mode
Logon as root
cardmgr to load network drivers
netconfig to setup networking
/etc/init.d/network restart to start networking
mkdir /mnt/root /mnt/nfs (creates working mount points)
mount /dev/hda3 /mnt/root  (mounts real file system root to virtual root)
mount 192.168.255.195:/mnt/nfs /mnt/nfs (mounts remote files system to local target point)
vi /etc/fstab (add following line)
/dev/hda3     /mnt/root    ext3    defaults          0 0
dump –z1 -0af /mnt/nfs/root.image /mnt/root (This does the dump)
0

Featured Post

Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

Join & Write a Comment

Daily system administration tasks often require administrators to connect remote systems. But allowing these remote systems to accept passwords makes these systems vulnerable to the risk of brute-force password guessing attacks. Furthermore there ar…
I. Introduction There's an interesting discussion going on now in an Experts Exchange Group — Attachments with no extension (http://www.experts-exchange.com/discussions/210281/Attachments-with-no-extension.html). This reminded me of questions tha…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now