LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 11-22-2002, 05:47 PM   #1
Sudha Ravikumar
LQ Newbie
 
Registered: Nov 2002
Posts: 1

Rep: Reputation: 0
Question Files on Linux system


I have a requirement where a specific file could be on the Linux system. But my C++ Dll on Windows system should be able to read and write to this file. Is this possible? Can you give an example?

Thanks,
Sudha
 
Old 11-22-2002, 07:25 PM   #2
DavidPhillips
LQ Guru
 
Registered: Jun 2001
Location: South Alabama
Distribution: Fedora / RedHat / SuSE
Posts: 7,163

Rep: Reputation: 58
Is this a local disk or network that the file is to be accessed on?


If it's the local disk you should put the file on a filesystem that windows can use, fat32 would be the best. That way both windows and linux can use it.

You could also make a link to the file on your linux system in the place where the file is expected to be so you could put the file anywhere on the fat32 drive.

If the linux system only needs read access you could use ntfs.

If it's over a network you need to setup samba on the linux box and use network sharing.

Here is one way to do it, there are many ways...

Make a mounting folder...
mkdir /somefolder

Mount drive C: to the mounting folder...
mount -t vfat /dev/hda1 /somefolder

Move the file to the fat32 partition...
mv /locationof/myfile /somefolder/somewhere/myfile

Create a link to the file in it's original location...
ln -s /somefolder/somewhere/myfile /locationof/myfile


Update your /etc/fstab file to mount the partition on boot if required...

/dev/hda1 /somefolder vfat defaults 0 0



Last edited by DavidPhillips; 11-22-2002 at 07:27 PM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
opening linux file system files in windows 95?? timefortea General 6 08-26-2005 01:28 PM
Can i use JFS files system partitions to be any linux distro ? pleasehelpme Linux - General 1 05-13-2005 03:25 PM
Looking at Windows-files from a linux system HULLU Linux - General 3 12-19-2004 05:16 AM
Files system for Linux and Windows stefane321 Linux - Hardware 2 09-09-2004 01:41 PM
Cannot edit system files in Mandrake Linux... Tommi Linux - Newbie 7 08-14-2003 01:53 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 09:04 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration