LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Accessing files on the Windows Partition from Linux (https://www.linuxquestions.org/questions/linux-software-2/accessing-files-on-the-windows-partition-from-linux-160343/)

sci0x 03-20-2004 05:25 PM

Accessing files on the Windows Partition from Linux
 
I would like to access the music on my Windows Partition to play on Linux. I know there is a way this can be done I would just like to know how. Is there some software out there that can do it?

Kovacs 03-20-2004 05:46 PM

You need to have support for whatever windows filesystem you want to access (fat32, ntfs) compiled into your kernel or as a module. Then you can add an entry for your windows partition to /etc/fstab, mount it and read files as normal (you can't really write to ntfs though afaik).

man mount
man fstab

sci0x 03-20-2004 06:00 PM

Any chance you could explain that again, to a person who has just started using Linux yesterday?

Thanks :D

Kovacs 03-20-2004 06:28 PM

Ok... the kernel thing is tricky, although it is not that difficult to compile a new one. Most stock kernels that I know of probably have fat32 read support though. What distro and kernel are you using (check with uname -r at the command line), and what format is your windows partition (fat32 or ntfs)?

Assuming that you have read support for that partition type in your kernel, do this as root:

1) Add a line similar to this to your /etc/fstab:
Code:

/dev/hda1        /mnt/windows    ntfs        noauto,users,ro,umask=0222    0  0
Where the first part points to the name of your windows partition, the second points to the directory you are going to make in the next step, the third is the file system type of your win partition.

2) Make a new directory /mnt/windows
Code:

mkdir /mnt/windows
chmod 755 /mnt/windows

My memory is a little hazy on this, you might have to do that in the opposite order. :D

Hopefully after this you should be able to use the command:
mount /mnt/windows
to mount your windows partition and then be able to navigate and use files in it as you would normally. Note that you won't be able to change them unless you alter the umask setting in /etc/fstab. If you get any errors post them here with specific error messages.

sci0x 03-20-2004 06:53 PM

When i open etc/fstab i cant edit it. How do i log in as root to edit it?

Thanks for helping me btw

urzumph 03-20-2004 07:15 PM

it's better not to log into the GUI as root (safer)

To log in as root :
CTRL-ALT-F2
and log in

To have access to root permissions from within GUI :
Open a terminal.
type su and hit enter
enter your password.

Once you've done that, edit your fstab with whatever editor you have installed, (I recommend nano for new linux users) and save.

sci0x 03-21-2004 02:34 PM

ok i open the terminal, type su, log in and it says im logged in. But when i open /etc/fstab i still dont have permission to edit it?


All times are GMT -5. The time now is 06:45 AM.