This is a discussion on usb disk insists on being readonly within the Linux Operating System forums, part of the Unix Operating Systems category; --> On Jul 5, 7:58 am, Roby <r...@no-address.net> wrote: > lalawawa wrote: > > On Jul 4, 6:05 pm, Roby ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| On Jul 5, 7:58 am, Roby <r...@no-address.net> wrote: > lalawawa wrote: > > On Jul 4, 6:05 pm, Roby <r...@no-address.net> wrote: > >> lalawawa wrote: > >> > Hi, I just bought a 400Mbyte usb disk. > > >> > My OS is Ubuntu version 5, I've recently done the updates to it. > > >> > My computer is a Sony VAIO PCV-RX270DS that I bought in 2001, with > >> > about 400Mbytes of disk and the usb port is USB 1 (that manual doesn't > >> > say which USB version because I think USB 2.0 wasn't out yet). The > >> > disk is connected through a hub. > > >> > The drive is a 400GB Simpletech drive. The specifications make it > >> > clear it's USB 1.1 compatible. All the online technical support > >> > assumes you're on Windows. > > >> > When I turn on the disk, it appears in the /media directory by the > >> > filename ' simpletech ' (not spaces before and after the name). The > >> > fstab entry that appears is > > >> > /dev/sda /media/usb0 auto rw,user,noauto 0 0 > > >> > If I cd to /media and do 'ls -ld \ simpletech\ ', I get > >> > dr-x------ 1 wulluw wulluw 4096 2007-02-20 10:25 simpletech > >> > if I go into that directory and do 'ls -la' I get > >> > total 8 > >> > dr-x------ 1 wulluw wulluw 4096 2007-02-20 10:25 . > >> > drwxr-xr-x 7 root root 4096 2007-07-04 14:20 .. > >> > dr-x------ 1 wulluw wulluw 0 2007-02-20 10:25 System Volume > >> > Information > >> > if I try 'touch a' it says > >> > touch: cannot touch `a': Read-only file system > >> > if I try 'sudo touch a' it still says > >> > touch: cannot touch `a': Read-only file system > >> > I cd back to /media > >> > $ chmod +w \ simpletech\ / > >> > chmod: changing permissions of ` simpletech /': Read-only file system > >> > $ sudo chmod +w \ simpletech\ / > >> > chmod: changing permissions of ` simpletech /': Read-only file system > > >> > Why is it saying the filesystem is readonly when /etc/fstab clearly > >> > says it's rw? What do I have to do to get the disk mounted rw? A > >> > 400GB readonly disk with nothing on it isn't very useful. > > >> > Any help would be appreciated. > > >> > Bill > > >> My guess: the drive is formatted ntfs and the "auto" in the fstab entry > >> is causing linux to load the ntfs driver (rather than ntfs-3g). The > >> drive will be painfully slow at usb 1.1. usb2 pci cards are cheap and > >> do a great job. > > > I would like to put in a USB 2.0 board, but I absolutely, positively > > don't want to make any hardware changes to my box until I'm able to > > back up. > > > In the past, I would back up on CD-ROM using K3B. Then suddenly, > > probably as a result of an upgrade, neither K3B nor the CD-ROM Creator > > software are able to find my CD burner. Here's my fstab: > > > $ cat /etc/fstab > > # /etc/fstab: static file system information. > > # > > # <file system> <mount point> <type> <options> <dump> <pass> > > proc /proc proc defaults 0 0 > > /dev/mapper/Ubuntu-root / ext3 > > defaults,errors=remount-ro 0 1 > > /dev/hda1 /boot ext3 defaults 0 2 > > /dev/mapper/Ubuntu-swap_1 none swap sw > > 0 0 > > /dev/hdc /media/cdrom0 udf,iso9660 user,noauto 0 0 > > /dev/hdd /media/cdrom1 udf,iso9660 user,noauto 0 0 > > /dev/fd0 /media/floppy0 auto rw,user,noauto 0 0 > > /dev/sda /media/usb0 auto rw,user,noauto 0 0 > > $ > > $ df > > Filesystem 1K-blocks Used Available Use% Mounted on > > /dev/mapper/Ubuntu-root > > 37079744 12680436 22515764 37% / > > tmpfs 193436 0 193436 0% /dev/shm > > tmpfs 193436 12588 180848 7% /lib/modules/ > > 2.6.12-10-386/volatile > > /dev/hda1 233335 19153 201734 9% /boot > > /dev/sda1 390708800 77912 390630888 1% /media/ > > simpletech > > $ > > but I don't think upgrading to a 2.0 port is going to change the > > permissions of the disk. I think all that would be accomplished by > > upgrading to USB 2.0 would be to change my slow 400GB readonly disk > > with nothing on it to a fast 400GB disk with nothing on it. > > First let's confirm that your external drive is formatted ntfs: > $ sudo fdisk -l /dev/sda > > Yes, it's ntfs. So try mounting it using the ntfs-3g driver: > $ ntfs-3g /dev/sda1 /media/usb0 > > If successful, you finally have write privilege. > > If not, you need to install that driver. I don't use Ubuntu > so don't know the details. Once installed, change fstab to: > /dev/sda1 /media/usb0 ntfs-3g rw,user,noauto 0 0 > Note that it's sda1, not sda. > > I agree that a recent backup promotes sanity. Doing it at > 12megabits/sec will provide time to clean the garage, etc. > It will make you appreciate usb2.0 later. You'll see. > > I reformatted my external drives to ext3. Better. > > Roby There is no ntfs-3g program available, and I went to the Synaptic Package Manager (where you go on Ubuntu to download new packages) and there was no such package available for download. |
| |||
| Note that according to fstab, the drive is /dev/sda. According to df and /etc/mtab, the drive is /dev/sda1. If I do umount /dev/sda1 it complains it's not in fstab. If I do umount /dev/sda, it complains it's not in mtab. I'm not sure how to deal with this if I am to format the disk. |
| |||
| lalawawa wrote: > On Jul 5, 7:58 am, Roby <r...@no-address.net> wrote: >> lalawawa wrote: >> > On Jul 4, 6:05 pm, Roby <r...@no-address.net> wrote: >> >> lalawawa wrote: >> >> > Hi, I just bought a 400Mbyte usb disk. >> >> >> > My OS is Ubuntu version 5, I've recently done the updates to it. >> >> >> > My computer is a Sony VAIO PCV-RX270DS that I bought in 2001, with >> >> > about 400Mbytes of disk and the usb port is USB 1 (that manual >> >> > doesn't >> >> > say which USB version because I think USB 2.0 wasn't out yet). The >> >> > disk is connected through a hub. >> >> >> > The drive is a 400GB Simpletech drive. The specifications make it >> >> > clear it's USB 1.1 compatible. All the online technical support >> >> > assumes you're on Windows. >> >> >> > When I turn on the disk, it appears in the /media directory by the >> >> > filename ' simpletech ' (not spaces before and after the name). The >> >> > fstab entry that appears is >> >> >> > /dev/sda /media/usb0 auto rw,user,noauto 0 0 >> >> >> > If I cd to /media and do 'ls -ld \ simpletech\ ', I get >> >> > dr-x------ 1 wulluw wulluw 4096 2007-02-20 10:25 simpletech >> >> > if I go into that directory and do 'ls -la' I get >> >> > total 8 >> >> > dr-x------ 1 wulluw wulluw 4096 2007-02-20 10:25 . >> >> > drwxr-xr-x 7 root root 4096 2007-07-04 14:20 .. >> >> > dr-x------ 1 wulluw wulluw 0 2007-02-20 10:25 System Volume >> >> > Information >> >> > if I try 'touch a' it says >> >> > touch: cannot touch `a': Read-only file system >> >> > if I try 'sudo touch a' it still says >> >> > touch: cannot touch `a': Read-only file system >> >> > I cd back to /media >> >> > $ chmod +w \ simpletech\ / >> >> > chmod: changing permissions of ` simpletech /': Read-only file >> >> > system $ sudo chmod +w \ simpletech\ / >> >> > chmod: changing permissions of ` simpletech /': Read-only file >> >> > system >> >> >> > Why is it saying the filesystem is readonly when /etc/fstab clearly >> >> > says it's rw? What do I have to do to get the disk mounted rw? A >> >> > 400GB readonly disk with nothing on it isn't very useful. >> >> >> > Any help would be appreciated. >> >> >> > Bill >> >> >> My guess: the drive is formatted ntfs and the "auto" in the fstab >> >> entry >> >> is causing linux to load the ntfs driver (rather than ntfs-3g). The >> >> drive will be painfully slow at usb 1.1. usb2 pci cards are cheap and >> >> do a great job. >> >> > I would like to put in a USB 2.0 board, but I absolutely, positively >> > don't want to make any hardware changes to my box until I'm able to >> > back up. >> >> > In the past, I would back up on CD-ROM using K3B. Then suddenly, >> > probably as a result of an upgrade, neither K3B nor the CD-ROM Creator >> > software are able to find my CD burner. Here's my fstab: >> >> > $ cat /etc/fstab >> > # /etc/fstab: static file system information. >> > # >> > # <file system> <mount point> <type> <options> <dump> <pass> >> > proc /proc proc defaults 0 0 >> > /dev/mapper/Ubuntu-root / ext3 >> > defaults,errors=remount-ro 0 1 >> > /dev/hda1 /boot ext3 defaults 0 2 >> > /dev/mapper/Ubuntu-swap_1 none swap sw >> > 0 0 >> > /dev/hdc /media/cdrom0 udf,iso9660 user,noauto 0 0 >> > /dev/hdd /media/cdrom1 udf,iso9660 user,noauto 0 0 >> > /dev/fd0 /media/floppy0 auto rw,user,noauto 0 0 >> > /dev/sda /media/usb0 auto rw,user,noauto 0 0 >> > $ >> > $ df >> > Filesystem 1K-blocks Used Available Use% Mounted on >> > /dev/mapper/Ubuntu-root >> > 37079744 12680436 22515764 37% / >> > tmpfs 193436 0 193436 0% /dev/shm >> > tmpfs 193436 12588 180848 7% /lib/modules/ >> > 2.6.12-10-386/volatile >> > /dev/hda1 233335 19153 201734 9% /boot >> > /dev/sda1 390708800 77912 390630888 1% /media/ >> > simpletech >> > $ >> > but I don't think upgrading to a 2.0 port is going to change the >> > permissions of the disk. I think all that would be accomplished by >> > upgrading to USB 2.0 would be to change my slow 400GB readonly disk >> > with nothing on it to a fast 400GB disk with nothing on it. >> >> First let's confirm that your external drive is formatted ntfs: >> $ sudo fdisk -l /dev/sda >> >> Yes, it's ntfs. So try mounting it using the ntfs-3g driver: >> $ ntfs-3g /dev/sda1 /media/usb0 >> >> If successful, you finally have write privilege. >> >> If not, you need to install that driver. I don't use Ubuntu >> so don't know the details. Once installed, change fstab to: >> /dev/sda1 /media/usb0 ntfs-3g rw,user,noauto 0 0 >> Note that it's sda1, not sda. >> >> I agree that a recent backup promotes sanity. Doing it at >> 12megabits/sec will provide time to clean the garage, etc. >> It will make you appreciate usb2.0 later. You'll see. >> >> I reformatted my external drives to ext3. Better. >> >> Roby > > There is no ntfs-3g program available, and I went to the Synaptic > Package Manager (where you go on Ubuntu to download new packages) and > there was no such package available for download. .... mebbe your /etc/apt/sources.list needs an additional repository. Google search for Ubuntu ntfs-3g returneth many matches, including: https://help.ubuntu.com/community/Mo...irdPartyNTFS3G I recall adding ntfs-3g to an XUbuntu install a while back, so it's available somewhere in UbuntuLand. |
| |||
| lalawawa wrote: > Note that according to fstab, the drive is /dev/sda. According to df > and /etc/mtab, the drive is /dev/sda1. > If I do umount /dev/sda1 it complains it's not in fstab. If I do > umount /dev/sda, it complains it's not in mtab. I'm not sure how to > deal with this if I am to format the disk. With the external disk not mounted, if you edit fstab to make the entry /dev/sda1, can't you $ mount /media/usb0 and then $ umount /media/usb0?? /dev/sda refers to the whole disk thingy, including the partition table that usually lives at the very front of the disk. /dev/sda1 refers to the first (and probably only) partition on that disk, located after the partition table. Methinks the fstab entry should be /dev/sda1 ... unless SimpleTech chose to treat the whole disk like a giant-giant floppy and so there's no partition table. I think that's unlikely; may not even be possible. |
| |||
| Roby wrote: > lalawawa wrote: > >> Note that according to fstab, the drive is /dev/sda. According to df >> and /etc/mtab, the drive is /dev/sda1. >> If I do umount /dev/sda1 it complains it's not in fstab. If I do >> umount /dev/sda, it complains it's not in mtab. I'm not sure how to >> deal with this if I am to format the disk. > > With the external disk not mounted, if you edit fstab to make the entry > /dev/sda1, can't you $ mount /media/usb0 and then $ umount /media/usb0?? > > /dev/sda refers to the whole disk thingy, including the partition table that > usually lives at the very front of the disk. > > /dev/sda1 refers to the first (and probably only) partition on that disk, > located after the partition table. > > Methinks the fstab entry should be /dev/sda1 ... unless SimpleTech chose > to treat the whole disk like a giant-giant floppy and so there's no > partition table. I think that's unlikely; may not even be possible. > > Correct. Mounting the WHOLE DISK is a buit of a recipe fior disaster. You partition the raw device (sda) to give miuntable partitions (sda1,sda2 etc.), then format the *partitions*with a file system. And mount those. The only operations ever carried out on the raw device would be a dd total transfer of everything (including partition info) and repartitioning. Raw disks are almost NEVER mounted. |
| |||
| On Fri, 06 Jul 2007 11:38:09 -0000, lalawawa <usenet@ccjj.info> wrote: > > > On Jul 5, 7:58 am, Roby <r...@no-address.net> wrote: >> lalawawa wrote: >> > On Jul 4, 6:05 pm, Roby <r...@no-address.net> wrote: >> >> lalawawa wrote: >> >> > Hi, I just bought a 400Mbyte usb disk. >> >> >> > My OS is Ubuntu version 5, I've recently done the updates to it. >> > > There is no ntfs-3g program available, and I went to the Synaptic > Package Manager (where you go on Ubuntu to download new packages) and > there was no such package available for download. > You are using an old unsupported version of Ubuntu. ntfs-3g is in the current version 7.04. -- If you can keep your head when all about you are losing theirs, then you clearly don't understand the situation. |
| |||
| OK guys, here's my plan. Formatting the device is not a very attractive option right now for two reasons: - I have two boxes, a windoze box as well as the Ubuntu box that I have been talking about. I am afraid that if I reformat, it will no longer be Windoze readable and I will no longer have the option of putting the drive on my windoze box and reading my backups from there. - as long as my usb port is 1.1, formatting a 400GB drive at 10MB / sec will take all day If it takes a few tries to get it right that will be a disaster. I only have < 1GB of data that needs backing up. I have a 1GB usb ram stick that works, I can do a backup to it in a couple minutes. So this gives me the option of doing risky changes to my machine. A few days ago, I ordered Ubuntu 7.0 from Amazon, it should show up any day now. Last night I went to Circuit City and they didn't have any USB 2.0 boards, so I just ordered one on the internet, it should show up in a few days. By backing up to my ram stick, I can make both those upgrades to my box. (I totally will not upgrade my OS without backing up first. I did a routine backup of SuSE about a year ago and it wound up screwing up my machine with complete loss of data. So I no longer am willing to upgrade my OS without backing up first). Then, since Bill Marcum told me I will have access to ntfs-3g, hopefully everything will work. If that doesn't solve the problem, I will then have the option of reformatting the drive at reasonably high speed. Bill |
| |||
| OK, everybody, here's how things turned out. This whole saga started when I found my cdrom burning software could no longer find my cdrom device. I figured some random update to Ubuntu had given me software that no longer understood my hardware, so I bought this new disk to do my backups on. Then I had all these problems with this disk, leading to this thread in usenet. There was a hassle getting my Ubuntu 7 dvd in the mail, and things got busy, so I finally went to upgrade my Ubuntu from version 5 to 7 last weekend. I discovered that my computer would not boot off the dvd. In fact, it could not access the dvd or cdrom at all. So the whole thing was a hardware problem. So then I contemplated getting an external usb cdrom/dvd drive, which could involve as many headaches as the simpletech usb disk drive did, and add a new board (which never showed up in the mail) to support USB 2.0 (since doing everything over the existing USB 1.1 would be pretty painful), all to keep my 6 1/2 year old, 866 MHz, 400 MB cpu going, or I could just go to the store and get a new computer. I chose the latter action. I got a Compaq Presario SR530SX, 1G Ram, 200G disk, Vista installed but no Vista recovery disk. I tested the hardware thoroughly before installing Ubuntu, since that action voided the store warranty. The Ubuntu dvd gave confusing directions when asking me how to partition the 200G disk. I thought I told it to put 80% of the disk in the Ubuntu partition and give the rest to the Vista partition, but it did the other way round. So I've only got 40G in the partition I actually use, but that will be enough. I plugged the new simpletech into my other computer, my Windoze box, and put a bunch of data on it, that went OK. I plugged the new device into my new Ubuntu box and had exactly the same problems I had on Ubuntu 5. Following Roby's advice, I got ntfs-3g installed. There was still a problem. The drive really, really wants to be mounted at '/media/ simpletech ' (note Unix-confounding spaces before and after 'simpletech'). If I put that name into /etc/fstab it doesn't know how to parse it. I tried putting '\' before the spaces in the fstab but that didn't help. I tried putting '/media/ simpletech ' in single quotes and it REALLY didn't like that. I did eventually manage to manually mount the thing in a newly created directory /media/st that I created, but it just won't cooperate with going there when I tell it to in the fstab. Also, every time I reboot, the usb drive comes up wth a different /dev directory name. Failing to find the pattern, I wrote scripts based on "fdisk -l | grep NTFS" and sed that get the name of the appropriate wandering /dev drive and mount/umount it. That will do. I anticipate accessing this disk at most once per month for backup. I really don't recommend the simpletech drive to Linux users. I guess a lot of these problems are inevitable for any NTFS drive, and I want a Windoze compatible file system. But I think life would have been a lot easier if they hadn't programmed it to mount itself in a directory with SPACES in the filename. It's the second simpletech drive I got. Both have worked fine with Windoze.The first, a 160G drive, has been good, but the second, 400G drive is noiser and hotter. You really have to mount it standing up so it can get rid of the excess heat, while the 160G model you can just lie down and put things on top of. One fortunate spinoff of all this hassle is I figured out how to use 'sudo ntfs-config' to mount my 160G Windoze partition from Linux, so I at least have easy access to all that disk. But the Ubuntu people would be well-advised to try to make their questions clearer when asking how you want your partitions set up. One bad thing about Linux is it gets very upset when you just yank the usb connection without umounting the drive. Windoze doesn't mind (well, AFAIK, Windoze has no way to umount the drive). Windoze Vista has been pretty underwhelming. When I was testing it out before installing Linux, one thing I did was mount both my usb drives on it and copy my 20G library of music mp3's from one to the other. At the same time I was playing some of the music from the source, not the destination, drive. When the copy got to the file I was playing, Vista died! Blue Screen of Death, no less. What an operating system - accessing the same file for read twice crashes it! After I installed Linux and was fooling around with ntfs-3g, I was getting messages from Linux about the new Simpletech drive being 'dirty' and recommending I boot Windoze a couple of times with the drive attached. I did this, and one of those times, Vista went into a mode where it said "Don't shut down or unplug your computer, installing ...". It didn't say *what* it was installing, *I* hadn't asked it to install *anything*, it gave no time estimate of how long this would take, it just sat there saying that. I went out for the day, returning 7 hours later to be greeted by the same screen. At that point I powered down the PC and was able to reboot Vista OK. |
| ||||
| lalawawa wrote: (snip) > I did eventually manage to manually mount the thing in a newly > created directory /media/st that I created, but it just won't > cooperate with going there when I tell it to in the fstab. Also, > every time I reboot, the usb drive comes up wth a different /dev > directory name. Failing to find the pattern, I wrote scripts based on > "fdisk -l | grep NTFS" and sed that get the name of the appropriate > wandering /dev drive and mount/umount it. That will do. I anticipate > accessing this disk at most once per month for backup. > Put a disk label on the usb drive and use it to identify the right device by putting something like this in /etc/fstab: /dev/disk/by-label/my_usb_disk /media/st ntfs-3g defaults 0 0 The label is case-sensitive. Methinks this was all just a ploy to get yourself Vista. Shame on you!! |