Organized data encoded in a pre-defined format and stored on a filesystem.

learn more… | top users | synonyms

250
votes
15answers
176k views

How do you find what process is holding a file open in Windows?

One thing that annoys me no end about Windows is the old "sharing violation" error. Often you can't identify what's holding it open. Usually it's just an editor or explorer just pointing to a relevant ...
72
votes
8answers
106k views

How do I create a symbolic link in Windows?

Windows Vista added the ability to create symbolic links to files and directories. How do I create a symbolic link and what are the current consumer and server versions of Windows that support it?
63
votes
9answers
10k views

Linux - Is there a way to prevent/protect a file from being deleted even by root?

I have a very important file which an application in my workplace uses, i need to make sure it is not delete whatsoever, how can I do that?
41
votes
15answers
10k views

Favorite rsync tips and tricks

The more I use rsync the more I realise that it's a swiss army knife of file transfer. There are so many options. I recently found out that you can go --remove-source-files and it'll delete a file ...
29
votes
6answers
19k views

Merge 2 directory trees in Linux without copying?

I have two directory trees with similar layouts, i.e. . |-- dir1 | |-- a | | |-- file1.txt | | `-- file2.txt | |-- b | | `-- file3.txt | `-- c | `-- file4.txt `-- ...
20
votes
4answers
16k views

How to move files between two S3 buckets with minimum cost?

I have millions of files in a Amazon S3 bucket and I'd like to move these files to other buckets and folders with minimum cost or no cost if possible. All buckets are in the same zone. How could I ...
18
votes
9answers
19k views

Best way to compare (diff) a full directory structure?

What's the best way to compare directory structures? I have a backup utility which uses rsync. I want to tell the exact differences (in terms of file sizes and last-changed dates) between the source ...
14
votes
8answers
6k views

Doing an rm -rf on a massive directory tree takes hours

We're using rsnapshot for backups. It keeps lots of snapshots of the backuped up file, but it does delete old ones. This is good. However it's taking about 7 hours to do a rm -rf on a massive ...
14
votes
9answers
34k views

Linux (mv or cp) specific files from a text list of files?

I have a directory of many files, something like 50,000 pdf's and other files on a server. I need to move specific ones to another directory. I can generate a list of the files that need to be moved ...
11
votes
3answers
7k views

Does the Midnight Commander have an option to display actual dir sizes?

i have plenty of empty directories and i wonder if there's a way to display actual direcory sizes (after some sort of scan maybe) in MC
11
votes
2answers
18k views

What is stored in %Windir%\System32\LogFiles\WMI\RtBackup?

I occasionally notice in Resource Monitor hard disk activity related to ETL files in the folder C:\Windows\System32\LogFiles\WMI\RtBackup. Which process/service creates these ETL files and what is ...
9
votes
5answers
13k views

Recursively copying hidden files - Linux

Is there an easy way to recursively copy all hidden files in a directory to another directory? I would like to back up just all the settings files in a home directory, not the normal files. I tried: ...
9
votes
2answers
748 views

Transfer a 30GB tar file from one remote server to another - restrained by disk space

I have a 38GB "Moodle" tar file that I need to transfer from the old server (Shared hosting), which we can call "Server A" to the new server (Dedicated virtual), or "Server B". I'm with Mediatemple if ...
9
votes
4answers
1k views

read specified range of lines from a file

I have i file that contains 100000 line how i can get the lines from line# 5555 to line# 7777 under linux. Thanks for all.
9
votes
6answers
1k views

Files disappearing on linux server

I've got 4 specific files that seem to keep disappearing from a user's home directory. As far as we know, there are no cronjobs or other automated tasks that would be removing them. I've setup auditd ...
9
votes
3answers
5k views

In SQL Server, when should you split your PRIMARY Data FileGroup into secondary data files?

Our database currently only has one FileGroup, PRIMARY, which contains roughly 8GB of data (table rows, indexes, full-text catalog). When is a good time to split this into secondary data files? What ...
8
votes
4answers
2k views

Linux : Losing group ownership of files

I have a project with a number of files that I created in Linux. And I needed to give another user write permission on them. So I created a "dev" group of which he and I are members and changed the ...
8
votes
1answer
7k views

Perform rsync while following sym links

I have a directory that contains symbolic links to other directories located on different media on my system: /opt/lun1/2011 /opt/lun1/2010 /opt/lun2/2009 /opt/lun2/2008 /opt/lun3/2007 But the ...
8
votes
6answers
3k views

Is there a tool to compare values in .ini files? [closed]

I'm looking for a file comparison utility specifically for .ini files, typically used as settings files. There are plenty of file comparison tools (WinDiff, Beyond Compare, CompareIt, WinMerge, ...), ...
8
votes
5answers
16k views

How do I extract all archives in the subdirectories of this folder?

How do I extract multiple archives in contained in subdirectories in a folder, outputting the results back into the folders where the archives are.
8
votes
1answer
2k views

Why does getfattr not display anything for a file that has the extended attribute bit set?

I've got a Nagios XI install running on CentOS 6.2, and want to modify the backup script. I noticed that the extended attribute bit is set for this shell script, so I want to be sure not to mess ...
7
votes
4answers
2k views

How can I easily confirm in Linux that two separate directories have the exact same contents?

CentOS 5.x Mq question seemed similar to this one but I wasn't sure... I have two servers (completely isolated from each other), each with a directory and sub-directories that should have the same ...
7
votes
2answers
466 views

How to find files affected by reallocated sectors?

I have a Western Digital RE4 1.5TB that has just reallocated 56 sectors. Reallocated Sectors Count,140,193,193,OK,56,0,Enabled I want to know if it is possible to find out which are the files ...
7
votes
7answers
4k views

How long do you keep log files?

I have an application which writes its log files in a special folder. Now I'd like to add a functionality to delete these logs after a defined period of time automatically. But how long should I keep ...
6
votes
6answers
6k views

How to Find a file in FreeBSD

I'm trying to locate all copies of example.filename on my FreeBSD server. What's the best / easiest / most efficient way to do this?
6
votes
6answers
3k views

In *nix, how to determine which filesystem a particular file is on?

In a generic, modern unix environment (say, GNU/Linux, GNU/Solaris, or Mac OS X), is there a good way to determine which mountpoint and filesystem-type a particular absolute file path is on? I ...
6
votes
5answers
653 views

Force file deletion on Windows

Often on my development workstation (on which I am administrator and the only user), I am unable to delete files by deleting the root folder - despite having recursively taken ownership of the tree. ...
6
votes
3answers
4k views

Stopping too long filenames in Windows Server 2003

We're finding a problem with long filenames, usually on "My Documents" or on shared drives. Basically, it seems that a document could be written that has a very long filename, and saved say in "My ...
6
votes
8answers
3k views

Monitor File Changes On Windows System

I am looking for a utility that can take a snapshot of the files in directories that I am interested in and then compare that snapshot to the current state of the system and show me any files that ...
6
votes
4answers
4k views

Automatic Notification of New or Changed Files in a Folder or Share

I'm looking for some Open Source [free] or relatively inexpensive solution for monitoring specific folders on a file system and 'Windows' network with several shares. When a file is added or changed, ...
6
votes
0answers
2k views

Log file rotation and “tail -f”

I use log4j to create rolling log files from my program. It writes to a log file until it reaches 256mb, and then it renames all the log files and creates a new log file and continues logging. It is ...
5
votes
9answers
3k views

Deleting large no of files on linux eats up CPU

I generate more than 50GB of cache files on my RHEL server (and typical file size is 200kb so no of files is huge). When I try to delete these files it takes 8-10 hours. However, the bigger issue is ...
5
votes
4answers
4k views

Incorrect file creation date in Windows XP/Vista

Check this out: Create a new file on your Windows machine. Note its creation date/time. Delete the file. Wait a little bit. Create a new file on the same directory, with the same name as the ...
5
votes
5answers
7k views

Get total files size from a file containing a file list

I have a file containing a list of files that I would like to know the total files size. Is there a command to do so? My OS is a very basic linux (Qnap TS-410). EDIT: A few lines from the file: ...
5
votes
2answers
312 views

Concatenating files to a virtual file on Linux

On a Linux system, is there any way to concatenate a series of files into one exposed file for reading and writing while not actually taking up another N bytes of disk space? I was hoping for ...
5
votes
1answer
235 views

How to distribute files and folders to handle large number of files

I want to manage a huge number of files on my server (say millions). It is needed to save files in two or three levels of folders to keep the number of files in each folder low. On the other hand, it ...
5
votes
1answer
577 views

BYOD (accessing files) on a domain without joining?

I run a Samba 4 instance at a small private school. This makes a regular Linux server appear as a directory controller. There are two relevant benefits to this: I have a Samba share for people's ...
5
votes
2answers
191 views

Deny all files in a certain directory using <files>

Im attempting to secure the mod_userdir module in apache.. Currently the directory structure for my users sites is /home/{user}/domains/{domain}/public_html/site The issue is, a number of my users ...
5
votes
2answers
449 views

Disk fragmentation when dealing with many small files

On a daily basis we generate about 3.4 Million small jpeg files. We also delete about 3.4 Million 90 day old images. To date, we've dealt with this content by storing the images in a hierarchical ...
4
votes
5answers
247 views

Remove a file with <Down> in the name?

So, on a CentOS box, I accidentally executed :w<Down> in a vim editor, with "<Down>" being literally pressing the down arrow key on the keyboard (rendered onscreen as "<Down>"), and ...
4
votes
3answers
3k views

Is there a hard limit to the number of files a directory can have? [duplicate]

Wondering if there is a limit to the number of files that can be stored inside a directory, in CentOS 6. There is one particular directory which could potentially have millions of subdirectories. ...
4
votes
6answers
14k views

How to rename multiple files by replacing word in file name?

Replace ACDC to AC-DC For example we have these files ACDC - Rock N' Roll Ain't Noise Pollution.xxx ACDC - Rocker.xxx ACDC - Shoot To Thrill.xxx I want them to become: AC-DC - ...
4
votes
5answers
3k views

Unable to remove file using 'rm'

In one of our severs (IBM AIX), we have a file in path /data/1002/ which we were not able to remove or delete using the 'rm' command. The error message we got is "rm: S1208001.002: A file or directory ...
4
votes
2answers
710 views

Linux: ps -awx vs. ps -awwx

Does anyone know the difference of ps -awx vs. ps -awwx? I'm tracking down some processes, and I see significantly more information when I add an additional "w". Does this work like in other cases ...
4
votes
3answers
963 views

Is it possible to GET or PUT two specific files at a time using SFTP without wildcard?

From a directory of dozens of files, is it possible to GET or PUT two files at once using SFTP? I do not want to use a wildcard because I don't necessarily know the names of all the files and don't ...
4
votes
2answers
7k views

Move files to another directory which are older than a date

I am looking for a solution to move files that are year older from today. My log partition is getting full, but I can not remove them. They are needed for a long long time. Anyway one solution I came ...
4
votes
1answer
839 views

how to delete a insane number of files from an unix system?

On a system with linux there are 2 folders with aprox 12gb used(out of 500gb) and all inodes are used by some s
4
votes
1answer
110 views

List all files modified or created by certain application

Is there a free tool to list all files modified by certain application? What I would like to see is that I can start "monitoring" and start my application (MS Word). After that I can stop ...
4
votes
1answer
65 views

Group Policy Files - Active Directory

I am having a whole lot of trouble getting some files distributed across the network. My settings are: Action: Replace Source: \\[fqdn]\Repo\sqljdbcl.jar Destination: ...