I have done side by side install of Windows 7 and Ubuntu 10.0.4. I have setup a third partition for all my files I will switch between (i.e documents, music, and video's). How do I setup the third hard drive so that I can open in it the terminal so compile programs using the g++ and emacs. So my files stay updated if decide to open it in windows 7.

Hope this makes sense.

Dani AI

Generated

Short answer: mount the shared partition in Ubuntu with a Windows-friendly filesystem (NTFS or exFAT) and give your Linux user ownership and the exec flag so you can open a terminal there, edit with Emacs and run g++. That will keep files readable from Windows; however, for reliability and correct Unix permissions it is often better to keep sources on ext4 and sync them to Windows (Git, Samba, rsync) rather than doing heavy builds directly on NTFS.

Practical steps (conceptual — apply to your install): find the partition UUID, create a mount point (for example /mnt/shared) and add a persistent /etc/fstab entry that uses ntfs-3g and sets ownership and exec. Example fstab line (replace the UUID and uid/gid with your values):

UUID=XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX /mnt/shared ntfs-3g defaults,uid=1000,gid=1000,umask=0022,exec 0 0

After that sudo mount -a will mount it; from a file manager you can then "Open in Terminal" at that folder (install the file-manager terminal extension if your UI lacks it).

Practical cautions and tips: NTFS does not preserve Unix permissions and can make some build tools behave oddly; compiled Linux binaries are ELF and will not run on Windows (use MinGW or build on Windows for .exe). If Windows hibernation or fast-boot left the volume flagged, Linux will refuse write-mounts — always shut down Windows fully before mounting read/write. As and suggested, mounting is the first step; the fstab/UUID approach makes it robust. If Ubuntu was installed inside Windows (Wubi), the Windows filesystem may already be visible and some mounts won’t be necessary.

Recommended Answers

All 3 Replies

perfect sense. You can mount a windows drive in Ubuntu and use it for storage.... Some settings change depending on the filesystem, but pretty straight forward.

HAve a look at this:

I have done side by side install of Windows 7 and Ubuntu 10.0.4. I have setup a third partition for all my files I will switch between (i.e documents, music, and video's). How do I setup the third hard drive so that I can open in it the terminal so compile programs using the g++ and emacs. So my files stay updated if decide to open it in windows 7.

Hope this makes sense.

Hi.,

Let me say, u have three partitions in windows, C,D,E.

If u have installed ubuntu using option "Install inside windows", and used, "C" drive or ur Operating system drive for windows for ubuntu, then u can find all the files on the drive in the location : "/host/"

Specifically if u wanna use files stored in ur personal folder in windows, go to : "/host/users/USERNAME/"...


Or else, if u have installed ubuntu in an other drive, say "D" or "E", u can access all the files as mentioned...

Mount ur drive from "Places".u can access them easily

or go to computer in "places" and u will have access to all ur drive partitions. Hope u got it...

then u can change the path in ur terminal and use g++ or whatever u wanna do and files get updated so that u can use them when u go to windows..

With regards
vinaychalluru

Mount all drives in Linux share file with windows :
Open terminal type fdisk -l use this command see all windows partition's ,Which one you want to mount select this.

Like this
mount /sda/hdc1 /media

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.