VectorLinux
September 02, 2014, 01:29:47 am *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: Visit our home page for VL info. To search the old message board go to http://vectorlinux.com/forum1. The first VL forum is temporarily offline until we can find a host for it. Thanks for your patience.
 
Now powered by KnowledgeDex.
   Home   Help Search Login Register  
Please support VectorLinux!
Pages: [1]
  Print  
Author Topic: In single user mode, everything is read only [solved]  (Read 1768 times)
finneces
Member
*
Posts: 4


« on: December 29, 2007, 02:40:44 am »

Hi everyone,

I have a partitioned drive with Ubuntu on one partition and Vector on the other.  I've liked Vector better (faster and many things seem to work better) but I seem to have forgotten my root password.  I thought I used the same one as on my Ubuntu installation, but apparently it doesn`t work.  So I logged on in single user mode (only works if I use the init=/bin/bash boot option) but then the entire system is read only so I can`t change the password.  Does anyone have an idea what could be wrong?

I usually can solve my problems with google, but this time I don't even know what to search for.

Thank you,

Matt
« Last Edit: December 29, 2007, 10:13:31 am by The Headacher » Logged
finneces
Member
*
Posts: 4


« Reply #1 on: December 29, 2007, 02:46:12 am »

Oh, by the way, when I was in single user mode I couldnt even make a new document.  I tried emacs t.t and it said the document was read only.  I tried typing "su -" (didnt require password) and then still the same thing.
Logged
The Headacher
Louder than you
Global Moderator
Vectorian
*****
Posts: 1545


I like the bass to go BOOM!


WWW
« Reply #2 on: December 29, 2007, 03:20:58 am »

Quote
I thought I used the same one as on my Ubuntu installation, but apparently it doesn`t work.  So I logged on in single user mode (only works if I use the init=/bin/bash boot option) but then the entire system is read only so I can`t change the password.  Does anyone have an idea what could be wrong?
Nothing is wrong, except of course that you can't log in as root. The rest of it seems exactly how Linux should work. Would be a little weird if every user could just change root's password wouldn't it? That's not exactly what I'd consider safe. As for write access: normal users can only write to their home directory and where root has allowed them to write.

Quote
Oh, by the way, when I was in single user mode I couldnt even make a new document.  I tried emacs t.t and it said the document was read only.  I tried typing "su -" (didnt require password) and then still the same thing.
I am unsure what this "single user mode" is... where did you find it? I can't recall such an option in VL. If "su -" doesn't require a password, haven't you just left it empty? "su -" sure requires a password here. 
Logged

Most music on my soundcloud page was arranged in programs running on VL.
jduped
Vectorite
***
Posts: 127


Don't Worry, Be Happy


« Reply #3 on: December 29, 2007, 03:27:41 am »

I don't believe you can do much with out a password.
my suggestion would be use your ubuntu partition, as you can login.
Access the vector partition/mount it.
If you have any important data, settings bring it over to your ubuntu partition, and reinstall vector.
If data isn't critical, then just do a reload.

Its really not the greatest suggestion, but when your locked out of the vault how else can you get in?
« Last Edit: December 29, 2007, 03:29:13 am by jduped » Logged

Ask Yourself

finneces
Member
*
Posts: 4


« Reply #4 on: December 29, 2007, 04:12:37 am »

Quote
I thought I used the same one as on my Ubuntu installation, but apparently it doesn`t work.  So I logged on in single user mode (only works if I use the init=/bin/bash boot option) but then the entire system is read only so I can`t change the password.  Does anyone have an idea what could be wrong?
Nothing is wrong, except of course that you can't log in as root. The rest of it seems exactly how Linux should work. Would be a little weird if every user could just change root's password wouldn't it? That's not exactly what I'd consider safe. As for write access: normal users can only write to their home directory and where root has allowed them to write.
I wasnt a normal user.  I was root.
Quote
Quote
Oh, by the way, when I was in single user mode I couldnt even make a new document.  I tried emacs t.t and it said the document was read only.  I tried typing "su -" (didnt require password) and then still the same thing.
I am unsure what this "single user mode" is... where did you find it? I can't recall such an option in VL. If "su -" doesn't require a password, haven't you just left it empty? "su -" sure requires a password here. 

You have a thousand posts but you dont know what single user mode is???  When you boot using grub, edit the command line to start the kernel and add the option "single" you may also need to add the option "init=/bin/bash".    Then when you boot you are root without a password.  Normally you do this only when you forget your root password.  But even as root I couldnt edit any files and couldnt change my own password.  It said "could not lock password file".  I tried loading Ubuntu and mounted the Vector partition and then coppied over my password file, but that didnt seem to work.  Perhaps reinstalling is the only way, though certainly not the coolest way.
« Last Edit: December 29, 2007, 04:29:30 am by finneces » Logged
nightflier
Administrator
Vectorian
*****
Posts: 4022



« Reply #5 on: December 29, 2007, 05:17:30 am »

You have a thousand posts but you dont know what single user mode is???
- Not a good way to motivate those who may help you -

GRUB is a relatively new option for VL. I am not familiar with it's custom commands, but understand that single user mode logs you straight in to the root account without the need for a password. Frankly, I think that is a huge security hole.

Is it possible you are actually logging on to Ubuntu doing it this way?
Logged
exeterdad
Packager
Vectorian
****
Posts: 2046



« Reply #6 on: December 29, 2007, 05:33:42 am »

While running Ubuntu, mount your partition that VL is on.
Edit VL's /etc/shadow file by finding the root entry:
Quote
root:$1$aB7mx0Licb$CTbs2RQrfPHkz5Vna0.fnz8H68tB.:10852:0:99999:7:::
It will look something like this.  Delete the text between the first set of colon's.  I marked it red for you.
Save the file and boot VL without a password.  Now set a new one ASAP.
Logged
finneces
Member
*
Posts: 4


« Reply #7 on: December 29, 2007, 05:58:29 am »

While running Ubuntu, mount your partition that VL is on.
Edit VL's /etc/shadow file by finding the root entry:
Quote
root:$1$aB7mx0Licb$CTbs2RQrfPHkz5Vna0.fnz8H68tB.:10852:0:99999:7:::
It will look something like this.  Delete the text between the first set of colon's.  I marked it red for you.
Save the file and boot VL without a password.  Now set a new one ASAP.

Excellent!  That did the trick!

Danke sehr!

Matt
Logged
jduped
Vectorite
***
Posts: 127


Don't Worry, Be Happy


« Reply #8 on: December 29, 2007, 08:25:08 am »

Man, good to know...thats going into the how to Smiley
Logged

Ask Yourself

exeterdad
Packager
Vectorian
****
Posts: 2046



« Reply #9 on: December 29, 2007, 08:29:23 am »

This can also be done with a "live" Linux disc if you don't have the luxury of another partition with a working Linux install.

Glad we were able to save your install without loosing data. Smiley
Logged
The Headacher
Louder than you
Global Moderator
Vectorian
*****
Posts: 1545


I like the bass to go BOOM!


WWW
« Reply #10 on: December 29, 2007, 10:05:41 am »

You have a thousand posts but you dont know what single user mode is???  When you boot using grub, edit the command line to start the kernel and add the option "single" you may also need to add the option "init=/bin/bash".    Then when you boot you are root without a password. 
I never use grub, I know lilo and stick with it because I sort of understand how to mess with it without having to read documentation. If you had read anything about the "single" command though, you'd have known you would enter a read-only environment  Kiss.

Quote
I usually can solve my problems with google, but this time I don't even know what to search for.
"grub single user" worked fine for me.

[edit]
Ps. I've marked this thread [solved] now, hope you don't mind
[/edit]
« Last Edit: December 30, 2007, 03:41:30 pm by The Headacher » Logged

Most music on my soundcloud page was arranged in programs running on VL.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2013, Simple Machines Valid XHTML 1.0! Valid CSS!