Jump to content

"Segmetation fault" after modifing .bashrc as a rootuser

:(  I think i've broke my debian bad, wasn't following instruction closely... need to learn how to read again. I was trying to get color-coding to work in my terminal (different colors for directories, files, exec and such) and modified .bashrc files by adding something, i already forgot what to it, i think it was

source ~/.bashrc

everything else was commented out. Now I can't use sudo -s command, after punching in password it give me: Segmentation fault and kicks me back to regular user $. I've tried to open .bashrc with nano and vim, but both show nothing, nano says "Directory '.' is not writable" so i can't even show what i've done.  Is there any cure for that

Link to comment
Share on other sites

Link to post
Share on other sites

What does the terminal say when you run " whoami " ?

 

Did you happen to add something like

 

if [ -f ~/.bashrc ]; then
	source ~/.bashrc
fi

To the top of the bashrc file?

Intel i7 5820K (4.5 GHz) | MSI X99A MPower | 32 GB Kingston HyperX Fury 2666MHz | Asus RoG STRIX GTX 1080ti OC | Samsung 951 m.2 nVME 512GB | Crucial MX200 1000GB | Western Digital Caviar Black 2000GB | Noctua NH-D15 | Fractal Define R5 | Seasonic 860 Platinum | Logitech G910 | Sennheiser 599 | Blue Yeti | Logitech G502

 

Nikon D500 | Nikon 300mm f/4 PF  | Nikon 200-500 f/5.6 | Nikon 50mm f/1.8 | Tamron 70-210 f/4 VCII | Sigma 10-20 f/3.5 | Nikon 17-55 f/2.8 | Tamron 90mm F2.8 SP Di VC USD Macro | Neewer 750II

Link to comment
Share on other sites

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×