LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 06-18-2012, 05:55 AM   #1
Ajit Gunge
Member
 
Registered: Jan 2008
Location: Pune
Distribution: RHEL,fedora
Posts: 253
Blog Entries: 1

Rep: Reputation: 21
Talking Edited .bashrc now cannot login as root


Hi All,
I had edited my .bashrc file using the blog http://www.cyberciti.biz/tips/bash-a...inux-unix.html.There is an alias vi=vim.Now when I am trying to edit any file it says vim command not found.Also to install vim when I run the command yum isntall -y vim it says

ajit is not into sudoers file.The incident will be reported.

Now I cannot edit by bashrc file.I cannot edit my sudoers file.Can someone tell me how can I edit my sudoers file.I cannot login as root.How do I get out of the situation.Please help.
 
Old 06-18-2012, 06:07 AM   #2
pan64
LQ Addict
 
Registered: Mar 2012
Location: Hungary
Distribution: debian/ubuntu/suse ...
Posts: 21,830

Rep: Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308Reputation: 7308
you need to remove that alias, or use vi with full path. execute yum as root, not as normal user.





_____________________________________
If someone helps you, or you approve of what's posted, click the "Add to Reputation" button, on the left of the post.
Happy with solution ... mark as SOLVED
(located in the "thread tools")
 
Old 06-18-2012, 07:13 AM   #3
Ajit Gunge
Member
 
Registered: Jan 2008
Location: Pune
Distribution: RHEL,fedora
Posts: 253

Original Poster
Blog Entries: 1

Rep: Reputation: 21
You can always unalias an alais using the command unalias command
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
bashrc and root fluxism Linux - Newbie 9 06-16-2009 09:11 AM
edited the wheel group file and i cant log in as root again in the terminal cheezy86 Linux - Newbie 6 05-16-2009 07:37 PM
'bashrc user login karanjeet Linux - Desktop 1 07-18-2008 10:34 AM
.login, .bashrc or .cshrc ??? tuananhbirm Linux - General 1 01-20-2005 09:44 AM
Graphical login not working? Edited inittab... streamalot Linux - General 6 02-22-2002 09:24 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 11:53 AM.

Main Menu
Advertisement
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
Open Source Consulting | Domain Registration