How to access files in Windows partition from Ubuntu live USB?

Solution 1:

You need to mount the partition that contains you files. Run this on Terminal:

sudo fdisk -l

It should be something like

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *        2048      206847      102400    7  HPFS/NTFS/exFAT
/dev/sda2          206848   209717247   104755200    7  HPFS/NTFS/exFAT

To locate which partition has your files, probably the one Windows 7 is installed in, then perform the following command:

sudo mount -t ntfs-3g /dev/sdaX /~/choose-a-folder-name-you-want

Where X is the number of the partition you want to mount, like /dev/sda1 or /dev/sda2.

It should mount the disk with full access, so you can copy and paste files to those folders. More about mount.

Remember, it will mount your whole Windows 7 partition to a folder, so be carefull not to delete anything important.

Solution 2:

Scenario B

A live boot with access to a Windows drive on a another machine.

Fast Solution

You'll need your live-boot user UID and GID

~ $ id

Create a local mount directory

~ $ mkdir ~/<mount-dir>

'mount' the windows drive.

~ $ sudo mount -t cifs -o user=<win-user-acct>,rw,uid=<uid-number>,gid=<gid-number> //<IP-of-Win-Machine>/C$ ~/<mount-dir>

Example

~ $ sudo mount -t cifs -o user=winUserName,rw,uid=999,gid=999 //192.168.1.77/C$ ~/winbox01

NOTE 'cifs-utils' should be installed by default, but to check,

~ $ sudo apt search cifs-utils

[ If not installed, use the following ]

sudo apt update && sudo install cifs-utils

Other Difficulties

The 'mount -o[ptions]' list must NOT contain white space.

The following options list will fail,

"-o user=winUserName[SPACE],rw,uid= ... "

Wired NIC Connection Issues

~ $ ip link OR ip address

With NIC device name,

~ $ sudo ip link set <NIC-dev-name> up

Wireless NIC Connection Issues

~ $ nmcli

[ to get device name of wireless NIC ]

~ $ nmcli d wifi list

[ to get SSID to connect to ]

~ $ nmcli d wifi connect <WiFiSSID> password <WiFiPassword> iface <WifiInterface>

[ to connect NIC to Wireless network ]

Misc

Certain punctuation within "<WiFiPassword>" must be escaped,

Yes: \!,\$,\&

No: @, #

To mount the Windows C$ share [ which is the entire drive ], your <win-User-Acct> will need to belong to the Windows machine's local 'Administrators' group. If not, you'll need to share a folder on the Windows machine and use "<IP-of-Win-Machine>/<share-name>" in the 'mount' command.