filesystems

How to implement 'open file location' behaviour programmatically (c++ builder)

In Windows Media Player you can right click on a music file and click 'open file location' and it opens an explorer window with the file selected. I want to be able to do this in applications. So given a filename (as an ansi string) I want to be able to go to the file in a new explorer window. ...

How can I recursively copy a directory into another and replace only the files that have not changed?

Hi all, I am looking to do a specific copy in Fedora. I have two folders: 'webroot': holding ALL web files/images etc 'export': folder containing thousands of PHP, CSS, JS documents that are exported from my SVN repo. The export directory contains many of the same files/folders that the root does, however the root contains additio...

Directory structure for a file host

I've got a simple file host going that gives files a unique id and just stores them in a directory. I've been told that this will cause problems in the future, and I'm wondering what things I should look out for to make sure it works smoothly into the future and beyond. Also, is there a performance issue with forcing downloads by sendin...

Is there a better way to store this database?

What i would like to do is scan a disc or a drive (usb, main hdd, etc) for files and store its info in a db. Then i would search the db to a particular file to find where it is stored. Alternatively i cans search how old copys are for archiving reasons or if i have dupes of something and dont need to rearchive it or look for a dupe in th...

XSLT: How to get file names from a certain directory?

Is there a function in XSLT that can takes in a directory path and gives back all the files in it?? I have a xml file now reads like this <filelist> <file>fileA.xml</file> <file>fileB.xml</file> </filelist> Now, there's directory called dir, has files fileX.xml, fileY.xml and a bunch of other xml files in it. I want to add th...

How can locked files be monitored on a WIN 2000 server

Hi, I'm interested to know what would be the best way to monitor locked files/open file handles on a win 2000 server. I am interested in a general system report that could show locked files or handles over time (over the course of one night, for example) without having to specify which processes are to be monitored specifically. Thanks...

How to get path to Desktop for current user in C# ?

This should be a no brainer, but somehow I can't persuade Google to give me a decent answer. The only think I could find is the VB-only class SpecialDirectories, which has this property: My.Computer.FileSystem.SpecialDirectories.Desktop How can i do this in C# ? ...

What can du see that rsync can't?

I want to copy an entire linux server that is going to be decommissioned over the network so we are sure nothing is lost. I did du / and was told there are 60 GB of under / Then I did rsync -r / root@newserver:/old-server and when doing du in the old-server dir I got 22 GB. So why is that difference? Is there something that du can see...

How can I get the files stored in host machine?

Hi,I installed a Linux systems on a VMWare which is a guest of Windows XP operating systems. How can I get files stored in XP file systems directly when working in Linux environment? Thanks. ...

How to dectect new or modified files in Mac OSX

In Windows OS, MS provides ReadDirectoryChangesW and FindFirstChangeNotification API to dectect new or modified file, does the Mac OSX provide equal function as well? ...

Directory checksum with python?

So I'm in the middle of web-based filesystem abstraction layer development. Just like file browser, except it has some extra features like freaky permissions etc. I would like users to be notified somehow about directory changes. So, i.e. when someone uploads a new file via FTP, certain users should get a proper message. It is not re...

What are all the illegal characters in the XFS filesystem?

Could someone provide (or point me to a list) of all the illegal characters in the XFS filesystem? I'm writing an app that needs to sanitize filenames. EDIT: Okay, so POSIX filesystems should allow all characters except the NUL character, forward slash, and the '.' and '..' filenames are reserved. All other exceptions are application-l...

An example project for network-programming written in C/C++

Are there good open-source projects on P2P file-sharing systems or distributed file systems written in C/C++ ? I need a project to start with network-programming. Can anyone give me any suggestions? ...

What is a good filesystem for embedded NAND drives?

Hi, I am working on an embedded application that uses NAND flash for storage. As it looks now, we won't use Linux or any other RTOS. The application must handle unexpected power downs. We have been looking on different file system solutions, including YAFFS2, JFFS2, FAT+FTL as well as solutions from HCC Embedded. I have heard FAT+FTL ...

Get the hierarchy of a directory with PHP

I'm trying to find all the files and folders under a specified directory For example I have /home/user/stuff I want to return /home/user/stuff/folder1/image1.jpg /home/user/stuff/folder1/image2.jpg /home/user/stuff/folder2/subfolder1/image1.jpg /home/user/stuff/image1.jpg Hopefully that makes sense! ...

Why Windows sets new created file's "created time" property to old time?

Trying this I have found a strange problem: Delete an old file. Create a new file and name it the same as the old file. Then the "created time" property of the new file is set to the "created time" of the old file. Why is that happens? And how of course? It seems that the directory does not delete the old file's entry and if a new file g...

[java] how do i programmatically change file permissions?

In java, i'm dynamically creating a set of files and i'd like to change the file permissions on these files on a linux/unix file system. I'd like to be able to execute the java equivalent of chmod. Is that possible Java 5, if so, how? I know in Java 6 the File object has setReadable()/setWritable() methods. I also know i could make a...

Secure and efficient way to modify multiple files on POSIX systems?

I have been following the discussion on the "bug" on EXT4 that causes files to be zeroed in crash if one uses the "create temp file, write temp file, rename temp to target file" process. POSIX says that unless fsync() is called, you cannot be sure the data has been flushed to harddisk. Obviously doing: 0) get the file contents (read it...

Add or extend file system support under windows

I've seen that Mac Drive 7 adds HFS+ and HFS support to windows for both hard-drives and CDs, which includes handling problems like the mac partition format. Clearly that must mean that file system support in windows is extensible somehow, even if it is slow. So where could someone start to write a simple (or not) file system driver for ...

The ideal background filesystem backup

I am thinking about a script/program that can run in background, and attempt to backup or synchronize a given filesystem path to a mirror location (probably located on an external/separate storage device). This should apply to Windows but it could as well be used under Linux. Differential/incremental backups are a bonus. Windows Syste...