0

I was trying to install Spotify onto my ubuntu...and I don't know what I did wrong, but I do not have Spotify and all of my files have become read-only (everything in the file system has a padlock on it)!!! This means I cannot do anything in the terminal without getting the error that it cannot open anything because it’s a read-only file system...any suggestions?

Thanks for replying so fast! I tried to follow these instructions on terminal ..none of the stuff was working anyway

Debian

# 1. Add this line to your list of repositories by
#    editing your /etc/apt/sources.list
deb http://repository.spotify.com stable non-free

# 2. If you want to verify the downloaded packages,
#    you will need to add our public key
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 94558F59

# 3. Run apt-get update
sudo apt-get update

# 4. Install spotify!
sudo apt-get install spotify-client

Now I keep getting this error if I try and do an fsck:

permission denied while trying to open /dev/sda1 you must have r/w access to the file system or be root.

I think the error happened when it kept telling me dev is not recognised so I tried to install devscripts...:( ...which was what someone else suggested (if you're having trouble installing spotify)

My history is just the following

24  vi/etc/apt/sources.list
25  deb
26  debc (spotify link) stable non-free
27  sudo apt-get install devscripts
28  debc http://repository.spotify.com stable non-free
29  deb (spotify link) stable non-free
30  apt-get install debian-reference
31  yes
32  sudo apt-key adv--keyserver.ubuntu.com--recv-keys 4E9CFF4E
33  sudo add-apt-repository "deb (spotify link) stable non-fr
Melebius
  • 11,750
Hala
  • 11

2 Answers2

1

This can happen because there is a disk drive error. What you describe has happened several times to me. Your fstab will have an entry similar to this:

UUID=80e377f3-6e78-4126-aa93-35ee62b58272 / ext4 errors=remount-ro 0 1

This is an instruction to remount the drive read-only if there are errors. In my case this was caused by faulty sata connections to the motherboard. I reseated the sata connector and the problem went away.

But the problem kept coming back and I finally solved the problem for good, by buying new, high quality sata cables that had a spring locking clip in the connectors. YMMV :)

labnut
  • 239
0

Type ls -l in one of the padlocked directories to find out the permissions. You should be able to change them with chmod and chown (using sudo if not owned by your user) if they are wrong.

For example, if a file that should be writable says:

-r--r--r-- 1 user user  4160 Jul 18 15:44 file.ext

You can give yourself write permissions using chmod ug+w file.ext.

If a file that belongs to you says:

-rw-rw-r-- 1 root user  4160 Jul 18 15:44 file.ext

You can take control of it using sudo chown user file.ext.

Similarly chgrp to change the group (the second 'user' above) if that is wrong.

otus
  • 873