Ask the Experts: I recently reinstalled Windows on my dual boot system and now Linux no longer boots...
Question: I recently had to reinstall Windows on my dual boot system and now Linux no longer boots. Rather than booting to the grub boot manager it now boots directly into Windows. How do I recover my ability to dual boot?" --Tara Ryan, Mountain View, CA
Our friends at Apress have kindly offered one free book or ebook of your choice if we publish your Ask the Experts question. Readers, send your Ask the Experts question in to get in on the action. A free book and free tech support if your question is selected -- pretty cool right? Now on to our responses to this week's question:
Tom Metge responds: You'll need to reinstall GRUB to the MBR of your disk- Windows overwrites it on installation. If you've got a live Linux disc handy (the rescue function on your distro's install disk, for example), boot into the rescue environment and do the following:
- mount your boot and root partitions
- chroot to the root partition
where [dev] = the drive you boot from, in grub format (hd0,0 for the first drive in the system, for example).
Bill Childers, an IT Manager in Silicon Valley responds: Tom's instructions are dead-on. Alternatively, though -- in the event the BIOS doesn't want to probe the drive properly from the chroot you can also re-install grub outside the chroot. Ensure your boot and root partitions are mounted as in Tom's instructions, then run "grub-install --root-directory=/mnt/hda1 /dev/hda" (substitute /mnt/hda1 and /dev/hda for your actual mountpoint and device nodes).
Luis Cerezo responds: When using rescue mode the root part and boot, depending on how your system us set up may need to be mounted in rw mode. Mount -I remount,rw /.
Chris Stark of the University of Hawaii College of Education responds: Hi Tara. Tom, Bill, and Luis all had perfect answers for recovering from this sort of problem. For now, follow their advice for getting your GRUB installation back, then follow my advice for a strategy to help avoid the problem from happening again.
As I'm sure you know, there are hundreds of Linux distros out there, each with a slightly different audience or purpose. A specific distro I'd like to bring to your attention is the Clonezilla Live CD, http://clonezilla.org/.
Download the ISO image and burn it to CD as usual. Set the disk aside for now.
Next, get your Windows installation updated and configured to your liking. I tend to do a fairly minimal amount of tweaking: install any drivers & updates, install an anti-virus and Windows Defender, and turn off the annoying interface sounds.
Once you're satisfied with your Windows installation, reboot using the Clonezilla Live CD, and follow the prompts to create an image of your Windows partition. Clonezilla is very flexible in that it lets you save the image to a network share, external drive, or even a local partition. Now that you have an image, you can confidently go about your business, knowing that the next time Windows blows itself up (...and you know it will...), you'll be ready to get back up and running quickly and painlessly.
Be sure the read the "How to use" link from the Clonezilla homepage. You'll find that Clonezilla is very easy to use, albeit a bit quirky, and restoring your perfectly configured Windows partition means no overwriting the Master Boot Record (thus leaving GRUB intact and ready to dual boot).
If you're like me, and only need Windows around for testing purposes, consider running Windows in a virtual machine, like VirtualBox, http://www.virtualbox.org/.
James Ward of Adobe Systems responds: Boot any Live CD and then run the following command:
sudo grub-install --no-floppy /dev/sda
Assuming that /dev/sda is the device you want to install the boot loader on. Since your Grub configuration should still be intact this should just work.
>> Ask the Experts is a new weekly column featured exclusively on LinuxJournal.com.
>> Question for our experts? E-mail them.
Carlie Fairchild is the publisher of Linux Journal.
Practical Task Scheduling Deployment
July 20, 2016 12:00 pm CDT
One of the best things about the UNIX environment (aside from being stable and efficient) is the vast array of software tools available to help you do your job. Traditionally, a UNIX tool does only one thing, but does that one thing very well. For example, grep is very easy to use and can search vast amounts of data quickly. The find tool can find a particular file or files based on all kinds of criteria. It's pretty easy to string these tools together to build even more powerful tools, such as a tool that finds all of the .log files in the /home directory and searches each one for a particular entry. This erector-set mentality allows UNIX system administrators to seem to always have the right tool for the job.
Cron traditionally has been considered another such a tool for job scheduling, but is it enough? This webinar considers that very question. The first part builds on a previous Geek Guide, Beyond Cron, and briefly describes how to know when it might be time to consider upgrading your job scheduling infrastructure. The second part presents an actual planning and implementation framework.
Join Linux Journal's Mike Diehl and Pat Cameron of Help Systems.
Free to Linux Journal readers.Register Now!
- SUSE LLC's SUSE Manager
- My +1 Sword of Productivity
- Murat Yener and Onur Dundar's Expert Android Studio (Wrox)
- Managing Linux Using Puppet
- Non-Linux FOSS: Caffeine!
- Doing for User Space What We Did for Kernel Space
- SuperTuxKart 0.9.2 Released
- Google's SwiftShader Released
- Parsing an RSS News Feed with a Bash Script
- Rogue Wave Software's Zend Server
With all the industry talk about the benefits of Linux on Power and all the performance advantages offered by its open architecture, you may be considering a move in that direction. If you are thinking about analytics, big data and cloud computing, you would be right to evaluate Power. The idea of using commodity x86 hardware and replacing it every three years is an outdated cost model. It doesn’t consider the total cost of ownership, and it doesn’t consider the advantage of real processing power, high-availability and multithreading like a demon.
This ebook takes a look at some of the practical applications of the Linux on Power platform and ways you might bring all the performance power of this open architecture to bear for your organization. There are no smoke and mirrors here—just hard, cold, empirical evidence provided by independent sources. I also consider some innovative ways Linux on Power will be used in the future.Get the Guide