LinuxQuestions.org
Visit the LQ Articles and Editorials section
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices

Reply
 
Search this Thread
Old 01-20-2013, 09:06 AM   #1
lectraplayer
Member
 
Registered: Mar 2003
Location: a little west of Birmingham, AL, USA.
Distribution: SuSE 10
Posts: 915

Rep: Reputation: 30
CHMOD: How do I get my Linux back?


This is a really simple question, but I remember I could bring an installation of Linux back from a Windows takeover by using CHMOD under a boot in Recovery Mode. It does this by reinstating Grub or Lilo back to the MBR as it was prior to the introduction of Windows, allowing the existing OS to boot. What were those arguments again?

chmod ??? ??? ???
 
Old 01-20-2013, 11:20 AM   #2
bigrigdriver
LQ Addict
 
Registered: Jul 2002
Location: East Centra Illinois, USA
Distribution: Debian Squeeze
Posts: 5,785

Rep: Reputation: 311Reputation: 311Reputation: 311Reputation: 311
I don't recall ever hearing of anything such as you describe.

The process of getting grub back to the MBR is much easier than that.

Use your Suse installation disk. Put it in the cd/dvd drive and boot up. At the menu, you should have an option to boot from the disk. Select that and boot from the Suse installation.

Once booted up, run /usr/sbin/grub-install to put grub back into the MBR.
 
Old 01-20-2013, 12:25 PM   #3
lectraplayer
Member
 
Registered: Mar 2003
Location: a little west of Birmingham, AL, USA.
Distribution: SuSE 10
Posts: 915

Original Poster
Rep: Reputation: 30
What about Fedora? I'm not sure what may be easier than one command though. It may be CHOWN instead of CHMOD. I remember I did it before a couple times with that one command.
 
Old 01-21-2013, 05:26 AM   #4
lectraplayer
Member
 
Registered: Mar 2003
Location: a little west of Birmingham, AL, USA.
Distribution: SuSE 10
Posts: 915

Original Poster
Rep: Reputation: 30
Found what i was trying to remember.

Quote:
Originally Posted by david_ross View Post
You should be able to boot with fedora cd1 and at the boot prompt enter "linux rescue".

Once booted run:
chroot /mnt/sysimage
/sbin/grub-install /dev/hda

This should put grub back on the mbr.
 
Old 01-21-2013, 10:22 AM   #5
suicidaleggroll
Senior Member
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 3,007

Rep: Reputation: 1051Reputation: 1051Reputation: 1051Reputation: 1051Reputation: 1051Reputation: 1051Reputation: 1051Reputation: 1051
Quote:
Originally Posted by lectraplayer View Post
Found what i was trying to remember.
That's basically the same thing that bigrigdriver said in his post. In rescue mode you need to do the chroot, or you can just use the install cd to boot into the full OS and skip the chroot part. The important command there is the grub-install, that's what's actually reinstalling grub on your MBR.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Sticky Bit? (ie: chmod 2770 vs chmod 770) JeffC1 Linux - Newbie 7 03-18-2010 07:39 AM
Apache: difference between chmod 644 and chmod 666 and chmod 600 for output/txt/dat? frenchn00b Programming 6 04-22-2009 01:10 PM
chmod 775 to only the directories and chmod 664 to only the files? apachenew Linux - Security 6 09-27-2007 03:26 PM
chmod, external usb, vfat - can't chmod a directory itsjustme Slackware 2 04-02-2006 04:23 PM
What can we do if we type chmod ugo-x /bin/chmod ?????? bunny123 Linux - Software 3 02-01-2005 08:53 PM


All times are GMT -5. The time now is 10:01 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration