Ubuntu help - changing external HDD permissions

LucianH
LucianH Posts: 445 Forumite
Part of the Furniture 100 Posts Name Dropper Photogenic
I'm a set-in-my-ways windows user (currently XP) and this is my first attempt at using Ubuntu and I'm struggling,

The reason for using Ubuntu is to copy data from one external HDD to another. The source HDD in question has been used to store PVR TV programs using a Samsung SMART TV and I've got a new HDD but I want to copy recorded programs from the old to new. Windows XP refuses to see the files but Ubuntu does (at least I've got as far as being able to see the files!).

I'm using Ubuntu 12.04 but have not installed it, I'm running it in "try" mode from the CD.

The trouble is that I do not have permissions to write to the HDD's. I've set up a user account as admininistrator but when I do a right-click/properties from the drive (in the Home folder) then the drop downs on the permissions tab are greyed out and it tells me that I am not the owner.

I've spent ages trawling the web and all references to changing permissions seem to use the terminal with command line such as this page. The solution the guy found started with installing pysdm:

"1 install physical storage device manger:sudo apt-get install pysdm"

When I try this in the terminal I get "E: Unable to locate package pysdm"

I also see loads of reference on different googled pages to the root and drive mount points, the thought of which scares the bejesus outta me.:eek:

The first question is, before I try anything else, is it possible to do what I'm trying to do by running Ubunto from CD in "try" mode or does this automatically lock all drives in read-only mode? If that's the case then is it easy to install Ubunto along side my ageing windows XP (does it sort out partitioning and dual boot stuff automatically (I've never dual-booted before apart from putting the wellies on for the snow!)?

So any help would be extremely welcome:beer:
Never let it get you down... unless it really is as bad as it seems.
«1

Comments

  • flexrider
    flexrider Posts: 745 Forumite
    edited 4 May 2012 at 1:34PM
    LucianH wrote: »
    I'm a set-in-my-ways windows user (currently XP) and this is my first attempt at using Ubuntu and I'm struggling,

    The reason for using Ubuntu is to copy data from one external HDD to another. The source HDD in question has been used to store PVR TV programs using a Samsung SMART TV and I've got a new HDD but I want to copy recorded programs from the old to new. Windows XP refuses to see the files but Ubuntu does (at least I've got as far as being able to see the files!).

    I'm using Ubuntu 12.04 but have not installed it, I'm running it in "try" mode from the CD.

    The trouble is that I do not have permissions to write to the HDD's. I've set up a user account as admininistrator but when I do a right-click/properties from the drive (in the Home folder) then the drop downs on the permissions tab are greyed out and it tells me that I am not the owner.

    I've spent ages trawling the web and all references to changing permissions seem to use the terminal with command line such as this page. The solution the guy found started with installing pysdm:

    "1 install physical storage device manger:sudo apt-get install pysdm"

    When I try this in the terminal I get "E: Unable to locate package pysdm"

    I also see loads of reference on different googled pages to the root and drive mount points, the thought of which scares the bejesus outta me.:eek:

    The first question is, before I try anything else, is it possible to do what I'm trying to do by running Ubunto from CD in "try" mode or does this automatically lock all drives in read-only mode? If that's the case then is it easy to install Ubunto along side my ageing windows XP (does it sort out partitioning and dual boot stuff automatically (I've never dual-booted before apart from putting the wellies on for the snow!)?

    So any help would be extremely welcome:beer:

    Hmm The best advise is to download and install ubuntu on a Usb Memory stick. That way when you put the stick into your computer it will *hopefully* ask u which o/s you want to simply go bk to windows you have to close ubuntu...i would use ubuntu in graphic mode also like windows desktop and not in coding, and for learning i suggest this book http://www.amazon.co.uk/s/ref=nb_sb_noss?url=search-alias%3Daps&field-keywords=learn+ubuntu+&x=0&y=0 (amazon)

    Ubuntu is lunix and will crash on same partition as windows so best to do it off the usb stick methoid and save the hassle of Hdd TomFoolerly

    edit: as for root Root is like windows adminstrator accounts,Mount is simply the way to access drives, I think you better buy the book Lunix is a great O/s But very different from windows, you need to know commands and your way round the o/s and windows is very click start>click tools kinda way....lunix is more grub/dev/ and for a newbie can get confusing
    "MSE Money saving challenges..8/12/13 3,500 saved so far :j" p.s if i been helpfully please leave me a thank you but seek official advice at all times from a pro
  • Mondez
    Mondez Posts: 146 Forumite
    It sounds like the drives are mounted read only rather than it being a permissions problem. Open terminal, type "mount" without the quotes and press enter and then post what the output is. Apparently the Samsung uses XFS as the format for its drive, what did you use to set up the new drive, windows?
  • LucianH
    LucianH Posts: 445 Forumite
    Part of the Furniture 100 Posts Name Dropper Photogenic
    Mondez wrote: »
    It sounds like the drives are mounted read only rather than it being a permissions problem. Open terminal, type "mount" without the quotes and press enter and then post what the output is. Apparently the Samsung uses XFS as the format for its drive, what did you use to set up the new drive, windows?

    The new drive has been formated using the Samsung TV so it's also XFS.

    The following is the mount result without either of the drives connected:

    /cow on / type overlayfs (rw)
    proc on /proc type proc (rw,noexec,nosuid,nodev)
    sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
    udev on /dev type devtmpfs (rw,mode=0755)
    devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
    tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
    /dev/sr0 on /cdrom type iso9660 (ro,noatime)
    /dev/loop0 on /rofs type squashfs (ro,noatime)
    none on /sys/fs/fuse/connections type fusectl (rw)
    none on /sys/kernel/debug type debugfs (rw)
    none on /sys/kernel/security type securityfs (rw)
    tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
    none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
    none on /run/shm type tmpfs (rw,nosuid,nodev)
    gvfs-fuse-daemon on /home/lucianh/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=lucianh)

    and the following is after I've connected one of the drives:

    /cow on / type overlayfs (rw)
    proc on /proc type proc (rw,noexec,nosuid,nodev)
    sysfs on /sys type sysfs (rw,noexec,nosuid,nodev)
    udev on /dev type devtmpfs (rw,mode=0755)
    devpts on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
    tmpfs on /run type tmpfs (rw,noexec,nosuid,size=10%,mode=0755)
    /dev/sr0 on /cdrom type iso9660 (ro,noatime)
    /dev/loop0 on /rofs type squashfs (ro,noatime)
    none on /sys/fs/fuse/connections type fusectl (rw)
    none on /sys/kernel/debug type debugfs (rw)
    none on /sys/kernel/security type securityfs (rw)
    tmpfs on /tmp type tmpfs (rw,nosuid,nodev)
    none on /run/lock type tmpfs (rw,noexec,nosuid,nodev,size=5242880)
    none on /run/shm type tmpfs (rw,nosuid,nodev)
    gvfs-fuse-daemon on /home/lucianh/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=lucianh)
    /dev/sde1 on /media/d9d2903c-9011-44e8-b41b-c065e22b5561 type xfs (rw,nosuid,nodev,uhelper=udisks)

    Additional line at the end
    Never let it get you down... unless it really is as bad as it seems.
  • fwor
    fwor Posts: 6,858 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    To answer the last question first - if you choose to install then Ubuntu is very well-behaved. It will deal with the partitioning and dual-boot config itself unless you choose something other than the defaults.

    However, it would be a lot easier to stick with the LiveCD and work at the command line. Psydm may be more than you need, as it looks like the drive is auto-mounted r/w Ok anyway.

    It may just be that Ubuntu is honouring the permissions that the Samsung box has set (i.e. it is the owner of the files, not you).
  • LucianH
    LucianH Posts: 445 Forumite
    Part of the Furniture 100 Posts Name Dropper Photogenic
    OK, now getting fed up with the speed of running CD Live. Have been trying to install Config Editor (probably won't help but it looks fun to play with) but it keeps locking up. Takes ages to reboot and you loose any configs (wasted most of today on it!).:(

    Currently ghosting my C Drive ready to install ubuntu for real and then I'll have another go to get permissions of the HDD changed.

    No doubt I'll be back with more questions once I'm up and running. And thanks to those that have posted already and if anybody else can throw more insight onto solving the problem please feel free to add to the list !!!
    :beer:
    Never let it get you down... unless it really is as bad as it seems.
  • fwor
    fwor Posts: 6,858 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    I don't think you need to be thinking of changing the permissions of the files on the source HDD. If you do, you're only going to have to change them back after you've copied them or the Samsung (probably) won't like them.

    If you can get both HDD's connected at the same time then you should be able to do what you want via the LiveCD and a single command line instruction:

    sudo cp -p /media/<source HDD UUID>/*.* /media/<dest HDD UUID>/

    The -p switch preserves the permissions, so that they will be as the TV likes them (and not root:root, which it won't like!).

    The UUID is just the long hex number with hyphens in from your last mount example. You don't even need to type that long string in - you can copy and paste from the mount output within the Linux terminal.
  • LucianH
    LucianH Posts: 445 Forumite
    Part of the Furniture 100 Posts Name Dropper Photogenic
    fwor wrote: »
    I don't think you need to be thinking of changing the permissions of the files on the source HDD. If you do, you're only going to have to change them back after you've copied them or the Samsung (probably) won't like them.

    If you can get both HDD's connected at the same time then you should be able to do what you want via the LiveCD and a single command line instruction:

    sudo cp -p /media/<source HDD UUID>/*.* /media/<dest HDD UUID>/

    The -p switch preserves the permissions, so that they will be as the TV likes them (and not root:root, which it won't like!).

    The UUID is just the long hex number with hyphens in from your last mount example. You don't even need to type that long string in - you can copy and paste from the mount output within the Linux terminal.
    Thanks, that sounds like the way to do it. I haven't got 'round to installing Ubunto yet - just finished ghosting the drive and I was about to re-partition it ready for an install. Watch this space and I'll report back.
    Never let it get you down... unless it really is as bad as it seems.
  • LucianH
    LucianH Posts: 445 Forumite
    Part of the Furniture 100 Posts Name Dropper Photogenic
    edited 4 May 2012 at 7:43PM
    Doh - Nothing happened! I've plugged in both HDDs and have got their UUIDs. I then typed this into the terminal:

    sudo cp -p /media/fc075f90-6bce-4d2e-813f-9488a8bffc45/*.* /media/d012c65f-3309-40b7-80e4-e57e1bc2eb04/

    And nothing happend. I did it after immediately firing up the Live CD (when you get the ubuntu prompt in the terminal - no error messages were given but also nothing else happened. I then set up an adminstrator account (seemed like a good idea) and tried again - the only difference this time is that it asked for the admin password:

    lucianh@ubuntu:~$ sudo cp -p /media/fc075f90-6bce-4d2e-813f-9488a8bffc45/*.* /media/d012c65f-3309-40b7-80e4-e57e1bc2eb04/
    [sudo] password for lucianh:
    lucianh@ubuntu:~$

    Again, straight to the prompt and no error messages. And the files ain't copying.

    This seemed such a simple idea at the time and I have a lot of respect for ubuntu but this is driving me crazy. Why can't I simply copy files from one HDD to another without worrying about any permissions? I can't do anything via the GUI (I can right click copy but the paste is greyed out when I try and paste to the destination HDD).

    I can understand that changing the permissions could screw up the TV trying to access the drive, given the apparent really strong control. What I can't understand is why you can't "login" to ubuntu with super user status to override these controls - I would have thought the adminstrator role would allow you to do this.

    After spending nearly the whole day on this, it's now running into the evenning and it's driving me :mad:

    Time to calm down, have a break and someting to eat (and a beer!).


    Edit: Just while I was shoving my steak pie in the oven, I had a thought related to the question I raised in the original post - Is there any restrictions on permissions when using Live CD as opposed to a full installation?
    Never let it get you down... unless it really is as bad as it seems.
  • fwor
    fwor Posts: 6,858 Forumite
    Part of the Furniture 1,000 Posts Name Dropper
    That's odd. I suppose you definitely got them round the right way? Nothing would happen if you didn't!

    Provided that you've checked using the mount command that both are mounted r/w, is it possible that the TV might have created some empty folders on the destination HDD, ready for new recordings to go into, which the cp command cannot overwrite without using another switch? Even so, you'd expect error messages...

    In reply to your edit: Yes, the LiveCD user is just another ordinary user, so logged in as that you still can't do anything with files owned by other users unless their permissions say you can.

    If you right-click on a file on the source HDD and look at Permissions, who does it say the owner is?

    There are a couple of ways to address this - either using CHOWN to change ownership, or CHMOD to change permissions.

    Incidentally, though this all seems a pain, it's one of the main reasons why malware writers find it difficult to target Linux...
  • LucianH
    LucianH Posts: 445 Forumite
    Part of the Furniture 100 Posts Name Dropper Photogenic
    That's better - a nice Steak and Ale Pukka Pie (and a couple of cans of Old Speckled Hen) does wonders for the inshpirashion - and, of course, your previous post fwor:
    fwor wrote: »
    is it possible that the TV might have created some empty folders on the destination HDD, ready for new recordings to go into, which the cp command cannot overwrite without using another switch?

    Yes the TV did created a file structure for the recordings as well as a few database info files. This means that the copy file command needs to overwrite these files as well as coping the new program video files into the folders that the TV's created. Why it didn't flag up errors I don't know but what I've done is to copy using the -f (and -i for safety?) switches (good old google!). I then repeated it for each of the folders in the file structure (and at this point, I realise that the Old Speckled Hen was not such a good idea - I suppose if I had used the -r switch it would have copied all the files! - luckily there were only two folders!). So in the end the following commands did the trick:

    sudo cp -p -i -f /media/fc075f90-6bce-4d2e-813f-9488a8bffc45/*.* /media/d012c65f-3309-40b7-80e4-e57e1bc2eb04/
    sudo cp -p -i -f /media/fc075f90-6bce-4d2e-813f-9488a8bffc45/database/*.* /media/d012c65f-3309-40b7-80e4-e57e1bc2eb04/database/
    sudo cp -p -i -f /media/fc075f90-6bce-4d2e-813f-9488a8bffc45/CONTENTS/*.* /media/d012c65f-3309-40b7-80e4-e57e1bc2eb04/CONTENTS/ - - - (and I've learnt that Linux is case sensitve!)

    Although.. there were two files it did not copy which I then did individually. I was also disconcerted when I did a "sumcheck" by doing a properties on the source and destination drives, the number of files was the same but the total size was different. A bit of tracking down showed that one of the video files (.srf file) ended up as a different size on the source drive - so I recopied it. Now I can't rule out a HDD fault (I'm changing the drive because the TV used to sometimes stop recognising the old drive) so I'm not sure whether I should worry but I don't know why no errors were flag up.

    I've just tried the new HDD with the copied files on the TV and it appears to work.:T

    I still think it's a shame that you have to resort to command line and not be able to use the GUI. However, after a whole frustrating day on this, there is a positve side, I still think I'm going to install Linux and have a play with it - it looks interesting.

    And thanks again fwor :beer:
    Never let it get you down... unless it really is as bad as it seems.
This discussion has been closed.
Meet your Ambassadors

🚀 Getting Started

Hi new member!

Our Getting Started Guide will help you get the most out of the Forum

Categories

  • All Categories
  • 349.9K Banking & Borrowing
  • 252.6K Reduce Debt & Boost Income
  • 453K Spending & Discounts
  • 242.8K Work, Benefits & Business
  • 619.7K Mortgages, Homes & Bills
  • 176.4K Life & Family
  • 255.8K Travel & Transport
  • 1.5M Hobbies & Leisure
  • 16.1K Discuss & Feedback
  • 15.1K Coronavirus Support Boards

Is this how you want to be seen?

We see you are using a default avatar. It takes only a few seconds to pick a picture.