LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 09-05-2003, 10:32 PM   #1
gazzy
LQ Newbie
 
Registered: Sep 2003
Posts: 1

Rep: Reputation: 0
Automatically resolving WINDOWS paths to pre-configured Linux paths


My problem needs AUTOMATIC resolution of WINDOWS paths (with drive letters et al) to pre-configured LINUX paths on RedHat 9.0 machines. Specifically, I have a third party application (running on both Windows and Linux platforms), which generates data files with embedded file paths corresponding to the particular OS file naming system. Consider the following example. Say, I create a data file using my application (lets call it X) on Windows XP. The contents of the data file will look as follows:

#Data file for application X
.......
.......
.......
.......
exec "C:\testdir\bin\abc.xyz"

Now, I need to process this same data file on a RedHat Linux 9.0 box. The problem is that Linux does not use drive letters, it is case sensitive and the slashes are also different. So, the embedded file path won't be resolved correctly by Linux. This is the crux of my problem.

So, what I am looking for is some Linux app ,which can be configured to maintain a table of Windows path mappings to their corresponding Linux counterparts. It would look something like this:

WINDOWS FILE PATH LINUX FILE PATH
C:\SAMPLE\example1.txt /tmp/example1.txt
D:\example2.txt /tmp/example2.txt

This app can then inform the OS of the configured drive mappings. SO, whenever the RH 9.0 OS encounters the Windows style file paths it looks up the table (might need a kernel mod for doing that) and resolves it to the correct Linux file path (provided it has been configured in the table).

Is there any such Linux app out there? I can solve my problem by writing scripts to read through the entire data file and perform the file path replacement wherever necessary. However, the problem is that the data files are huge (> 100 MB) and therefore the aforementioned solution becomes really expensive.

Any help in this regard will be highly appreciated.

Thanks & Regards,
Gautam.
 
Old 09-05-2003, 11:15 PM   #2
MasterC
LQ Guru
 
Registered: Mar 2002
Location: Salt Lake City, UT - USA
Distribution: Gentoo ; LFS ; Kubuntu ; CentOS ; Raspbian
Posts: 12,613

Rep: Reputation: 69
Moving to Linux - General This question really isn't RedHat specific, so you'll get more traffic/views in the Linux - General forum.

Welcome to LQ

Cool
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
different paths iomari Linux - General 1 11-10-2004 07:57 AM
Where are my paths? colly Linux - General 1 06-17-2004 08:15 AM
How do you set up links or paths in LINUX? Mandrake 9.2 Java VM Ygarl Linux - Newbie 4 03-29-2004 04:00 PM
linux equiv. of raw disks and device paths iggymac Linux - Newbie 0 11-20-2003 11:46 PM
Resolving file paths... ugenn Programming 3 10-01-2002 03:27 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

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

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