-1

I can't uninstall ATI catalyst driver or due to some other issue i am getting blank screen in Ubuntu 12.04 . I am able to access terminal and data in recovery mode. So how can i move the data from my /var/www to some other drives so that i can access it in my windows.

Please help me out, i have a lot of data i have been working upon for last six months

1
  • Boot from a live session and copy your data to the windows partition directly from www.
    – Parto
    Jul 12, 2014 at 19:19

1 Answer 1

1

First you need to mount the other device where you want to move the data. This can be done by using the following commands:

sudo mkdir /media/newdrive

After making a "newdrive" folder in /media/

you can mount your drive by:

sudo mount /dev/sdb1 /media/newdrive

(/dev/sdb1 is the drive you want to mount and newdrive is the newly created folder)

After the drive has been mounted, move the directory by using these commands:

sudo mv /path/to/source /path/to/dest

In your case it will be something like:

sudo mv /var/www /media/newdrive

Remember to mount the drive to newdrive first. And if it is already mounted skip the first two steps.

3
  • i know about /dev/sdb1 that it is internal hard drive but i have no idea about /media ... Can you please explain it what is media , is it external pen drive
    – terminator
    Jul 12, 2014 at 18:47
  • /media is any directory on your hard dist. "/media/newdrive" is only a logical mount-point for your actual physical drive. So, in fact, you could choose to mount the sdb at any location of your choice which is not used. (P.s.: /media is often chosen as ubuntu or any linux does not put any of its own file in it, hence it is always guaranteed to be empty, unless you put something there.)
    – Ashish
    Jul 12, 2014 at 19:23
  • Must mention that it's a good idea to mount the volume at boot by making an entry in fstab. I'd have recommended a slightly different approach though - sudo cp -pdR /var/www ~/www then sudo rm -rf /var/www then sudo mkdir /var/www then sudo mount /dev/sdb1 /var/www then make entry in fstab and finally sudo cp -pdR ~/www /var/.. Check permissions/ownership/disk-usage with sudo ls -al /var/www and df -h. Cheers!
    – Fr0zenFyr
    Apr 7, 2016 at 13:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .