DIGIT-ARC read-only archive · snapshot: July 23, 2026

overwitten bashrc in centos

2 posts · originally from https://geek.digit.in/community/threads/overwitten-bashrc-in-centos.195509/

C
cubaperumal Original post #1
Nov 16, 2015 at 12:12 AM
Dear friends :),
I am using centOs version 6.5. I was editing bashrc using vi editor to setup path for a program,
my capslock was on when I was giving quit command to vi editor. I dont know what mistake I have done.
When I boot Centos (gui). There is problem in booting. Is there anyway that I could retrieve the default bashrc by logging in
as root without formatting or reinstalling OS. please help me in this regard
ratul
ratul #2
Nov 16, 2015 at 11:10 PM
Dear friends :),
I am using centOs version 6.5. I was editing bashrc using vi editor to setup path for a program,
my capslock was on when I was giving quit command to vi editor. I dont know what mistake I have done.
When I boot Centos (gui). There is problem in booting. Is there anyway that I could retrieve the default bashrc by logging in
as root without formatting or reinstalling OS. please help me in this regard

i think /etc/skel stores the default files needed for any home directory, just copy the bashrc from there.
Code:
cp /etc/skel/.bashrc ~