Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Save RedHat Install

Posted on 2002-06-09
8
225 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
ID: 7078841
Must be more work than I thought. Perhaps this will help
0
 
LVL 40

Expert Comment

by:jlevie
ID: 7100003
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
ID: 7139209
Could you supply some example commands?
I have one partion /dev/hda3 mounted on /
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 
LVL 40

Accepted Solution

by:
jlevie earned 300 total points
ID: 7139302
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
 

Author Comment

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

Expert Comment

by:jlevie
ID: 7142291
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
ID: 7142832
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
ID: 7147726
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

Ransomware: The New Cyber Threat & How to Stop It

This infographic explains ransomware, type of malware that blocks access to your files or your systems and holds them hostage until a ransom is paid. It also examines the different types of ransomware and explains what you can do to thwart this sinister online threat.  

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Little introduction about CP: CP is a command on linux that use to copy files and folder from one location to another location. Example usage of CP as follow: cp /myfoder /pathto/destination/folder/ cp abc.tar.gz /pathto/destination/folder/ab…
Join Greg Farro and Ethan Banks from Packet Pushers (http://packetpushers.net/podcast/podcasts/pq-show-93-smart-network-monitoring-paessler-sponsored/) and Greg Ross from Paessler (https://www.paessler.com/prtg) for a discussion about smart network …
Learn several ways to interact with files and get file information from the bash shell. ls lists the contents of a directory: Using the -a flag displays hidden files: Using the -l flag formats the output in a long list: The file command gives us mor…
Connecting to an Amazon Linux EC2 Instance from Windows Using PuTTY.

856 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